The initramfs, the bootloader, and the rescue targets
Topic 202 is weight 9 and covers recovery, the initramfs and bootloaders. This guide reads what GRUB generated and what the kernel was actually told, opens the initramfs to count what is inside it, rebuilds one safely to a temporary file, compares the two families' boot layouts, and clears a machine that was genuinely reporting itself degraded.
201: System Startup Guide 25 of 29 Intermediate
- PlatformsUbuntu 26.04 LTS + AlmaLinux 10.2
- Block devicesone 50 GB disk
- TimeAbout 26 min
| Server Name | IP Address | OS | Roles | CPU | RAM | HDD |
|---|---|---|---|---|---|---|
| LPIC2-A01 | 192.168.0.78 | Ubuntu 26.04 LTS | Primary service host - BIND, Apache, Samba, Postfix. Topic 204 RAID runs on loop devices; this machine has no spare disk | 2 Core | 4 GB | 50 GB |
| LPIC2-B01 | 192.168.0.79 | AlmaLinux 10.2 | Second service host - nginx, NFS, DNS secondary, and the other family's spelling of each service | 2 Core | 4 GB | 50 GB |
This guide includes
Use this before you need it - the day a machine does not boot is the wrong time to learn where its bootloader configuration lives. This matters because the file you edit is not the file that boots, and because a machine can run perfectly while reporting itself degraded over units whose packages were removed months ago.
- finding the firmware type, the generated config, and the file you are meant to edit
- comparing what GRUB wrote with what the running kernel was actually given
- listing the initramfs and counting the modules it carries to mount the root filesystem
- rebuilding an initramfs to a temporary file, without touching the one that boots
- reading
rescue.targetagainstemergency.target, and clearing a degraded system
Before you start
- boot-order-and-what-delayed-it
-
Which bootloader, and where it keeps its mind
-
What the kernel was actually told
-
Inside the initramfs
-
Building one, without touching the one that boots
-
The targets you boot into when something is broken
-
A machine that reports itself degraded
-
The same boot directory, two layouts
-
Putting the machine back