Re: Can't shutdown processes



On Friday 14 December 2001 08:37, crispin iinet net au wrote:
> > Do this if system is refusing to shutdown cleanly
> >
> > # cd /
> >
> > # killall5 -15 <-- relatively safe
> > (wait 3 sec)
> > # killall5 -9 <-- apps may lose data here
> > (wait 3 sec)
> > (repeat these killall5s several times)
>
> From this point on your shell will be dead, because you killed it, thus...

killall5 shouldn't kill processes in it's own process group.
I conducted an experiment just 2 minutes ago: sorry you're wrong...

But you have a point: this is fragile. I got intermixed shell and login 
prompts which looked confusing, but shell was responding to my commands.
I did three rounds of killall5 -15, killall5 -9, then "ps -AH e" to see
survivors :-)

Actually for shutting down my boxes I have a script which creates separate 
process group, disconnects from tty and does all this from there. Works 100% 
of the time even if started from X.

> > # sync
> > # umount -a -r -f
> > # sync
> > (wait 3 sec for disk cache writeout)
> > (Now hit red button)
>
> Youll never be able to type this in

Actually I typed xinit and writing this from that X session :-)
Will have to restart dhcpcd to be able to mail it, tho'...
--
vda



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]