Debian/Ubuntu: Use /dev/disk/by-uuid

This is how the Ubuntu 20.04 installer configures the ESP to mount at
/boot/efi, so it should be fine to use this convention everywhere.

/dev/md0's /dev/disk/by-uuid entry does not show up immediately, so I
removed the swapon there.

Signed-off-by: Richard Laager <rlaager@wiktel.com>
This commit is contained in:
Richard Laager
2020-12-05 17:12:22 -06:00
parent a4f8837031
commit d86f52c207
2 changed files with 8 additions and 9 deletions

View File

@@ -609,8 +609,8 @@ Step 4: System Configuration
apt install --yes cryptsetup
echo luks1 UUID=$(blkid -s UUID -o value ${DISK}-part4) none \
luks,discard,initramfs > /etc/crypttab
echo luks1 /dev/disk/by-uuid/$(blkid -s UUID -o value ${DISK}-part4) \
none luks,discard,initramfs > /etc/crypttab
The use of ``initramfs`` is a work-around for `cryptsetup does not support
ZFS <https://bugs.launchpad.net/ubuntu/+source/cryptsetup/+bug/1612906>`__.
@@ -634,7 +634,7 @@ Step 4: System Configuration
apt install dosfstools
mkdosfs -F 32 -s 1 -n EFI ${DISK}-part2
mkdir /boot/efi
echo UUID=$(blkid -s UUID -o value ${DISK}-part2) \
echo /dev/disk/by-uuid/$(blkid -s UUID -o value ${DISK}-part2) \
/boot/efi vfat nofail,x-systemd.device-timeout=1 0 1 >> /etc/fstab
mount /boot/efi
apt install --yes grub-efi-amd64 shim-signed