On 09/06/2015 16:24, Steve Litt wrote:
* killall5 -15; sleep 2; killall5 -9; sleep 2

* umount -a

* mount -o remount,ro /dev/sda1

* /sbin/halt or /sbin/reboot

Could somebody confirm which order these things come in?

 You got the right order.

 Note that killall5 is heavy, kludgy and System V-specific.

 If your shell has a "kill" builtin, you can simply replace
"killall5 -15" with "kill -15 -1", and "killall5 -9" with
"kill -9 -1". It will work on Linux.
 If your shell does not have a "kill" builtin, you're out of
luck, unless your script is running as process 1.

 This is one of the reasons why I advocate running the last part
of the shutdown procedure as process 1 - it makes the final nuke
easy and portable.

--
 Laurent

Reply via email to