[Nut-upsuser] Synology NAS is shutting down Ubuntu servers after very brief power outage

Roger Price roger at rogerprice.org
Mon Aug 3 06:06:36 BST 2020


On Sun, 2 Aug 2020, Todd Benivegna wrote:

> How would you write the SHUTDOWNCMD line with multiple commands?  I’ve been looking at the manual and see that you have to escape the internal “ but am
> still a little confused on how to do this exactly.

  SHUTDOWNCMD "logger -t upsmon.conf \"UPS status is [$( upsc myups ups.status )]:$( upsc myups battery.charge )\" ; /sbin/shutdown -h +0"

should log something like

  UPS status is [OL]:100

It might be useful to have a shell function to generate that output text.

Roger


More information about the Nut-upsuser mailing list