Tutorials: Under the Hood: How the Linux Kernel and systemd Boot Your System
![]() |
| Tutorials: Under the Hood: How the Linux Kernel and systemd Boot Your System |
The Linux boot process follows a strict, step-by-step sequence to transition your system from a powered-off state into a fully usable operating system.
Here is a breakdown of the 6 core stages of the Linux boot sequence:
1. BIOS / UEFI (Hardware Initialization)
When you press the power button, the system motherboard runs its firmware—either the traditional BIOS (Basic Input/Output System) or the modern UEFI (Unified Extensible Firmware Interface).
POST (Power-On Self-Test): The firmware initializes and checks your hardware components (RAM, CPU, storage drives, graphics card).
MBS/EFI Detection: Once the hardware passes the test, BIOS searches for a Boot Sector (Master Boot Record - MBR) on the primary drive. UEFI skips the MBR search and reads its configurations directly from a dedicated system partition called the ESP (EFI System Partition) to find a bootloader file (
.efi).
2. Bootloader (GRUB2)
The firmware hands complete control over to the bootloader program. On most modern Linux distributions (like Ubuntu or Fedora), this is GRUB2 (Grand Unified Bootloader v2).
User Menu: GRUB displays a splash menu allowing you to select your preferred Linux kernel version or a different operating system.
Loading to RAM: Once a selection is made, GRUB2 loads the compressed Linux Kernel image and a temporary root filesystem (initramfs) directly into the system's RAM.
3. The Kernel Stage
The Kernel acts as the core controller of the entire operating system. As soon as it uncompresses in memory, it takes charge:
Hardware Configurations: It scans and initializes all underlying hardware devices using built-in modules and drivers.
Mounting Root: It mounts the temporary virtual file system (initramfs or Initial RAM Filesystem). This temporary filesystem contains just enough basic drivers (like storage controller and storage network drivers) to let the kernel locate and mount the actual physical root file system (
/) on your drive.
4. The Init Process (systemd)
Once the real physical root filesystem (/) is safely mounted, the kernel frees up the temporary memory space and launches the very first user-space process.
PID 1: This process is assigned a Process ID of 1 (PID 1). On almost all modern Linux systems, this init process is
systemd.All other processes on your machine are direct or indirect children of this parent process.
5. systemd Target Initialization
Instead of old-school SysV "runlevels", systemd uses Targets to manage which services and daemons should launch during startup. It resolves script dependencies in parallel to maximize boot speeds:
multi-user.target: Loads the CLI environment, networking configurations, and system logging services.graphical.target: If you are running a desktop environment, this target activates right aftermulti-user.target, launching your display server (Xorg/Wayland) and your graphical login manager.
6. Display Manager & Desktop
The boot process officially concludes when systemd launches your Display Manager (like GDM, SDDM, or LightDM).
The system displays your graphical login screen.
Once you type in your credentials, the system spins up your user session desktop environment (GNOME, KDE Plasma, XFCE, etc.) alongside any background startup applications.
Quick Summary Checklist
[Power On]
└──> BIOS/UEFI (Hardware POST)
└──> GRUB2 Bootloader (Loads Kernel & initramfs)
└──> Kernel (Initializes drivers & mounts root /)
└──> systemd (PID 1 starts core services)
└──> Graphical Target (Launches Login Screen)
Download zone : ------------------------------------------------------------------------
👉 linux_shell_commands_cheat_sheet.pdf_
👉 [Download "Python Notes for Professionals" for Free Here] (Insert your link here: https://goalkicker.com/PythonBook/PythonNotesForProfessionals.pdf)
Have you read this book yet? Let me know your favorite Python tip or trick in the comments below!
📥 Linux Magazin Ro (July 2026)
Stop wasting hours filtering through fragmented, outdated forum posts. Equip your digital toolkit with clean, verified, and reproducible technical blueprints.
👉 Download the Complete Open-Source & Tech Compilation on Gumroad Now!
Have questions about any of the configurations or setup guides included in the PDF? Drop a comment down below and let's discuss!
Simply click the link below to download the PDF, print your favorite puzzles, and start solving!
👉 [[Download 100_sudoku_puzzles.pdf Here]]
*If you enjoy these puzzles, I would love to hear your feedback
-------------------------------------------------------------------------------------------------------------------

Comments
Post a Comment