[BusyBox] Reboot not working?

Erik Andersen andersen at codepoet.org
Sat Nov 10 05:49:35 UTC 2001


On Thu Nov 08, 2001 at 02:15:14PM -0500, Scott Murray wrote:
> The reboot/halt applets in busybox normally rely on the init applet being
> turned on, as they just send a signal to it to trigger the reboot/halt.
> I'm attaching the patch I use against 0.60.1 to make reboot/halt call the
> syscall directly if the init applet is turned off.
> 
> Erik, is there any chance you could apply this, or tell me what you'd
> like cleaned up so that you'd consider applying it?

I suppose I can see the value in something like this, though it
will be awfully rude about how it shuts down the system.  I think
I would prefer to have a libb/bb_shutdown.c added and used when
busybox init is not enabled.  It would do something comparable to
what busybox init does to shutdown the system, i.e. send a
sigterm, sleep, then a sigkill, then a sleep, then call reboot or
poweroff or halt, then sleep forever (in case that fails).  And
having it print the appropriate message to the syslog (so the
kernel will spam the console) would be a good thing too...  With
some care, the shutdown routines could be ripped out of init and
used directly by reboot and friends when init is not enabled.  I
think that type of a solution would be the best.  Agreeable?

> Scott Murray
> SOMA Networks, Inc.

Ever read "A Brave New World" by Aldous Huxley?

 -Erik

--
Erik B. Andersen             http://codepoet-consulting.com/
--This message was written using 73% post-consumer electrons--





More information about the busybox mailing list