Eu instalei o Nut no servidor Ubuntu 16.04 para me conectar com o meu Eaton 5SC-750, seguindo
Parece-me que um Shutdown forçado está sendo emitido em vez de executar o script fornecido pelo guia. Por quê? e como faço para corrigir isso?
Eu gostaria que ele fosse executado com bateria por 2 minutos antes de desligar. Eu pretendo conectar um segundo servidor (como escravo em Nut) a este no-break.
Aqui estão as entradas do syslog de desligamentos de comutação para bateria:
Feb 3 14:49:17 Hutch upsmon[1252]: UPS philip@localhost on battery
Feb 3 14:49:17 Hutch upsmon[1252]: Signal 10: User requested FSD
Feb 3 14:49:17 Hutch upsd[1235]: Client monuser@::1 set FSD on UPS [philip]
Feb 3 14:49:17 Hutch upsmon[1252]: Executing automatic power-fail shutdown
Feb 3 14:49:17 Hutch upsmon[1252]: Auto logout and shutdown proceeding
Conteúdo do arquivo de configuração (menos comentários):
nut.conf
MODE=standalone
ups.conf
[philip]
driver = usbhid-ups
port = auto
desc = "Eaton 5SC750 UPS"
upsd.conf
LISTEN 127.0.0.1 3493
LISTEN ::1 3493
LISTEN 203.192.151.2 3493
upsd.users
[admin]
password = ********
actions = SET
instcmds = ALL
[monuser]
password = *********
instcmds = ALL
upsmon master
[monuserc]
password = ********
upsmon slave
[monuserv]
password = ********
upsmon slave
upsmon.conf
[monuser]
password = ********
#actions = SET FSD
instcmds = ALL
upsmon master
[monuserslave]
password = ********
upsmon slave
MINSUPPLIES 1
SHUTDOWNCMD "/sbin/shutdown -P now"
NOTIFYCMD /etc/nut/notifycmd
POLLFREQ 5
POLLFREQALERT 5
HOSTSYNC 15
DEADTIME 15
POWERDOWNFLAG /etc/killpower
NOTIFYFLAG ONLINE SYSLOG+WALL
NOTIFYFLAG ONBATT SYSLOG+WALL+EXEC
NOTIFYFLAG LOWBATT SYSLOG+WALL+EXEC
NOTIFYFLAG FSD SYSLOG+WALL
NOTIFYFLAG COMMOK SYSLOG+WALL
NOTIFYFLAG COMMBAD SYSLOG+WALL
NOTIFYFLAG SHUTDOWN SYSLOG+WALL
NOTIFYFLAG REPLBATT SYSLOG+WALL
NOTIFYFLAG NOCOMM SYSLOG+WALL
NOTIFYFLAG NOPARENT SYSLOG+WALL
FINALDELAY 5
/ etc / nut / notifycmd
#!/bin/bash
#
# NUT NOTIFYCMD script
PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/sbin:/usr/local/bin
trap "exit 0" SIGTERM
if [ "$NOTIFYTYPE" = "ONLINE" ]
then
echo $0: power restored | wall
# Cause all instances of this script to exit.
killall -s SIGTERM 'basename $0'
fi
if [ "$NOTIFYTYPE" = "ONBATT" ]
then
echo $0: 2 minutes till system powers down... | wall
# Loop with one second interval to allow SIGTERM reception.
let "n = 120"
while [ $n -ne 0 ]
do
sleep 1
let "n--"
done
echo $0: commencing shutdown | wall
upsmon -c fsd
fi
Obrigado