www.nico.schottelius.org/software/cinit/browse_source/cinit-0.3pre7/doc/braindumps/shutdown.text
Nico Schottelius 423ba10303 import cinit from unix.schottelius.org
Signed-off-by: Nico Schottelius <nico@ikn.schottelius.org>
2009-09-16 12:53:45 +02:00

40 lines
987 B
Text

cinit - braindumps - shutdown
=============================
Nico Schottelius <nico-cinit@@@@schottelius.org>
v0.1, for cinit-0.3, 2007-01-11
:Author Initials: NS
Just some braindumps. Do not read.
Introduction
------------
Shutting down the system.
When?
-----
- reboot
- halt
- power off
- further needed?
How / What?
------------
- Stop services in the correct order
* reuse the service tree / needs / needed_by!
* call off, if existent
* if respawning, send SIGTERM?
- not if off is existent?
* give some variables to off?
- $RESPAWN_PID: if respawning
- send SIGTERM to other apps?
* or put that into special? special/post_svc_shutdown
- call special/{halt,poweroff,reboot}
- implement timely controlled shutdown:
* cinit.shutdown forks (?) itself and waits, then sends a signal
to cinit to initiate the shutdown process
- also implement halt
* kill -TERM 1
- also implement reboot
* kill -HUP 1
- also implement reboot
* kill -USR1 1