Getting >console to work in 10.4
Overview
Since 10.4, using the >console login from the login window has been, at best, sporadic. Many times, the error "Operation not supported by device" for /dev/console will be given. Here is a kludge to make it work, but must be repeated anytime the machine is restarted.
Read on for more detail
ttys
First, you must login as a normal user through the login window. Once here, open up a Terminal window and cd to /etc. There is a file, ttys which controls what actually handles /dev/console (among other things). Temporarily changing this file, handling a basic getty login, then changing the file back is the kludge here.
While in /etc, run
to have the original on hand. Next, edit ttys with your preferred editor (emacs, nano, pico, or vi and don't forget the sudo). What you want to do is uncomment the first line with console in it, which looks like
and make it look like
Then comment-out the second line about console, which should look like
and make it look like
Save and quit.
launchd
Now, tell launchd (successor to init) to reread the file:
Now logout, and a basic console-only login should be presented instead of the normal graphic login window.
Back to normal
Login to the console, then switch the ttys back and tell launchd again:
Logout again, and the graphic login window should be working again. However, using >console should also work as it once did.
On reboots
Just remember, this works until the machine is restarted, then it'd have to be done again, but until then, >console should work.
Update (2006-04-17)
Three things: First, when you do this you may see the "Operation not supported by device" several times before a login prompt shows. Each time this happens, you have to wait thirty seconds, so it could take a couple minutes.
Second, don't reboot with this setting in place, as otherwise you'll be sitting and staring at the "Starting Up" window forever. If you do have to reboot for whatever reason, be sure to boot in single user to put the ttys.orig back in place, otherwise you'll need to be able to ssh into the machine to fix it. This would entail putting the ttys back in place, HUPing launchd, and killing off getty and possibly a WindowServer process.
Finally, be sure to read Wout's comment below if you use ARD.
Since 10.4, using the >console login from the login window has been, at best, sporadic. Many times, the error "Operation not supported by device" for /dev/console will be given. Here is a kludge to make it work, but must be repeated anytime the machine is restarted.
Read on for more detail
ttys
First, you must login as a normal user through the login window. Once here, open up a Terminal window and cd to /etc. There is a file, ttys which controls what actually handles /dev/console (among other things). Temporarily changing this file, handling a basic getty login, then changing the file back is the kludge here.
While in /etc, run
sudo cp -p ttys ttys.orig
to have the original on hand. Next, edit ttys with your preferred editor (emacs, nano, pico, or vi and don't forget the sudo). What you want to do is uncomment the first line with console in it, which looks like
#console "/usr/libexec/getty std.57600" vt100 on secure
and make it look like
console "/usr/libexec/getty std.57600" vt100 on secure
Then comment-out the second line about console, which should look like
console "/System/Library/CoreServices/loginwindow.app/Contents/MacOS/loginwindow" vt100 on secure onoption="/usr/libexec/getty std.9600"
and make it look like
#console "/System/Library/CoreServices/loginwindow.app/Contents/MacOS/loginwindow" vt100 on secure onoption="/usr/libexec/getty std.9600"
Save and quit.
launchd
Now, tell launchd (successor to init) to reread the file:
sudo kill -1 1
Now logout, and a basic console-only login should be presented instead of the normal graphic login window.
Back to normal
Login to the console, then switch the ttys back and tell launchd again:
sudo mv /etc/ttys.orig /etc/ttys
sudo kill -1 1
Logout again, and the graphic login window should be working again. However, using >console should also work as it once did.
On reboots
Just remember, this works until the machine is restarted, then it'd have to be done again, but until then, >console should work.
Update (2006-04-17)
Three things: First, when you do this you may see the "Operation not supported by device" several times before a login prompt shows. Each time this happens, you have to wait thirty seconds, so it could take a couple minutes.
Second, don't reboot with this setting in place, as otherwise you'll be sitting and staring at the "Starting Up" window forever. If you do have to reboot for whatever reason, be sure to boot in single user to put the ttys.orig back in place, otherwise you'll need to be able to ssh into the machine to fix it. This would entail putting the ttys back in place, HUPing launchd, and killing off getty and possibly a WindowServer process.
Finally, be sure to read Wout's comment below if you use ARD.

4 Comments:
And if you get a blue screen with only a mouse pointer when you go to the console, then that's because the Apple Remote Desktop service is enabled.
I think that it sees you logging in, and then wants to scrape the screen. Unfortunately, in order to do so it switches to graphics mode, where you can't do anything to get out of it.
The way out of it is to ssh or ard in and kill the getty process.
Wout.
By
Wout Mertens, at March 3, 2006 6:33 AM
Or you could just use WIndows XP
By
Anonymous, at March 4, 2006 7:26 PM
...were the grass is always greener
and the screen bluer...
By
Anonymous, at March 28, 2006 10:11 PM
Now you can even run it on a Mac... I guess it won't be long until OSX is a thing of the past.
By
Anonymous, at April 25, 2006 1:15 PM
Post a Comment
<< Home