Hi Laurent ! > It is still necessary to have some minimal hook in init, so that >init stops monitoring processes during the shutdown procedure.
Yes! After activating brain I got to same. init shall create a named pipe (fifo, e.g. /dev/init) and held open the read end of the pipe. As soon as data is available on this pipe init shall stop normal processing and exec to restart action/script with the read end of the pipe on stdin of the script. To shutdown the system we have to write the type of shutdown to the fifo. The script can read this info and determine action. One solution for unlimited number of clean shutdown cases. No need to have init do any other shutdown action. Everything controlled by final script. halt/reboot/poweroff without -f just write single character "H" / "R" / "P" followed by a newline to fifo. May be extended to any number of cases without need to add anything further to init. script may even restart init and resume normal operation after doing some processing. This is just a suggestion. The easy and extendable way I think. -- Harald _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
