Linux Booting
Linux Booting
Have you ever wondered what happens in the background from the time you press
the Powerbutton until the Linux login prompt appears?
The Linux boot process is the procedure for initializing the system. It consists of
everything that happens from when the computer power is first switched on until the
user interface is fully operational.
Once you start using Linux, you will find that having a good understanding of the
steps in the boot process will help you with troubleshooting problems as well as with
tailoring the computer's performance to your needs.
Click the image to view an enlarged version.
The BIOS software is stored on a ROM chip on the motherboard. After this, the
remainder of the boot process is completely controlled by the operating system.
Text-Mode Login
Near the end of the boot process, init starts a number of text-mode login prompts
(done by a program called getty). These enable you to type your username,
followed by your password, and to eventually get
a command shell.
Usually, the default command shell is bash (the
GNU Bourne Again Shell), but there are a
number of other advanced command shells
available. The shell prints a text prompt,
indicating it is ready to accept commands; after
the user types the command and presses Enter,
the command is executed, and another prompt is
displayed after the command is done.
As you'll learn in the chapter 'Command Line
Operations', the terminals which run the command shells can be accessed using
the ALT key plus a function key. Most distributions start six text terminals and one
graphics terminal starting with F1 or F2. If the graphical environment is also
started, switching to a text console requires pressing CTRL-ALT + the appropriate
function key (with F7 or F1being the GUI). As you'll see shortly, you may need to
run the startx command in order to start or restart your graphical desktop after you
have been in pure text mode.
X Window System
Generally, in a Linux desktop system, the X Window System is loaded as the final
step in the
boot process.
A service
called
the display
manager kee
ps track of the
displays being
provided, and loads the X server (so-called because it provides graphical services to
applications, sometimes called X clients). The display manager also handles
graphical logins, and starts the appropriate desktop environment after a user logs in.