On Thursday 17 August 2006 21:52, Johan Pramming wrote: > I have added the following to /etc/rc.shutdown:
> if (test -f /etc/killpower)
Isn't this csh scripting..? (and rc.shutdown is sh)
Anyway..
I modified /usr/local/etc/rc.d/nut.sh to check for /etc/killpower by modifying
the poststop function.. eg
nut_poststop() {
${nut_prefix}/libexec/nut/upsdrvctl stop
if [ -r /etc/killpower ]; then
rm -f /etc/killpower
${nut_prefix}/libexec/nut/upsdrvctl -v shutdown
fi
}
I have ondelay = 13 and offdelay = 120 in my ups.conf (MGE Pulsar EX) so the
system gets 2 minutes to shut down gracefully.
> I dropped the sleep command, as it doesn't have the desired effect on
> FreeBSD.
FreeBSD doesn't remount file systems read-only so it has a detrimental
effect :)
> Is it at all possible with the PowerMust driver?
I've never used PowerMust, hopefully someone else can answer your query.
--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
pgpmdA0gxMLAe.pgp
Description: PGP signature
_______________________________________________ Nut-upsuser mailing list [email protected] http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser

