David Mathog
2008-Jul-18 15:40 UTC
[Nut-upsuser] [Nut-upsdev] Shutdown by battery.remaining or battery.runtime?
> If you have any more questions regarding this, please use the nut-upsuser > mailinglist instead.Redirected to the appropriate list, sorry.> > Is there a place in the upsmon.conf (or elsewhere) > > file where one may enter something like: > > > > OVERRIDE_BATTERY_CHARGE_LOW 20 > > OVERRIDE_BATTERY.LOW 240 > >> See 'man 8 upsrw'. If your UPS supports changing this value, it should be > listed if you run 'upsrw <upsname>'. Most of the time, if it is possible > to change this value, it will be stored in non-volatile memory in the UPS > itself, so you only need to do this once.upsrw listed the values that may be changed, but it would not change them. When I try it asks for a username/password. I tried root, nut (the user "built into" nut), and the single user entry in upsd.users. In all cases this happened: % /usr/local/ups/bin/upsrw -s battery.charge.low=25 -u root apcups at localhost Password: Unexpected response from upsd: ERR ACCESS-DENIED This is nut 2.2.2 built from source. Possibly relevant, the password for the upsd.users account is 23 characters long. Too long for the software maybe??? It works ok with upsmon though. Thanks, David Mathog mathog at caltech.edu Manager, Sequence Analysis Facility, Biology Division, Caltech
Arjen de Korte
2008-Jul-18 19:02 UTC
[Nut-upsuser] [Nut-upsdev] Shutdown by battery.remaining or battery.runtime?
>> If you have any more questions regarding this, please use the >> nut-upsuser >> mailinglist instead. > Redirected to the appropriate list, sorry.No need to apologize here. You're question for the addition of a feature was relevant on the development mailinglist, but since there is a way to do this in NUT already exists, any questions about the latter should be directed to the nut-upsuser mailinglist. [...]> upsrw listed the values that may be changed, but it would not change > them. When I try it asks for a username/password. I tried root, > nut (the user "built into" nut), and the single user entry in > upsd.users. In all cases this happened: > > % /usr/local/ups/bin/upsrw -s battery.charge.low=25 -u root > apcups at localhost > Password: > Unexpected response from upsd: ERR ACCESS-DENIED > > This is nut 2.2.2 built from source. > > Possibly relevant, the password for the upsd.users account is 23 > characters long. Too long for the software maybe??? It works ok > with upsmon though.The username and password should be listed in 'upsd.users'. But (and this is probably what goes wrong), this user should also be allowed to change variables through the 'actions' field (see 'man 5 upsd.users'). If you don't list this, the user is denied access by default. Best regards, Arjen