Pending patches

Denys Vlasenko vda.linux at googlemail.com
Fri Nov 14 01:28:51 UTC 2008


On Thursday 13 November 2008 23:23, Vladimir Dronnikov wrote:
> >
> > I thought you do umount -r "Try to remount devices as read-only
> > if mount is busy" thing. From reboot POV, RO filesystems
> > are as safe as umounted ones.
> >
> > Does it work?
>
> Seems it does. Though I get a storm of runsv complains about they can not
> write to RO FSs. I can leave with this.

You should kill them first. killall5 -TERM, then wait a second or so
to let them die. Optionally follow with killall5 -KILL and sleep 1
for especially stubborn ones. Then umount -r.

> I'd like then to suggest you to remove -s option from runsvdir. It adds
> unnecessary bloat, not compatible and can be easily replaced with a special
> runsv "service" (say, reboot) which is initially down and wraps in its ./run
> script the functionality of reboot.sh.

Here we go again.

It's you who asked runsvdir to "make possible to use as init",
not my idea. I am totally happy with my init being a shell script -
no additinal hacking required.

runsvdir needs special hacks in order to be used as init
because you want to make it stop and not restart runsv's.

It's true that reboot actions (killall5 + umount)
are perfectly doable by any root process
(and I told so 999 times).

But you do need runsvdir -s stript, at least trivial one:

#!/bin/sh
while true; do sleep 999; done

just to make it stop respawning runsv's you are killing.

(oops, problem here. second killall5 ("killall5 -KILL")
will *kill the script*! what to do?...)

If you would run runsvdir NOT as init, but as ordinary process,
then you do not need this script, because killall5 -TERM
will kill runsvdir too - exactly what you need.
--
vda



More information about the busybox mailing list