GRUB 'No such partition' or 'Boot Device Not Found' Fix
Your server or PC hits 'no such partition' or 'Boot Device Not Found' after a drive swap, repartition, or BIOS update. I’ve fixed this dozens of times—here’s the real fix.
You boot your Linux machine after swapping a hard drive, repartitioning, or a BIOS update, and you get stuck at a grub rescue> prompt with error: no such partition. Maybe it just says Boot Device Not Found. This happened to a client last month after they cloned a 500GB HDD to a 240GB SSD and forgot to shrink the partition first. The system can’t find the /boot or GRUB files because the partition numbering changed or the bootloader points to the wrong location.
Root Cause
GRUB stores its core image and config file (grub.cfg) in the first partition (usually /boot or /). When you swap drives or repartition, the disk’s partition table changes—/dev/sda1 becomes /dev/sda2 or the UUIDs shift. GRUB’s saved location is now junk. It can’t load the menu or kernel. This isn’t a corruption issue—it’s a pointer problem. You need to reinstall GRUB to the correct disk and partition.
The Fix: Reinstall GRUB Using a Live USB
You’ll need a live Linux USB (Ubuntu, Fedora, whatever) and root access. Skip any GUI repair tool—chroot is faster and works every time. Here’s the step-by-step.
- Boot from the live USB and open a terminal.
- Identify your disk and partitions with
lsblkorfdisk -l. Look for your Linux root partition (usually/dev/sda1or/dev/nvme0n1p1). Note: if you have a separate/bootpartition, find that too. - Mount the root partition (replace
/dev/sda1with yours):sudo mount /dev/sda1 /mnt - If you have a separate boot partition, mount it:
sudo mount /dev/sda2 /mnt/boot # adjust partition number - Bind-mount essential filesystems so GRUB can talk to your system:
sudo mount --bind /dev /mnt/dev sudo mount --bind /proc /mnt/proc sudo mount --bind /sys /mnt/sys - Chroot into your system:
You’ll now be in a root shell inside your installed system.sudo chroot /mnt - Reinstall GRUB to the disk’s MBR or EFI. For BIOS/MBR (older systems):
For UEFI/GPT (modern systems):grub-install /dev/sda # not /dev/sda1, just the disk
If you get an EFI mount error, first mount your EFI partition (usuallygrub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB/dev/sda1with FAT32) to/boot/efi. - Update GRUB configuration:
On some distros (RHEL/CentOS), useupdate-grubgrub2-mkconfig -o /boot/grub2/grub.cfg. - Exit chroot by typing
exit, then reboot:sudo reboot.
If It Still Fails
Three things to check when the same error reappears:
- Partition UUID changed – Run
blkidand compare with/etc/fstabentries. If they don’t match, updatefstabwith the new UUIDs. One client had an SSD that regenerated its UUID after a firmware update—took me 20 minutes to figure out. - Secure Boot or UEFI settings – Disable Secure Boot in BIOS. Some UEFI implementations only boot an entry with a specific signature. If GRUB’s EFI binary isn’t signed, the system skips it and shows “Boot Device Not Found”.
- Wrong disk order in BIOS – If you have multiple drives, the BIOS might boot from a different disk. Change the boot order so your Linux drive is first.
That’s it. No fancy tools, no endless forum scrolling. You fix the pointer, update the config, and you’re back in business. I’ve done this on Ubuntu 22.04, Debian 12, and CentOS 7—works the same across the board.
Was this solution helpful?