[Nut-upsuser] two MGE Ellipse 1500 ups via usb

Thomas Gutzler thomas.gutzler at gmail.com
Wed Nov 18 03:18:14 UTC 2009


Arjen,

Thanks for your very tutorial email. It helped a lot.
I have moved my master monitor to the nfs machine and setup upsmon on
all other machines.

Arjen de Korte wrote:
> Citeren Thomas Gutzler <thomas.gutzler at gmail.com>:
> 
>> My setup is this: I have 6 computers on 2 UPSs (3 each). Boths UPSs have
>> equal power ratings but the load on the slave is less. They are both
>> connected to and monitored by the same computer (I call it monitor);
>> [...]
> 
> You can do this much better entirely in the upsmon.conf files
> on the various systems, without having to write your own shutdown
> scripts. [...]

My master, which is also nfs server now reads:
MONITOR ups1 at localhost 1 monmaster blah master
MONITOR ups2 at localhost 1 monmaster blah master
MINSUPPLIES 2
FINALDELAY 5

All other systems do this:
MONITOR ups1 at monitor 1 monslave blah slave
MINSUPPLIES 1
FINALDELAY 5


>> <shutdown script> Fortunately,
>> ubuntu comes with such a script (K50nut) but it has to be executed with
>> the parameter 'poweroff', not 'stop'. So, am I supposed to write a
>> shutdown script /etc/rc0.d/K99upspoweroff that calls '/etc/rc0.d/K50nut
>> poweroff'?
> 
> Not if you use the above upsmon configuration, assuming that the people
> of Ubuntu created a proper shutdown script.

They did.
The halt shutdown script includes code that runs /etc/init.d/ups-monitor
poweroff if $INIT_HALT = POWEROFF, which is controlled by
/etc/default/halt. There, default setting is HALT=poweroff
So it should all work.


> [...] In order to be able to restart if the power returns in
> the mean time, 'ondelay' must be higher than 'offdelay'.

I have two variables that I can set:
1) ups.delay.shutdown: Interval to wait after shutdown with delay
command (seconds)
2) ups.delay.start: Interval to wait before (re)starting the load (seconds)

I set 1 to 30 on both UPS and 2 to 60 on the master and 180 on the
slave, so that the master (nfs server) is avaiable before the rest comes
back. Unfortunately, there doesn't seem to be a variable that controls
how much charge the UPS must have before switching the load back on - I
suppose, it doesn't care. I'm pretty confident though that both UPSes
have enough charge to go through a second reboot and shutdown cycle even
if they're starting on 50%, which is what I have configured to be the
critical point.


Now all I have to do is wait for the next thunderstorm :)

Cheers,
  Tom




More information about the Nut-upsuser mailing list