The boot pipeline
Booting is a chain of handoffs. Firmware initializes hardware and chooses a boot entry. A bootloader loads the kernel and initramfs. The kernel initializes core hardware and starts the first user-space process. The init system starts services and login paths.
Knowing the chain helps troubleshooting. If firmware cannot find a boot entry, systemd logs are irrelevant. If a graphical login fails, the kernel probably already booted.
Firmware: BIOS vs UEFI
BIOS is the older boot style. UEFI is the modern firmware interface and commonly uses an EFI System Partition containing bootloader files. UEFI boot entries point to files such as EFI loaders.
Secure Boot is a UEFI feature that checks signatures for boot components. It can improve boot-chain trust, but it can also complicate custom kernels and drivers.
Bootloader, kernel loading, and initramfs
The bootloader chooses a kernel and passes options such as the root filesystem location. initramfs is a temporary early userspace image that helps the kernel find and mount the real root filesystem, especially when storage drivers, encryption, or logical volumes are involved.
After the real root filesystem is mounted, the system pivots from early boot into the installed system.
systemd or init
The first normal user-space process has PID 1. On many distributions, PID 1 is systemd. It starts units, tracks services, handles dependencies, collects logs through journald, and moves the system toward a target such as multi-user or graphical.
Other init systems exist, such as OpenRC on Alpine, but the concept remains: after the kernel, user-space startup must be coordinated.
Login manager, desktop session, and shell session
Desktop systems usually start a display manager such as GDM, SDDM, or LightDM. After login, it starts a desktop session. Terminal sessions start a shell, which may read startup files before showing a prompt.
Server systems may skip the graphical path and expose text login, SSH, or service workloads instead.
Boot troubleshooting basics
- Firmware screen appears but no OS: inspect UEFI boot order and EFI entries.
- Bootloader appears but kernel fails: check kernel options, initramfs, root filesystem, and recent updates.
- System reaches emergency mode: read the exact unit or mount failure and inspect journalctl -xb.
- Graphical login fails: switch to a text console and inspect display manager logs.
- Shell login is slow or broken: check shell startup files such as ~/.bashrc and ~/.profile.
journalctl -bsystemctl --failed