How To Install apcupsd on Fedora 36

In this tutorial we learn how to install apcupsd in Fedora 36. apcupsd is APC UPS Power Control Daemon

Introduction

In this tutorial we learn how to install apcupsd on Fedora 36.

What is apcupsd

Apcupsd can be used for controlling most APC UPSes. During a power failure, apcupsd will inform the users about the power failure and that a shutdown may occur. If power is not restored, a system shutdown will follow when the battery is exausted, a timeout (seconds) expires, or the battery runtime expires based on internal APC calculations determined by power consumption rates. If the power is restored before one of the above shutdown conditions is met, apcupsd will inform users about this fact. Some features depend on what UPS model you have (simple or smart).

We can use yum or dnf to install apcupsd on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install apcupsd.

Install apcupsd on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install apcupsd using dnf by running the following command:

sudo dnf -y install apcupsd

Install apcupsd on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install apcupsd using yum by running the following command:

sudo yum -y install apcupsd

How To Uninstall apcupsd on Fedora 36

To uninstall only the apcupsd package we can use the following command:

sudo dnf remove apcupsd

apcupsd Package Contents on Fedora 36

/etc/apcupsd
/etc/apcupsd/apccontrol
/etc/apcupsd/apcupsd.conf
/etc/apcupsd/changeme
/etc/apcupsd/commfailure
/etc/apcupsd/commok
/etc/apcupsd/offbattery
/etc/apcupsd/onbattery
/etc/logrotate.d/apcupsd
/lib/systemd/system-shutdown/apcupsd_shutdown
/lib/systemd/system/apcupsd.service
/sbin/apcaccess
/sbin/apctest
/sbin/apcupsd
/sbin/smtp
/usr/lib/.build-id
/usr/lib/.build-id/1c
/usr/lib/.build-id/1c/9a494c68a057e8290919174355758f306511b6
/usr/lib/.build-id/62
/usr/lib/.build-id/62/ded8b2d3e98107c4feba0a6e6beff1661c42f6
/usr/lib/.build-id/81
/usr/lib/.build-id/81/08ea49f8ccf5b01353ed5c33aea4950ed17610
/usr/lib/.build-id/db
/usr/lib/.build-id/db/de7af7c106e78df041371d957c8fb101d40527
/usr/share/doc/apcupsd
/usr/share/doc/apcupsd/ChangeLog
/usr/share/doc/apcupsd/ReleaseNotes
/usr/share/doc/apcupsd/examples
/usr/share/doc/apcupsd/examples/Makefile
/usr/share/doc/apcupsd/examples/SmartUPS1400.snmp
/usr/share/doc/apcupsd/examples/client.c
/usr/share/doc/apcupsd/examples/gui
/usr/share/doc/apcupsd/examples/gui/about.tcl
/usr/share/doc/apcupsd/examples/gui/apcupsd.tcl
/usr/share/doc/apcupsd/examples/gui/dialog.tcl
/usr/share/doc/apcupsd/examples/gui/events.tcl
/usr/share/doc/apcupsd/examples/gui/mainwindow.tcl
/usr/share/doc/apcupsd/examples/gui/pkgIndex.tcl
/usr/share/doc/apcupsd/examples/gui/splash.tcl
/usr/share/doc/apcupsd/examples/gui/status.tcl
/usr/share/doc/apcupsd/examples/hid-set.c
/usr/share/doc/apcupsd/examples/hid-ups.c
/usr/share/doc/apcupsd/examples/hiddev.h
/usr/share/doc/apcupsd/examples/index.php
/usr/share/doc/apcupsd/examples/libusb.h
/usr/share/doc/apcupsd/examples/make-hiddev
/usr/share/doc/apcupsd/examples/megaclient.c
/usr/share/doc/apcupsd/examples/nagios_plugin_check_apcupsd.c
/usr/share/doc/apcupsd/examples/newslave.c
/usr/share/doc/apcupsd/examples/offbattery.cpufreq
/usr/share/doc/apcupsd/examples/onbattery.cpufreq
/usr/share/doc/apcupsd/examples/php-monitor.txt
/usr/share/doc/apcupsd/examples/rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-350-USB.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-350ES.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-500-USB.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-500ES.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-BR-800.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-CS-650.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-ES-550.rpt
/usr/share/doc/apcupsd/examples/rpt/Back-UPS-XS-1300-LCD.rpt
/usr/share/doc/apcupsd/examples/rpt/BackUPS.rpt
/usr/share/doc/apcupsd/examples/rpt/Smart-UPS-1500.rpt
/usr/share/doc/apcupsd/examples/rpt/SmartUPS-USB.rpt
/usr/share/doc/apcupsd/examples/rpt/SmartUPS.rpt
/usr/share/doc/apcupsd/examples/rpt/hid-ups.rpt
/usr/share/doc/apcupsd/examples/safe.apccontrol
/usr/share/doc/apcupsd/examples/smartsim.c
/usr/share/doc/apcupsd/examples/snoopdecode.c
/usr/share/doc/apcupsd/examples/status
/usr/share/doc/apcupsd/examples/status/Back-UPS-BX-1500.status
/usr/share/doc/apcupsd/examples/status/Back-UPS-Pro-1000.status
/usr/share/doc/apcupsd/examples/status/BackUPS-USB.status
/usr/share/doc/apcupsd/examples/status/JapaneseUPS.status
/usr/share/doc/apcupsd/examples/status/PowerStack450.status
/usr/share/doc/apcupsd/examples/status/SmartUPS-vs-650.status
/usr/share/doc/apcupsd/examples/status/SmartUPS1000.status
/usr/share/doc/apcupsd/examples/status/SmartUPS1400.status
/usr/share/doc/apcupsd/examples/status/SmartUPS3000.status
/usr/share/doc/apcupsd/examples/status/SmartUPS5000.status
/usr/share/doc/apcupsd/examples/status/SmartUPS600.status
/usr/share/doc/apcupsd/examples/status/SmartUPS700-2.status
/usr/share/doc/apcupsd/examples/status/SmartUPS700.status
/usr/share/doc/apcupsd/examples/status/newbackupspro1.status
/usr/share/doc/apcupsd/examples/status/newbackupspro2.status
/usr/share/doc/apcupsd/examples/upsapm.c
/usr/share/doc/apcupsd/examples/usb_hid_usages
/usr/share/doc/apcupsd/examples/usbsnoop.txt
/usr/share/hal/fdi/policy/20thirdparty/80-apcupsd-ups-policy.fdi
/usr/share/licenses/apcupsd
/usr/share/licenses/apcupsd/COPYING
/usr/share/man/man5/apcupsd.conf.5.gz
/usr/share/man/man8/apcaccess.8.gz
/usr/share/man/man8/apccontrol.8.gz
/usr/share/man/man8/apctest.8.gz
/usr/share/man/man8/apcupsd.8.gz

References

Summary

In this tutorial we learn how to install apcupsd on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).