[PLUG] how to force a reboot with no working rootfs?

Jason R. Martin nsxfreddy at gmail.com
Wed May 3 16:38:59 UTC 2006


On 5/3/06, Eli Stair <eli.stair at gmail.com> wrote:
> If you have /proc mounted, you can enable a reboot-on-hang bit...
> don't remember offhand which entry in sys... there are ways to also
> manipulate an immediate reboot with some simple C code without all the
> libs necessary for shutdown (check busybox sources).  Alternately, I
> recall reading in the docs about embedding magic sysreq functions
> (which should allow you to force sync/unmount and reboot).

I'd go with the sysrq route, read sysrq.txt from the kernel
Documentation directory.  You should be able to enable the sysrq stuff
in /proc/sys/kernel/sysrq (assuming it was turned on in your kernel
build) and trigger lots of interesting things, including the reboot,
by writing the values from the file to /proc/sysrq-trigger.

Jason



More information about the PLUG mailing list