DEV Community

Discussion on: Running Ubuntu From A USB Drive

Collapse
 
angelarae63 profile image
Angela Whisnant

Mind blown! Why didn’t I think of that!? I’m gonna look into getting an external hard drive. What a great idea!

Collapse
 
geraldew profile image
geraldew

A very belated addendum is that I've since cracked the solution to correctly setting these up to work with EFI booting. The magic ingredient is using grub-install with a --removable option.

I should probably do a full post to cover this sometime but for just here I'll quote the sources for the magic tip:

In my case I cheated by unplugging the internal hard drive of my laptop and then installed Ubuntu 20.04 onto a USB thumb drive from a DVD (of the ISO live disc for AMD64). Then after a successful boot on the thumb drive I went to the command line to-reinstall GRUB with the removable option. That thumb drive now boots fine on any of 64bit computers and - importantly - when it does so it uses the ESP partition on itself, leaving any other drive safely alone.

The other extra trick is to use efibootmgr to alter the EFI default order - but that's a whole other topic and can't override bad firmware behaviours.