10. Boot and init
One-liner. Firmware finds a bootloader, the bootloader loads a kernel and initramfs, the kernel starts PID 1.
Memorize
- UEFI/BIOS → bootloader (GRUB or systemd-boot) → kernel + initramfs.
- The initramfs carries the drivers needed to mount the real root (storage, LVM, encryption).
- The kernel initializes devices, mounts root, then executes
/sbin/init(systemd) as PID 1. - systemd brings up
default.targetand its dependencies;multi-user.targetis the server baseline. dmesgshows kernel messages from boot;journalctl -bshows the full boot log.- Failed boot usually means fstab, initramfs, or a broken bootloader — recovery is a live USB + chroot.
Trap. Rebuilding the initramfs after a storage change is easy to forget — the system won't boot. Do this. Run update-initramfs -u / dracut -f after changing LVM, encryption or drivers, then test a reboot.
Check
What is the initramfs responsible for?
Why
It is a small early userspace that bridges firmware/kernel and the real root device.