Ubuntu – Installing Ubuntu on External Hard Drive – UEFI

dual-boothard drivesystem-installationuefi

I want to install Ubuntu on a 1TB External Hard Drive, while the internal hard drive already has Windows 10 (OEM) pre-installed on it. So, that I could use both the OS's, by deciding which one to use from the boot menu.

I did some research and found two way of doing this.

  • Method 1: (How do I install Ubuntu to a USB key?)

    • Remove the Internal Hard Drive and connect the External Hard Drive via USB
    • Disable Secure Boot in UEFI Firmware
    • Use bootable Ubuntu USB and install the normal way
    • Then reconnect the internal hard drive
  • Method 2: (How to install Ubuntu on portable external Hard Drive?)

    • Disable Secure Boot in UEFI Firmware and Fast Startup in Windows
    • Connect External Hard Drive via USB
    • Use bootable Ubuntu USB and choose "Something Else" in setup
    • Point the "Boot Loader Installation" to the external hard drive (sdb)
    • Create / and swap area (some people also create /boot) on external hard drive (sdb)
    • Once Ubuntu is installed, I'll be able to choose which OS to boot into from the Boot Menu

Problems are:

  • Would disabling secure boot render my Windows installation unusable?

    • Trying to disable Secure Boot, from UEFI Firmware settings, throws the following warning: Attention! Changing this setting may prevent your operating system from booting or require a reinstall. Are you sure you would like to continue?
    • Microsoft Secure Boot documentation highlights this warning too.
  • Would following Method 2 entail further complications like manually creating an EFI partition and manipulating grubx64.efi and shimx64.efi, EDIT: but wouldn't this manipulation cause problems when Secure Boot is turned back on (signature of boot loader might change)?

  • Which Method should I go with then?

Best Answer

I believe the installer now works with secure boot on. If not, the installed Ububtu will. So, turn secure boot back on after installing.

If you want the external to be bootable in any computer, then you have to make an EFI partition on it. Select something else for install to be sure the installer uses the external ESP not the internal. The EFI partition should be 500 MB, formated FAT, and flagged ESP.

If it will only be used on this computer, then using the internal drives EFI partition is preferable. Grub will require that the drive be connected so it can find it's config file. Though if you use the previous setup, it can be made so the computer automatically boots linux when the drive is connected or windows when not by setting boot order.

a separate /boot partition is unnecessary, and can cause problems if made too small

Edit:

as per Microsoft Secure Boot Documentation --- After disabling Secure Boot and installing other software and hardware, it may be difficult to re-activate Secure Boot without restoring your PC to the factory state

What this means is:

If you turn off secure boot in order to install low level software (such as drivers) in Windows, then turn secure boot on, Windows may not boot if the software is not signed by Microsoft.

Related Question