On Jan 1, 2020, at 3:27 PM, Manuel Wolfshant <[email protected]> wrote: > >> Well, I just tried "/sbin/upsdrvctl shutdown" and while I see some output >> and a message shutting down in 30 seconds, nothing happens to the host >> machine or the UPS. Hmmm. > that command only stops the drivers. generally speaking, upsdrvctl operates > only on the drivers.
But in the case of "upsdrvctl shutdown", upsdrvctl iterates through the drivers and calls them with "-k" to shutdown the UPS power. It expects "upsdrvctl stop" to have been run earlier, which shuts down the long-running driver process that poll the UPS during normal operation. https://github.com/networkupstools/nut/blob/v2.7.4/drivers/upsdrvctl.c#L343-L350 "usbhid-ups -k" tries several of the "shutdown.*" commands in order, which you can see if you add a few "-D" options to that command line. If your UPS does not respond to the usual shutdown commands (or ignores some of them in certain modes), the other commands mentioned elsewhere in this thread might work better. _______________________________________________ Nut-upsuser mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
