I had a couple of power cuts yesterday so today I have installed an APC UPS.
Connecting the USB cable to my Ubuntu PC has given me a battery icon showing status so everything "just works" without messing around installing nut or anything similar, which is what I was expecting to do.
However:
I have two PCs being protected by the same UPS, the second being a Win10 box. I was expecting to use something like nut to share the status between the two boxes so both will shut down on low battery.
Given that "it just works" so far, I'd like to supplement the existing config rather than replace it. Anyone here done something similar or know where I should start?
Mark
On 18/02/16 11:59, Mark Rogers wrote:
I had a couple of power cuts yesterday so today I have installed an APC UPS.
Connecting the USB cable to my Ubuntu PC has given me a battery icon showing status so everything "just works" without messing around installing nut or anything similar, which is what I was expecting to do.
However:
I have two PCs being protected by the same UPS, the second being a Win10 box. I was expecting to use something like nut to share the status between the two boxes so both will shut down on low battery.
Given that "it just works" so far, I'd like to supplement the existing config rather than replace it. Anyone here done something similar or know where I should start?
Mark
One of the "great" (for some value of great) thing about "It Just Works" is you (one) has no-idea how it works! I have apcupsd running = APC UPS Daemon. Minimal config & it works. You may or may not have that installed, or perhaps it's a hardware-driven USB driver thingy.
For apcupsd, I think there are examples posted on t'internet of how to use it to shut down multiple computers - either they all run apcupsd, or you hack the script that apcupsd runs in the power-fail-I'm-Shutting-down situation to send a message to the other machines to shutdown.
It may be possible to run apcupsd on a windows box (possibly via cygwin). Alternatively you have to run something that either listens to a signal from the UPS machine, or accepts commands from the UPS machine. You could run a SSH server on the windows machine that would accept a ssh command to shutdown (again, possibly via cygwin). (NB, first you have to work out how to issue a shutdown command from a command prompt). Alternatively, you could write a program that polls for the existence or non-existance of a file in a shared directory, and shuts down if it's there/not there. You'd then have to work out how to shutdown from inside a program.
I'm sure it's all been done before, but it could be fun working out how to do it. No doubt, windows' firewall will step in and make things more complicated.
I guess the first thing to would be to work out what software is initiating the shutdown on your UPS machine and read-up on it.
good luck!
On 4 March 2016 at 10:46, steve-ALUG@hst.me.uk wrote:
One of the "great" (for some value of great) thing about "It Just Works" is you (one) has no-idea how it works!
Indeed! For stuff that I have no real interest in that's fine, and to be honest although I've set up nut many times in the past it's never been regular enough that I've actually learned it (I always have to Google). Which means the obvious benefits of knowing how it works don't really apply and I might as well "learn" afresh how to do it in the new GUI environment.
I have apcupsd running = APC UPS Daemon. Minimal config & it works. You may or may not have that installed, or perhaps it's a hardware-driven USB driver thingy.
I don't have apcupsd (or at least "ps ax | grep apc" shows nothing).
As the main PC is my Linux box at the moment I'm minded to let it chance it - the Windows PC is still UPS backed regardless so it's only handling the case where the power is off long enough to kill the UPS (which admittedly isn't all that long).
Thanks for the suggestions though.
Mark