GRUB & rescue boot.
When the system won't boot, GRUB is your seat at the wheel. Edit the kernel command line for one boot, drop into rd.break to reset root, or boot into rescue/emergency targets to fix fstab. This is the lesson that turns a 3 a.m. call into a 3-minute fix.
GRUB and rescue boot animated tutorial. Editing the GRUB menu with 'e', adding rd.break or init=/bin/bash to the kernel command line, single-user mode, rescue.target and emergency.target, password reset workflow with SELinux relabel, and persisting changes with grubby. RHCSA EX200 ready.When the system won't boot or you've lost root, GRUB is your seat at the wheel. Six steps from menu to fix.
- Β·The boot-process lesson
- Β·Comfortable in a Bash shell
- Β·SELinux contexts lesson (relabel concept)
Edit the GRUB cmdline for one boot, use rd.break to reset root, drop into rescue/emergency targets, and persist cmdline changes with grubby.
pace: 9 minutes
The GRUB menu β your one chance to intervene
On boot, GRUB shows a menu listing kernel entries (current, previous, rescue). It auto-boots the highlighted entry after a few seconds β press any key to pause the timeout. β/β to pick; press `e` to EDIT the selected entry for ONE boot (great for rescue), or `c` to drop to a GRUB command line. Whatever you do here doesn't persist unless you also run grubby afterwards.
$press any key$press e$press cGRUB editing is one-shot rescue; grubby is permanent. After rd.break, two things are non-obvious but mandatory: mount -o remount,rw /sysroot and chroot /sysroot. And after any write inside the rescue chroot, touch /.autorelabel to keep SELinux happy. Forget that and login fails after reboot.
$[in GRUB] e$[in GRUB] Ctrl-X / F10$append: rd.break$append: init=/bin/bash$append: single$append: systemd.unit=rescue.target$append: systemd.unit=emergency.target$mount -o remount,rw /sysroot$chroot /sysroot$passwd root$touch /.autorelabel$systemctl isolate rescue.target$systemctl default$grubby --info=ALL$grubby --update-kernel=ALL --args="X"$grub2-mkconfig -o /boot/grub2/grub.cfgYou can't log in as root and SSH key auth isn't set up. You're at the GRUB menu. What's the move?
What's the difference between rescue.target and emergency.target?
You appended an arg in the GRUB editor and it worked. Two days later, after a reboot, the arg is gone. Why, and how do you make it stick?
After rd.break, you're in a shell with / mounted at /sysroot. What two things must you do before commands like `passwd root` behave normally?
These aren't graded β they're just for active recall, which is what actually makes the lesson stick.
Kernel parameters & tuned
Every cmdline arg you add here is a boot-time kernel parameter. See the full picture β boot args vs sysctl, and how tuned bundles them.
keep going β these pair well with what you just learned.
SELinux contexts
Why Apache can't read your file. Watch the policy engine decide β and learn the workflow for fixing denials. RHCSA-ready.
Linux boot process
From power button to login prompt. Every stage in the chain β UEFI, GRUB, kernel, initramfs, systemd β with the rescue moves that save you. RHCSA-ready.
LVM stacking
Layer-by-layer build of an LVM stack: disks β PVs β VG β LVs β filesystem. Then extend live and snapshot. RHCSA-ready.