Red Hat Bugzilla – Bug 495435
exec "init 7" and the tty will hang
Last modified: 2014-03-16 23:18:18 EDT
Description of problem:
Version-Release number of selected component (if applicable):
Red Hat Enterprise Linux 5.2 and 5.3
run a terminal at tty 1 -6 or X11, not ssh and other remote login.
and exec command "init 7",
then you will see system hang here.
tty 1- 7 stop.
you can not press anything, but server still run. you can ssh to the server.
Steps to Reproduce:
1.run command: init 7
init tell no this runlevel and quit.
init will stop the tty that current runlevel opened， then open the tty that new runlevel setted .
/etc/inittab has no information about runlevel 7 8 9，so after you exec runlevel 7 8 9，system will stop the tty current level open， but do nothing action to init the new runlevel's tty.
I think you kan add a "if" to check the new runlevel wether is setting, if no, tell user and quit.
7-9 are valid runlevels as far as init is concerned; if there's nothing configured for them, it will run nothing.
(In reply to comment #1)
> 7-9 are valid runlevels as far as init is concerned; if there's nothing
> configured for them, it will run nothing.
I don't think so.
I try it on my computer,
tty 1 to 7 will stop.(Like hang)
But other like service , network still OK .
Correct, because there's nothing that says network should be stopped in runlevel 7.