Subject: Re: shutdown over ssh
To: Martin Ammermueller <firstname.lastname@example.org>
From: Matthias Buelow <email@example.com>
Date: 06/07/2001 23:38:56
Martin Ammermueller writes:
>> Naturally, the ksh prints its prompt when the process group leader from
>> the foreground process group exits (and thus control is transferred
>> back to the shell.) The other shells should do this aswell, but since
>All shells I used before never returned to the controlling tty after the
>shutdown command. I also think that it's useless that someone can execute
>commands like cp and mv after the OS synced the disks.
The time window with "-r now" is probably too small to see this
happen often. Nevertheless, the shell doesn't treat a command
named "shutdown" any different from any other command of course.
You can enlargen the time window, for example to 5 minutes by typing
"shutdown -r +5" and you will see that shutdown puts itself into the
background (or rather, forks a background job) and terminates the
foreground job so that control is transferred back to the shell.