0

Yesterday I installed xubuntu 14.04 on an USB3 ultrafit pendrive just to avoid modifying the partition table of my new HP Envy 15 jxxx.

Everything works fine, xubuntu do perfectly this job... but every time I want to boot with my linux distro I have to press F9 at preboot and select ubuntu otherwise it will boot with Win8.1 ignoring my boot priority set in bios (Legacy and UEFI).

It's a pity because grub2 is so handy: when my usb device is plugged in grub asks me if I want Win of xubuntu, when it isn't plugged it should boot automatically to win.

Just to summarize: It's possible to set the priority boot to my usb devices with an UEFI boot manager as grub2 instead of pressing F9 every time?

P.-H. Lin
  • 2,844
  • 1
  • 19
  • 20
Dave
  • 11
  • 3

2 Answers2

1

Finally I got it!! I succeeded in installing Xubuntu on an usb drive and booting it though an EFI partition on my usb drive.

  1. Boot the Live Xubuntu Installer as UEFI
  2. With GParted create a FAT32 partition (size 250M flag boot)
  3. Create an EXT4 partition to be used as Root
  4. Installed Xubuntu normally setting the path for the bootloader on the Pendrive
  5. Reboot manually (F9 in preboot) and select "ubuntu"
  6. Mount the EFI partition on my USB and the EFI partition on my HDD
  7. Created this directory tree on my USB EFI partition:/EFI/BOOT
  8. Copied the content of {HDD UEFI Partition}/EFI/ubuntu inside {USB UEFI Partition}/EFI/BOOT
  9. Renamed grubx64.efi (or shimx64.efi for secure boot) to BOOTx64.efi
  10. Deleted ubuntu folder on HDD UEFI Partition
  11. Finally changed GUID of my HDD UEFI partition to my USB UEFI partition on /etc/fstab after rebooting to the installed system
Zanna
  • 72,312
Dave
  • 11
  • 3
0

I can't understand: if you use UEFI, you use UEFI to select the file to boot (that shall be the grub boot UEFI one...). And for UEFI I mean the UEFI partition of your hard disk. It's not important where the file to boot is storage, is enough that UEFI know that it's trusted an where is it. So you don't need an UEFI partition in your USB, is enough that there is a correct configuration on the UEFI in your machine. I think that you have to do is: delete UEFI partition on your pen drive (simple you don't need it, is enough the uefi partition of hdd), use bootrepair to install grub64.EFI in your pen drive, then enter in UEFI and flag that one as trusted for execution (more or less like it: Allowing boot of Ubuntu on a Acer Aspire v5-531 with UEFI ).cheer

Translate: è sufficiente una singola partizione UEFI, e questa deve stare sull'hard disk del tuo pc. Se grub non si trova sulla chiavetta (su cui hai installato il sistema operativo, non una live, vero?) devi usare il programma bootrepair per installare grub in quella partizione (sdb o qualcosa del genere). Fatto ciò occorre insegnare a UEFI dove trovare il file di boot di grub, più o meno come fatto qui: Allowing boot of Ubuntu on a Acer Aspire v5-531 with UEFI ) NB grub e UEFI sono due cose completamente diverse! UEFI in pratica sostituisce il bios e definisce il file da bootare, grub è il file che UEFI usa per il boot: quindi quando leggi grub.efi si intende un banalissimo file leggibile dal (semplificando un poco) progamma di boot che GIÀ si trova nella partizione UEFI. Grub quindi parte dopo (e NON in sostituzione) di UEFI. Buon divertimento!