[Nut-upsuser] How do I initiate a shutdown sequence immediately after losing line power?

Charles Lepple clepple at gmail.com
Thu Feb 13 15:52:08 UTC 2014

On Feb 13, 2014, at 10:22 AM, Stoycho Ganev wrote:

> Hi!
> Is there a way to tell upsd to initiate a shutdown sequence (i.e. run SHUTDOWNCMD) immediately after losing line power and switching the state to OB?
A generic way would be to have upsmon signal upssched, and run the shutdown command when upssched gets the OB signal:



You may want to look at the timers in upssched; otherwise, you may get false positives if your UPS briefly transitions to OB during a power glitch.
> I'm using an old battery and by the time it reaches LB state, it's already too late for a clean shutdown.
> Another solution would be to change the LB percentage. It currently reads (upsc):
> battery.charge.low: 10
> Is there a way to raise that to, say, 40 or 50 percent?
Hard to say without knowing what driver you are using (and even then, it depends on the UPS firmware). But if that variable shows up in the list when you run upsrw, then you should be able to adjust it.

> The goal is to initiate she shutdown procedure as soon after losing line power as possible.
> Thanks!
> -- 
> - - - - -
> Stoycho Ganev
> Linux Administrator
> 16 Ivan Vazov st., fl.4
> Sofia 1000
> UIC: 131409398
> tel: (+359 2) 921 08 50
> fax: (+359 2) 987 91 31
> s.ganev at datamax.bg
> https://www.epay.bg
> Please do not print this e-mail unless you really need to!
> This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.
> _______________________________________________
> Nut-upsuser mailing list
> Nut-upsuser at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/nut-upsuser

Charles Lepple
clepple at gmail

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20140213/45c4bed4/attachment-0001.html>

More information about the Nut-upsuser mailing list