|[Home] [Credit Search] [Category Browser] [Staff Roll Call]||The LINUX.COM Article Archive|
|Originally Published: Thursday, 19 October 2000||Author: Mike Baker|
|Published to: interact_articles_irc_recap/IRC Recap||Page: 1/1 - [Printable]|
Best of IRC for Thursday, October 19th!
It's time once again for another edition of Best of IRC. As always, we'll be taking an in-depth look at some of the questions asked on #Linuxhelp. If you haven't already been to #Linuxhelp, you'll find instructions on how to get there at the bottom of the Live! page. Feel free to stop by!
|Page 1 of 1|
inittabHow do I add more terminals?
When you load Linux, the first process to load after the kernel initialization is a process called init. Within init there are several modes of operation, these modes of opperation are called runlevels. The common runlevels tend to be 0 (shutdown), 1 (single user), 3 (multiuser), 5 (X11), 6 (reboot). The idea being that you can set the runlevel depending on the task to be performed; if you want to bootup and fix something without any programs loading that's runlevel 1. If you want to boot directly into an X11 login screen that's usually runlevel 5.
So how do you use the various runlevels? When you're booting Linux and you get the LILO boot: prompt, type in the name of the kernel you wish to boot, typically "linux" followed by a runlevel: LILO boot: linux 1
Linux will proceed to boot and switch into the appropriate runlevel. Note that if your system simply says LILO on bootup, hit ctrl to get a prompt. The other way to switch runlevels is via the init command. The init command will allow you to dynamically change your runlevel without restarting, e.g.: init 5
So, what does this all mean? If you want to add anything to the startup procees the places to look are the init config files, namely /etc/inittab. The inittab is 4 fields separated by a colon (:). The fields represented are <name>:<runlevels>:<action>:<command>. The names given are arbitrary, the important fields are the runlevels, action and command. A typical inittab might look something like this:
So, you want to add another virtual terminal? Simple, just edit /etc/inittab and add one. 7:23:respawn:/sbin/getty 38400 tty7
After editing inittab you'll need to run the command init q for changes to take effect. Note that with a terminal on tty7 your X will relocate to tty8 which is the first terminal not in use. CTRL-(left)ALT-F1 through CTRL-(left)ALT-F12 will give you the first 12 terminals, CTRL-(right)ALT-F1 through CTRL-(right)ALT-F12 gives you the next 12. Technically it's ALT-F* to switch consoles but CTRL-ALT-F* works regardless of if you're in X11 or not. It's also possible to switch terminals with ALT-LEFTARROW and ALT-RIGHTARROW.
|Page 1 of 1|