Booting Fedora 19 Using EFI Boot Stub

This post assumes that you are familiar with EFISTUB-booting a Linux Kernel and you have access to an EFI shell on your system. If not, see my blog posts on Musings of an OS Plumber for more information on EFI booting Linux systems.

Here is a suitable EFI script for the Fedora 19 GA kernel:

$ cat f19.nsh
vmlinuz-3.9.6-301.fc19.efi root=UUID=1d3092fc-265e-4860-a609-d6a16c1a6458 rd.lvm=0  KEYTABLE=us SYSFONT=True rd.luks=0 ro LANG=en_US.UTF-8 rhgb quiet initrd=.initramfs-3.9.6-301.fc19.x86_64.img

You will have to replace the above root filesystem UUID with the UUID of your root filesystem. It also assumes that you are not using a Logical Volume Manager (LVM) or an encrypted disk. Frankly, I see no reason to use LVM any longer in most of the classical use cases where LVM was used, and especially not for any of the standard operating system filesystems.

Here is a simple script which you can run to update f19.nsh whenever the kernel is updated.

# cat /boot/efi/


VMLINUZ=$(ls ../vmlinuz-* | sort -r | head -1)

INITRAMFS=$(ls ../initramfs-* | sort -r | head -1)

ROOTUUID=$(${AWK} ' { if ($2 == "/") { print $1} }' /etc/fstab)

rm -f vmlinuz-*
rm -f initramfs-*
cp ../${INITRAMFS} .

echo "${VMLINUZEFI} root=${ROOTUUID} rd.lvm=0  KEYTABLE=us SYSFONT=True rd.luks=0 ro LANG=en_US.UTF-8 rhgb quiet initrd=.\${INITRAMFS}" > ${RELEASE}.nsh

Again you may have to modify this script if you are using an encrypted root disk or LVM.

Comments are closed.