Linux Admin

Linux Kernel & Boot Errors: GRUB, kernel panic, initramfs, emergency mode

Kernel and Boot Errors

When a Linux box won’t boot, the diagnostic surface is much smaller than a running system: GRUB, the kernel command line, initramfs, and the root filesystem mount. Most boot failures fall into one of those four categories. The ten errors below are what you’ll see on the console of a non-booting server.

#71 – Kernel panic – not syncing

Description: Kernel encountered an unrecoverable error.

Common causes: Wrong root= UUID, missing initramfs module for the storage controller, hardware fault.

Solution: Boot a previous kernel from GRUB; mount root from rescue media and check /etc/fstab UUIDs against blkid; rebuild initramfs with update-initramfs -u -k all or dracut -f --regenerate-all.

#72 – GRUB: error: file `/boot/vmlinuz-X` not found

Description: Boot drops to the GRUB rescue prompt because the kernel image GRUB expects is missing.

Solution: Boot from rescue, mount root, chroot, then update-grub or grub2-mkconfig -o /boot/grub2/grub.cfg.

#73 – Cannot find boot device / VFS: Unable to mount root fs

Description: Kernel loaded but couldn’t find the root filesystem.

Solution: Common after disk replacement — UUID changed. Rescue boot, fix /etc/fstab with new UUIDs, regenerate initramfs.

#74 – emergency mode / dependency failed

Description: systemd dropped to emergency shell because a critical mount failed.

Solution: Login at the prompt; journalctl -xb for what failed; usually a stale fstab entry. systemctl daemon-reload + mount -a.

#75 – No init found

Description: Kernel boots but panics because it can’t locate /sbin/init.

Solution: Wrong root= on kernel cmdline OR /sbin/init missing/corrupt. Boot rescue, chroot, reinstall systemd or upstart.

#76 – module not found / missing module in initramfs

Description: Boot stalls because the initramfs lacks a driver needed to mount root.

Solution: Add module name to /etc/initramfs-tools/modules (Debian) or /etc/dracut.conf.d/ (RHEL); regenerate initramfs.

#77 – fsck failed during boot

Description: Boot stops at “fsck failed; entering emergency shell.”

Solution: At the rescue prompt: fsck -y /dev/sdaN; for repeated failures, the disk is dying.

#78 – Out of memory at boot (initramfs)

Description: Early-boot OOM in tiny VMs because the initramfs is bigger than available RAM.

Solution: Tiny VMs with too-fat initramfs; rebuild with --no-hostonly reduced; add RAM if VM.

#79 – Kernel command line typo (cannot parse)

Description: Kernel refuses to boot because of a malformed entry on the kernel command line.

Solution: At GRUB menu, press e to edit, fix the line, Ctrl-X to boot. Then permanent edit in /etc/default/grub + update-grub.

#80 – Boot loops without explicit error

Description: System reboots itself before it gets far enough to log the failure.

Solution: Kernel command line missing quiet — or has it — check the actual messages by removing quiet splash at GRUB to see what’s happening. Often hardware: failing disk, bad RAM (run memtest86+).

Conclusion

  1. Always keep a previous kernel installed; GRUB’s submenu lets you boot it if a new one breaks.
  2. Test update-initramfs before rebooting (regenerate then verify content with lsinitramfs).
  3. Use UUIDs in fstab, not /dev/sdaN — survives disk reordering.
  4. Memorize the rescue boot procedure for your distro before you need it.
  5. Snapshot/backup before kernel upgrades on critical hosts.