0

I have followed the steps from this video. But the USB is not showing on my boot option.

Here is what I have done:

1) I downloaded Ubuntu desktop and installed it on my 4GB USB drive using Rufus

2) I then installed the ubuntu OS into my 64GB USB drive from the 4GB USB drive

3) Then I tried to access the boot option menu after I finished installing it only showed me the windows boot manager


Here is how I fixed it:

1) Using fdisk -l to check the name of ESP partition

Disk /dev/sdb: 57.3 GiB, 61505273856 bytes, 120127488 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 09D357C5-2585-4D1D-9658-9417516D1E0A

Device         Start       End   Sectors  Size Type
/dev/sdb1       2048   1953791   1951744  953M EFI System
/dev/sdb2    1953792 117188607 115234816   55G Linux filesystem
/dev/sdb3  117188608 120125439   2936832  1.4G Linux swap

2) And then I used mkdir /media/root/Ubuntu to create a new mount point

3) Then I mount the ESP partition mount /dev/sdb1 /media/root/Ubuntu

4) My Boot directory

5) My Ubuntu directory

6)Using blkid to check if the UUID showed in terminal is the same as what grub.conf pointed to

/dev/sdb1: UUID="AD33-1FB3" TYPE="vfat" PARTUUID="99511b0d-05ea-4920-9a44-c94544b20091"
/dev/sdb2: UUID="1b3eccd8-7b52-4de9-947d-5183c43a5584" TYPE="ext4" PARTUUID="1400a3bf-43c9-441a-b124-85d54a961492"
/dev/sdb3: UUID="aef579c4-f98b-4abd-b54c-a521a2fa6074" TYPE="swap" PARTUUID="fcb804cc-6a81-4dae-8727-c8da31faab6b"

7) Check if bootx64.efi and shimx64.efi have the same size

8) Copygrubx64.efi to EFI/Boot

4
  • Comments are not for extended discussion; this conversation has been moved to chat.
    – Thomas Ward
    Mar 19, 2019 at 20:43
  • Either use gpt instead of dos partition table, or make the ESP partition a primary instead of a logical (one within the extended partition). In the more modern GPT partitioning, all partitions are "primary".
    – ubfan1
    Mar 19, 2019 at 21:47
  • @ubfan1 @oldfred I have modified the partition into GPT and I have copy both folder \EFI\ubuntu and EFI\boot to the ESP files system in my USB but it doesn't work Mar 19, 2019 at 23:26
  • @ubfan1 I have updated my post Mar 20, 2019 at 3:30

1 Answer 1

0

I'll edit this answer instead of responding in the comments. To answer your last question, where on the live media are the bootloaders?
Look in the live media's /EFI/BOOT directory and see BOOTx64.EFI and grubx64.efi. These are the two files that should wind up on the full-install USB's EFI partition (in the EFI/BOOT directory). Also on the full-install's EFI, there must be a /EFI/ubuntu/grub.cfg file. This file should have a UUID in it which must be the UUID of the root partition of the full-install USB (I think it gets set up correctly, even though all the files get written to the internal disk's EFI instead of the full-install's EFI.). Those three files in those locations should be all that it necessary for a UEFI secure boot, done by selecting the USB device for booting. Looks like the below:

full-install USB  
  EFI partition  
    EFI  (directory)  
     Boot  (directory)  
       bootx64.efi
       grubx64.efi
     ubuntu  (directory)  
       grub.cfg  
  root partition

So your EFI/Boot directory is missing the grubx64.efi file (if bootx64.efi is a copy of shimx64.efi, check the sizes), or you have set up with secure boot disabled, and bootx64.efi is actually a copy of grubx64.efi (again, check sizes). Using shimx64.efi as bootx64.efi will work with or without secure boot being on, so that's what I recommend. Both files are found in the EFI/ubuntu directory, so you can fix that up.
The UUID for you root, , UUID="1b3eccd8-7b52-4de9-947d-5183c43a5584 should be the UUID used in the EFI/ubuntu/grub.cfg file. Edit the file if necessary to change the UUID.


OK, so copy grubx64.efi from EFI/ubuntu to EFI/Boot, so it's ion the same directory as bootx64.efi(shim). Check the UUID in grub.cfg, note, I originally had the wrong ID, the partition id instead of the UUID, but I changed that. Selecting the USB device for a UEFI boot should then work (both with or without secure boot enabled). If not, your system does not follow the UEFI spec, so additional tweaking may be necessary, but doing the boot from the bootx64.efi gets around most name nonsense introduced by some vendors.

4
  • The bootx64.efi and shimx64.efi have the same size Mar 20, 2019 at 4:06
  • I copied the grubx64.efi to EFI/Boot and I have checked the grub.cfg Both UUID match each other Mar 20, 2019 at 4:20
  • It works ! Thanks !! I appreciate your help! :) I have been figuring it for days Mar 20, 2019 at 4:21
  • Also update UUID for mount of ESP - efi system partition from internal drive's ESP to flash drive's ESP. list UUIDs lstblk -f then sudoedit /etc/fstab if booted into your flash drive.
    – oldfred
    Mar 20, 2019 at 13:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .