Restoring Manjaro Grub Bootloader on the deletion of the boot partition on an EFI partition system

Shashwat NathShashwat Nath
2 min read

-By Shashwat Nath

You could be extending the volume of your disc where Manjaro is installed from shrinking space from NTFS partitions on Windows and you may find that you cannot boot to Manjaro installation through the GRUB menu. What to do if you are faced with a similar situation?

  • Make a live USB of Manjaro OS. You can download it from https://manjaro.org/download/ and may use a tool such as RUFUS https://rufus.ie/en/ to make a bootable drive.

  • If you are on Windows go to advanced startup settings or alternatively boot from BIOS and change the boot order to make a USB

  • Once you have booted into the Manjaro from live USB you may use the chroot command which is only available in the live version of USB and can be used to go to the root of your manjaro installation.

      sudo manjaro chroot -a
    
  • Open another terminal and using the fdisk -l command you can check all of the partitions that you have available on your disc and you can also install Gparted to manage and view partitions.

  • You can use the mount command and if the partition was deleted it would show a failure.

  • Open the file fstab in the directory '/etc/fstab' here note the UUID of the partition the command can be used as shown below using the nano file command.

      sudo nano /etc/fstab
    
  • Now you can use any software to make a fat32 partition or you can do it manually as well.I would recommend GParted for the same. Create a FAT32 system partition of at least 128MB.

  • Now go back to the terminal and change the UUID of the deleted partition with the new partition.

  • Use Chroot command as shown previously and mount the drive specifically at /boot/efi if you have an EFI partition system.

  • The mount should be successful you may use this command

    to reinstall GRUB bootloader.

      grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=manjaro --recheck
    
  • Now you may exit the chroot environment using exit and use sudo reboot and if everything went well you should be able to boot into your Manjaro installation.

      exit
      sudo reboot
    
0
Subscribe to my newsletter

Read articles from Shashwat Nath directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Shashwat Nath
Shashwat Nath