<br><div class="gmail_quote">2011/7/24 Sergei V. Dubrov <span dir="ltr"><<a href="mailto:dubrov@inp.nsk.su" target="_blank">dubrov@inp.nsk.su</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


G'day!<br>
<br>
On 23 Jul 2011 at 11:26, Sergei V. Dubrov wrote:<br>
<br>
To clarify some points...<br>
<div><br>
> ><br>
> > What I see after pulling the plug:<br>
> ><br>
> > ./upsc xen-home battery.charge<br>
> > 72<br>
> ><br>
> > ./upsc xen-home ups.status<br>
> > OB DISCHRG<br>
> ><br>
> > OB status is correct but why is there DISCHRG status?! This flag, as I<br>
> > think, cause immediately begin of shutdown although the battery is not<br>
> > discharged and has 72 percent of charge.<br>
> ><br>
> > Is DISCHRG exactly from UPS or is it an inaccurate interpretation of<br>
> > obtained status from WOW-500U?<br>
> ><br>
> > DISCHRG is a normal value:<br>
<br>
</div>Yes, it's absolutely true. My mistake was that I  thought that DISCHRG<br>
status means DISCHARGED (low) battery. But really this mean DISCHARGING,<br>
that is quite natural immediately after switching to battery.<br>
<br>
><br>
> Start test of battery:<br>
...<br>
> ups.status: OB DISCHRG<br>
<br>
I used a test battery instead of turning off from the outlet, because the<br>
behavior of NUT in these cases coincides. After switching UPS to battery<br>
and obtaining status OB (instead OB+LB) NUT immediately starts shutdown<br>
(after FINALDELAY - 5 sec by default). My workaround - is significantly to<br>
increase the delay (FINALDELAY=90 sec for me) but it's not quite right.<br>
<br>
Confirmation that the shutdown should not begin on the status OB (instead<br>
critical OB+LB) I found in manual page:<br>
<br>
<a href="http://www.networkupstools.org/docs/man/optiups.html" target="_blank">http://www.networkupstools.org/docs/man/optiups.html</a><br>
<br>
"fake_lowbatt<br>
<br>
This forces the low battery flag true. Without it, if you want to test your<br>
UPS, you will have to unplug it and wait until the battery drops to a<br>
low/critical voltage level before NUT will respond and power down your<br>
system. With the flag, NUT should power down the system soon after you pull<br>
the plug. When you are done testing, you should remove this flag."<br>
<br>
And once again want to emphasize - UPS does not go to state 'data stale'<br>
(loss of communication) after switching to battery since we can immediately<br>
read its status, for example, with the command 'upsc'.<br></blockquote></div><br>but since upsmon launches the system shutdown, there is something triggering it!<br><br>fake_lowbatt doesn't exist in usbhid-ups. <br>
you're probably facing a data mapping mismatch.<br><br>the best would be to monitor this a bit more closely.<br>
prefer to remove your PC from the UPS for those tests!<br>set SHUTDOWNCMD to empty or something not hurting (gedit) and restart upsmon and the driver in debug mode (ie "usbhid-ups -DDD -a ..."), in separate consoles.<br>
<br>then test a power failure, and send us back the results, along with your configuration (passwd trimmed!)<br>
<br>cheers,<br>Arno<br><br>