Pino Mauro
2006-Sep-13 15:18 UTC
[Nut-upsuser] POWERDOWNFLAG (/etc/killpower) does not contain the upsmon magic string!!!
Hi to all, i install nut and it's work perfectly but when i start upsmon i
recive the message:
POWERDOWNFLAG (/etc/killpower) does not contain the upsmon magic string
My upmon.conf contain:
MONITOR myups@theseo 1 orion91 carlos81 master
SHUTDOWNCMD "/sbin/shutdown -h +0"
HOSTSYNC 15
POWERDOWNFLAG /etc/killpower
FINALDELAY 5
My killpower scrit in /etc/killpower contain:
#!/bin/bash
if (test -f /etc/killpower)
then
echo "Killing the power, bye!"
/sbin/upsdrvctl shutdown
sleep 120
# uh oh... the UPS poweroff failed!
# you probably should reboot here to avoid getting stuck
# *** see the section on power races below ***
fi
Where is the problem! What's the upsmon magic string?
Help me please!
---------------------------------
Yahoo! Mail: gratis 1GB per i messaggi, antispam, antivirus, POP3
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20060913/e5acd922/attachment.html
Peter Selinger
2006-Sep-13 16:17 UTC
[Nut-upsuser] POWERDOWNFLAG (/etc/killpower) does not contain the
Pino Mauro wrote:> > Hi to all, i install nut and it's work perfectly but when i start > upsmon i recive the message: POWERDOWNFLAG (/etc/killpower) does not > contain the upsmon magic string > > ... > My killpower scrit in /etc/killpower contain: > > #!/bin/bash > > if (test -f /etc/killpower) > then > echo "Killing the power, bye!" > /sbin/upsdrvctl shutdown > > sleep 120 > > # uh oh... the UPS poweroff failed! > # you probably should reboot here to avoid getting stuck > # *** see the section on power races below *** > fi > > > Where is the problem! What's the upsmon magic string? > Help me please!Hi Pino, you are not supposed to put that script in /etc/killpower, but in your system's shutdown scripts. You should *not* create a file called /etc/killpower; that file is used by upsmon for internal purposes. The location of your shutdown scripts depends on your operating system; it could be something like /etc/rc.d/init.d/halt -- Peter
Arnaud Quette
2006-Sep-15 16:51 UTC
[Nut-upsuser] POWERDOWNFLAG (/etc/killpower) does not contain the upsmon magic string!!!
2006/9/13, Pino Mauro <pinomauro81@yahoo.it>:> Hi to all, i install nut and it's work perfectly but when i start upsmon i > recive the message: > POWERDOWNFLAG (/etc/killpower) does not contain the upsmon magic string > > My upmon.conf contain: > > MONITOR myups@theseo 1 orion91 carlos81 master > > SHUTDOWNCMD "/sbin/shutdown -h +0" > > HOSTSYNC 15 > > POWERDOWNFLAG /etc/killpower > > FINALDELAY 5 > > > My killpower scrit in /etc/killpower contain:do you mean the below script is named "/etc/killpower". if so, the problem is here since the file exist, and obviously can be created with the before mentioned magic! /etc/killpower is a flag created by upsmon upon shutdown, when an ups poweroff is needed.> #!/bin/bash > > if (test -f /etc/killpower) > then > echo "Killing the power, bye!" > /sbin/upsdrvctl shutdown > > sleep 120 > > # uh oh... the UPS poweroff failed! > # you probably should reboot here to avoid getting stuck > # *** see the section on power races below *** > fiArnaud -- Linux / Unix Expert - MGE UPS SYSTEMS - R&D Dpt Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/ Debian Developer - http://people.debian.org/~aquette/ OpenSource Developer - http://arnaud.quette.free.fr/