[Nut-upsuser] nut 2.0.2 + Fedora Core 4 : installation notes / how-to / tutorial

Miguel mth at mth.com
Fri Oct 21 12:58:39 UTC 2005


Fri 21 Oct 2005

The following are my notes for setting up NUT 2.0.2 on Fedora Core 4 using
the precompiled binary .rpm packages from rpmfind.net

Miguel
mth at mth.com

Config:
mykiss is the machine name (from oncorhynchus mykiss)
amd64
Fedora Core 4
Cyberpower 1250AVR UPS
Serial communications cable plugged into /dev/ttyS0

Note that Cyberpower provides linux software for 2.4 kernels. However, it
does not support 2.6 kernels. They have indicated to me via email that
they have no plans at this time to support 2.6 kernels. So it is time to
switch to nut.

    * http://www.networkupstools.org/ -> Packages -> RPMs via rpmfind.net
    * download Fedora Core Development for x86_64 nut-2.0.2-1.x86_64.rpm
    * you also need the nut-client. Scroll to the top of the rpmfind page
and type in nut-client -> Search ...
    * download Fedora Core Development for x86_64
nut-client-2.0.2-1.x86_64.rpm
    * install rpm packages

 $ cd <the directory where you downloaded>
 $ su
 # rpm -ivh nut-client-2.0.2-1.x86_64.rpm nut-2.0.2-1.x86_64.rpm


    * give the nut user access to the serial port. Note that ownership of
the serial port will be set to root.uucp each time tye system is
rebooted. Therefore, # chown nut.nut /dev/ttyS0 will not work across
system restarts. Therefore, we address this by making the nut user a
member of the uucp group.

# usermod -G nut,uucp nut


    * configure files


#  emacs /etc/sysconfig/ups
 * change MODEL=upsdrvctl
 * comment out DEVICE=/dev/ttyS0 because it is not used here and causes
confusion
 * comment out OPTIONS= because it is not used here and causes confusion

# cd /etc/ups
# emacs ups.conf
 * add a UPS definition at the bottom
[mykissUPS]
        driver = cyberpower
        port = /dev/ttyS0
        desc = "Cyberpower 1250AVR on mykiss"

# emacs upsd.users
 * create a nutmonitor user at the bottom
[nutmonitor]
    password = nutmonitorPassword
    allowfrom = localhost

# emacs upsmon.conf
 * create a MONITOR entry in the middle
MONITOR mykissUPS at localhost 1 nutmonitor nutmonitorPassword master


    * # service ups start
          o observe three services that start successfully with [ OK ]
    * permanently add to startup scripts

# chkconfig ups on
# chkconfig --list ups


    * force a shutdown by simulating a power failure

# upsmon -c fsd


    * Note that with the forced shutdown the Cyberpower 1250AVR UPS will
power off and switch to a standby state
    * press switch on UPS to turn it off
    * press switch on UPS to turn it back on
    * observe that system starts to reboot. If it does not, check BIOS
powerup settings.
    * click on Display Details during powerup to observe that three NUT
services start with [ OK ] status
    * login
    * open a terminal
    * pull power on UPS
    * observe on battery message
    * let battery drain and confirm that system shuts down properly
    * plugin UPS back in and observe that system restarts cleanly




More information about the Nut-upsuser mailing list