[Nut-upsuser] APC Smart-UPS 1000

Arjen de Korte nut+users at de-korte.org
Mon Feb 7 08:36:03 UTC 2011


Citeren Kevin <bakdong op gmail.com>:

> On 06/02/2011 21:42, Kevin wrote:
> Ok, I've tried that. The result of "clientcmd -u apcmon -p pass123  
> -a apc1500 shutdown.reboot" is nothing. Nothing that I can see  
> changes at all.

Of course. Do as I asked you and it *will* make a difference.

> I did this with the old working modified hidups driver:
>
> # ./hidups -DDD -k /dev/hiddev0
> Network UPS Tools: HID UPS driver 0.13 (2.0.0)

Use nut-2.6.0 instead. The above version is too old and I have no idea  
what variables it supports (and I don't want to take the time finding  
out).

> There are three lines in the apc-hid.c code that reference shutdown.reboot:
>
>   1. { "shutdown.reboot", 0, 0, "UPS.PowerSummary.DelayBeforeReboot",
>      NULL, "10", HU_TYPE_CMD, NULL },
>   2. { "shutdown.reboot", 0, 0, "UPS.Output.DelayBeforeReboot", NULL,
>      "10", HU_TYPE_CMD, NULL },
>   3. { "shutdown.reboot", 0, 0,
>      "UPS.APCGeneralCollection.APCDelayBeforeReboot", NULL, "1",
>      HU_TYPE_CMD, NULL },

The name change of the command is critical here. NUT will use whatever  
mapping it finds first, so that's the reason I asked you to use  
'shutdown.return' for this specific HID path instead. Otherwise the  
command will never be reached if you call the driver with '-k' and  
when you run 'shutdown.reboot' it will probably find a different HID  
path first.

Best regards, Arjen
-- 
Please keep list traffic on the list (off-list replies will be rejected)




More information about the Nut-upsuser mailing list