My objective is to create a bootable Ubuntu system (full installation) on a LUKS-encrypted UBS drive. The version I am trying to install is Ubuntu 18.04
I followed this guide Full_Disk_Encryption_Howto_2019 , step by step without any error/warning. The installation drive I selected is a blank 64GB USB drive. After installation is completed and followed the post-installation guide, the USB drive won't boot with a "Operating System Not Found" error.
Next, I try to use the default installation while selecting "Erase disk and install Ubuntu", "Encrypt the new installation for security" and "use LVM for the new Ubuntu installation" and accepted all default setting while selecting my USB drive as the destination. After installation was successful, I tried to boot the USB drive but an error "System BootOrder not found. Initializing defaults" is displayed and I was redirected to the bare GRUB prompt. I checked the USB disk and I can unlock it by typing my password. The file structure looks normal but somehow I cannot boot it.
Did anyone try to do the same thing and succeeded? Any help is much appreciated.
LUKS or Full Encryption Options in the Installer
Install to USB as you would to HDD. It is recommended that you remove the HDD before proceeding, especially in UEFI mode.
They have done a good job of hiding encryption options in the Live installer. It is located on the install page, just above Something else.
Tag "Erase disk and install Ubuntu" and then click "Advanced features". The Advanced Features popup will popup. Click "Use LVM with the new Ubuntu installation" and then "Encrypt the new Ubuntu installation for security".
Booting in BIOS/UEFI Modes
A USB created with the above method will only boot in the BIOS/UEFI mode it is created in. For a USB that Boots in either mode:
Copy grub.cfg from Partition 5 /boot/grub/ to Partition 1 /boot/grub/ overwriting the existing grub.cfg file.
Re-Install GRUB:
sudo mount /dev/sdb1 /mnt
sudo grub-install --boot-directory=/mnt/boot /dev/sdb
Encrypted Full install USB should now be working in BIOS and UEFI modes.
If you want an encrypted USB drive that will boot in either BIOS or UEFI mode see: How to Make BIOS/UEFI Flash Drive with Full Disk Encryption