Here is the halt script I'm currently using. I haven't done any extra
programming at this point and am just using the bat3 daemon with the
shutdown parameter. It issues the 'shutdown -h now', which in turn
invokes the halt script.
#! /bin/sh
# halt Execute the halt command.
PATH=/sbin:/bin:/usr/sbin:/usr/bin
pid=$(ps -ax |grep bat3 |sed 's/^ *//' |cut -d' ' -f1)
echo ; echo $pid ; echo
kill -SIGHUP $pid
echo "unmount cf"
umount /mnt/cf
echo "remove battery backup: note halt will not get called so this
will have to be good enough"
ups-monitor
halt
--- In "PeterElliot" <> wrote:
>
> Hi Mike,
>
> When I halt the ups-monitor is performed much later after the
> filesystems have all closed. Where did you place the ups-monitor
> poweroff within the shudown scripts? I'm not too familiar with Linux,
> so I don't know if I've missed the shutdown -h case, but I placed the
> ups-monitor poweroff in the halt script.
>
> I'm looking to modify the bat3 program to add an additional command
> to remove the need to kill the bat3 program prior to running ups-
> monitor, but this - as you state - would need to delay before
> powering off in a full boot condition.
>
> I've been working with Michael at Technologic Systems whose been very
> helpfull getting me through the errors located between my chair and
> the keyboard...
>
> Regards,
>
> PJE
>
>
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/ts-7000/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/ts-7000/join
(Yahoo! ID required)
<*> To change settings via email:
<*> To unsubscribe from this group, send an email to:
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|