Hi everyone.

I am on an UEFI system. I want to install arch on an external USB drive. I am facing certain issues and hoping I could troubleshoot with your advice.

The first irregularity I faced was generating the fstab using

genfstab -U /mnt >> /mnt/etc/fstab 

I though -U option was supposed to use UUIDs to identify the partitions, yet the partitions were identified by kernel name descriptors (i.e /dev/sdcX). The UUIDs were present as comments, so I could manually edit the file to use UUIDs instead.

Installed grub using the following command after "chroot"-ing into the new system.

grub-install --target=x86_64-efi --efi-directory=/efi --bootloader-id=GRUB 

Installation was successful and I could boot using grub. Encountered a problem when I removed the USB drive and re-inserted. The EFI boot entry GRUB was deleted by firmware. It was replaced by an entry similar to the live bootable media. "UEFI: Samsung USB Drive Partition 1" or something. Clicking on that just takes me to Windows (installed on internal drive).

I found that grub needs to be installed with --removable option. So I used

rm -r /efi/EFI/* rm -r /boot/grub/grub.cfg grub-install --target=x86_64-efi --efi-directory=/efi --bootloader-id=GRUB --removable --recheck 

This time I was successful. The EFI boot entry is persistent even if I remove and re-insert the drive. The problem is the boot entry has the generic name "UEFI: Samsung USB Drive Partition 1". I use the same type of drive to try out many distros, which leads to having similar entries which is confusing.

My questions are:

  1. It seems grub-install ignores the --bootloader-id=GRUB option when --removable is set. Is there any way to have a unique boot entry name for grub or is my only option to delete the boot entry using efibootmgr and creating a new one.
  2. Is there any other bootloader that will allow me to have both a unique and persistent boot entry for a removable drive, which doesn't need manually removing/adding EFI boot entries.
  3. Why does genfstab -U not use UUIDs to identify partitions. Is there any way to generate fstab with UUIDs automatically instead of manually editing it.
submitted by /u/sashwatsamaddar
[link] [comments]