Skip to main content
Engineering LibreTexts

07-A.1: Configuring Boot Components

  • Page ID
    1.1 Explain Linux boot process concepts
    1.4 Given a scenario, manage storage in a Linux environment

    Module Objectives

    The learning objectives for this module are as follows:

    • Explain how to configure boot components in Linux
    • Configure initial ramdisk to load a temporary root file system into memory
    • Describe the components of the Linux boot process
    • Recognize and troubleshoot issues related to a kernel panic during the boot process

    The Boot Process

    The boot process can be initiated in one of a couple ways. First, if power is turned off, turning on the power will begin the boot process. If the computer is already running a local user, including root or an unprivileged user, the user can programmatically initiate the boot sequence by using the GUI or command line to initiate a reboot. A reboot will first do a shutdown and then restart the computer.

    Booting a Linux installation involves multiple stages and software components, including firmware initialization, execution of a boot loader, loading and startup of a Linux kernel image, and execution of various startup scripts and daemons. For each of these stages and components there are different variations and approaches.

    The Boot Loader

    A boot loader is a small, simple program responsible for loading the Linux kernel with optional kernel parameters and the Linux initial RAM disk, known as initrd. Linux kernel is the core of the Linux operating system, and it starts the init (short for initialization) process, or an init replacement such as systemd, immediately after being loaded. The Linux initial RAM disk provides a temporary storage space for loading critical files into memory before the real root file system can be mounted.

    The boot loader phase varies by computer architecture. Since the earlier phases are not specific to the operating system, the BIOS-based boot process for x86 and x86-64 architectures is considered to start when the master boot record (MBR) code is executed in real mode and the first-stage boot loader is loaded. In UEFI systems, a payload, such as the Linux kernel, can be executed directly.

    GRUB 2 has two (optionally three) stages and is capable of automatic detection of various operating systems and automatic configuration. The first-stage loader (stage1) is loaded and executed either by the BIOS from the master boot record (MBR) or by another boot loader from the partition boot sector. Its job is to discover and access various file systems that the configuration can be read from later. The optional, intermediate stage loader (stage1.5) is loaded and executed by the first-stage loader in case the second-stage loader is not contiguous, or if the file-system or hardware requires special handling in order to access the second-stage loader. The second-stage loader (stage2) is loaded last and displays the GRUB startup menu that allows the user to choose an operating system or examine and edit startup parameters. After a menu entry is chosen and optional parameters are given, GRUB loads the kernel into memory and passes control to it.

    The BIOS

    BIOS is an acronym for Basic Input/Output System. It is firmware used to perform hardware initialization during the booting process (power-on startup), and to provide runtime services for operating systems and programs.

    The BIOS setup screen allows you to configure certain parameters that take effect as the computer boots up.
    Figure \(\PageIndex{1}\): BIOS Screen. ("BIOS Settings" by Patrick McClanahan is licensed under CC BY-SA 4.0)

    The BIOS firmware comes pre-installed on a personal computer's system board, and it is the first software to run when powered on.

    The BIOS in modern PCs initializes and tests the system hardware components, and loads a boot loader from a mass memory device which then initializes an operating system. In the era of DOS, the BIOS provided a hardware abstraction layer for the keyboard, display, and other input/output (I/O) devices that standardized an interface to application programs and the operating system. More recent operating systems do not use the BIOS after loading, instead accessing the hardware components directly.


    The Unified Extensible Firmware Interface (UEFI) is a specification that defines a software interface between an operating system and platform firmware. UEFI replaces the legacy Basic Input/Output System (BIOS) firmware interface originally present in all IBM PC-compatible personal computers,[1][2] with most UEFI firmware implementations providing support for legacy BIOS services. UEFI can support remote diagnostics and repair of computers, even with no operating system installed.

    Just like the BIOS, UEFI is an environment in which to execute a boot loader, and both eventually execute the operating system.

    Server Security

    As long as we are discussing BIOS/UEFI, its a good time to mention the idea of password protecting the boot sequence. Many Linux system administrators make use of the capability that both BIOS and UEFI have to put a password on the boot sequence. This prevents someone from gaining access to a corporate server, simply rebooting it and taking control. Sometimes it takes a bit of searching around in the BIOS/UEFI menu to find the place to enter a password. As there is greater focus being placed on security - both hardware and software - this is something to consider.

    Adapted from:
    "Linux startup process" by Multiple contributors, Wikipedia is licensed under CC BY-SA 3.0
    "BIOS" by Multiple contributors, Wikipedia is licensed under CC BY-SA 3.0
    "Unified Extensible Firmware Interface" by Multiple contributors, Wikipedia is licensed under CC BY-SA 3.0

    • Was this article helpful?