I just installed NUT on a new Linux (Gentoo) system. Most things work, (notification after 10 seconds on battery, notification and system shutdown after 100 seconds on battery.) However I can't seem to get the UPS (an Eaton 5SC1500) to turn itself off after the Gentoo system shutdown.
This is the shutdown command I am using in /etc/nut/upsmon.conf: SHUTDOWNCMD "/usr/sbin/upsdrvctl shutdown Eaton5SC1500 ; /sbin/shutdown -h +0" The /etc/shutdown part works. The UPS name, Eaton5SC1500, is correct because the command 'upsc Eaton5SC1500' lists the current parameters of the ups. Here is part of /var/log/messages during my last test "power outage": Jul 26 19:08:57 run-public upssched[4923]: Event: timeshutdown Jul 26 19:08:57 run-public upssched-cmd[4940]: The UPS has been on battery for 100 seconds -- shutting down Jul 26 19:08:57 run-public upsmon[4897]: Signal 10: User requested FSD Jul 26 19:08:57 run-public upsmon[4897]: FSD set on UPS [email protected] failed: ERR ACCESS-DENIED Jul 26 19:08:57 rur-public upsmon[4897]: Executing automatic power-fail shutdown Jul 26 19:08:57 run-public upsmon[4897]: Auto logout and shutdown proceeding Any idea on what is causing that ERR ACCESS-DENIED message? Running upsdrvctl in test mode doesn't tell me much: # /usr/sbin/upsdrvctl -t shutdown Eaton5SC1500 Network UPS Tools - UPS driver controller 2.7.4 *** Testing mode: not calling exec/kill 0.000000 If you're not a NUT core developer, chances are that you're told to enable debugging to see why a driver isn't working for you. We're sorry for the confusion, but this is the 'upsdrvctl' wrapper, not the driver you're interested in. Below you'll find one or more lines starting with 'exec:' followed by an absolute path to the driver binary and some command line option. This is what the driver starts and you need to copy and paste that line and append the debug flags to that line (less the 'exec:' prefix). 0.000137 Shutdown UPS: Eaton5SC1500 0.000151 exec: /lib64/nut/usbhid-ups -a Eaton5SC1500 -k --------------------- OS: Gentoo Linux: Gentoo Base System release 2.4.1 Linux Kernel: 4.17.10-gentoo NUT version: 2.7.4 (Installed via Gentoo Portage: (ie. "emerge nut") UPS info (from upsc): device.mfr: EATON device.model: Eaton 5SC 1500 device.type: ups driver.name: usbhid-ups driver.version: 2.7.4 driver.version.data: MGE HID 1.39 driver.version.internal: 0.41 _______________________________________________ Nut-upsuser mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
