[Nut-upsuser] Belkin USB UPS Not Turning Off
Charles Lepple
clepple at gmail.com
Thu Jan 2 02:34:55 GMT 2020
On Jan 1, 2020, at 3:27 PM, Manuel Wolfshant <wolfy at nobugconsulting.ro> 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.
More information about the Nut-upsuser
mailing list