Hi,
I am unable to get upssched working correctly as my UPS calls low battery too 
late and there is no way to change it.
I am running Nut 2.7.3 on Ubuntu 14.04
I have made this script, called /sbin/upssched-cmd.sh
#!/bin/sh case $1 in   onbatt)     /sbin/upsmon -c fsd;;   *)     echo 
"shutdown implemented";; esac
I am trying to run the script manually to break down my issues. All that 
happens when I run the script is I get the echo script but no shutdown, 
effectively the script doesn't seem to run the command /sbin/upsmon -c fsd . I 
have run this command from the command line and the system shuts down as 
expected.:
root@unifi:/sbin# ./upssched-cmd.shshutdown implemented
Command run manually works just fine:
root@unifi:/# upsmon -c fsdNetwork UPS Tools upsmon 2.7.3
Broadcast Message from nut@unifi        (somewhere) at 13:40 ...
Executing automatic power-fail shutdown


Broadcast Message from nut@unifi        (somewhere) at 13:40 ...
Auto logout and shutdown proceeding

Broadcast message from root@unifi        (unknown) at 13:40 ...
The system is going down for reboot NOW!

Permissions are:
root@unifi:/sbin# ls -la upssched-cmd.sh-rwxrwx--- 1 root root 107 Apr 27 13:33 
upssched-cmd.sh
I have the command pointing at the correct place:
unifi@unifi:~$ command -v upsmon/sbin/upsmon
Any help appreciated. All I am looking to do is shutdown this master upsd and 
send shutdown requests to 2 other slaves after 10 mins of the UPS going onto 
battery.
Cheers,
James


                                          
_______________________________________________
Nut-upsuser mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/nut-upsuser

Reply via email to