1. /etc/rc.shutdown, init, and the shutdown/reboot/halt commands
After learning of the ability to run a script (/etc/rc.shutdown) at
shutdown time in FreeBSD 2.2.5, I was somewhat surprised to discover
exactly how and when it is invoked!
My first attempts to run the shutdown script failed dismally. Every
time I did a "shutdown -h ..." or "shutdown -r ...", the system simply
shutdown. No script was run! I looked at the init code and it looked
like it should be run so I simply executed the command "kill -TERM 1"
and, lo and behold, the script ran as I expected it to.
Further investigation of the 'shutdown' program showed that a SIGTERM is
_NOT_ sent to init. It simply invokes the 'reboot' or 'halt' programs,
neither of which send a SIGTERM to init.
Given my habit of using shutdown/reboot/halt to bring a system down, I
am rather curious as to how the designer/coder of this new "feature"
intented it be used. Are we looking at incomplete functionality?
I can get around the problem by renaming shutdown, reboot, and halt to
something else and putting my own shutdown in their place that _DOES_ do
a kill -TERM on init but that seems rather kludgy!
Tony
2. ftape-HOWTO
3. PC does not reboot after `shutdown -r now/reboot'
4. 9Gb disk used in 6226 drawer ?
5. System Refuse to Shutdown or Reboot
6. Similar Questions by (??) Different People
7. Shutdown Problem - System Won't Reboot
8. filesystem question - what happens once a file reaches the 4 Gig limit on ext2fs?
9. Shutdown problem - system won't reboot
10. 'shutdown -r now' will NOT reboot system properly
11. System crashes (UFS related?) on reboot or shutdown
12. System doesn't reboot after 'shutdown -r '
13. corrupted file system: /etc directory overwritten by plain file