UPS monitor/shutdown service
I have messed around with NUT to trigger a graceful shutdown of my home server running Ubuntu Server. I have struggled with setting NUT up on bare metal, but would like a gui anyway. I saw PVE-UPS which looks good, but I think but I think it is meant for Proxmox. Any alternatives, or a spin of PVE-UPS for docker compose anybody know about?
Thanks. Good info. Feel like sharing your conf file to see how it’s formatted in an example that actually works? Might make this my weeks evening project.
It’s a lot. But here are my most recent notes.
Note that the pipe & lock locations different by distro, as does the nut username. So these files won’t drop in and work anywhere.
The dummy driver will need to be installed and configured.
Mine also have several layers of timers on battery an online:
Most configs would have the client side cancel their timers if power returns. In my case I don’t want that because I prefer more certainty of state so that I know it’s safe to power cycle an outlet to bring a device back up. My NUT server runs on an old pi 3b with a read-only file system. So it never needs a safe shutdown. It’s the last man standing to bring everything else back up if the UPS returns to line power before the battery is exhausted. That’s why there is no local shutdown on the NUT server config.
Each
snmpset…is a truncated version of an outlet power command.Also, the wall commands were a debug aid. Uncomment to use, but test a command first. Wall doesn’t work on some distros.
NUT Server
NUT.CONF:
MODE=netserverUPS.CONF:
UPSD.CONF:
UPSD.USERS:
UPSMON.CONF:
UPSSCHED-CMD
NUT Client
NUT.CONF
MODE=netclientUPS.CONF
maxretry = 3UPSD.CONF
# emptyUPSD.USERS
# emptyUPSMON.CONF
UPSSCHED.CONF
UPSSCHED-CMD