Last active
July 1, 2019 22:37
-
-
Save CarbonChauvinist/0d83f80037469aa4ef6cbf0619e865ee to your computer and use it in GitHub Desktop.
EFISTUB Dell Precision 5510
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://github.com/xdever/arch-efiboot/blob/master/build_kernel.sh | |
https://wiki.archlinux.org/index.php/Systemd-boot | |
1. Create new folder to hold EFISTUB | |
# mkdir -p /boot/EFI/arch | |
2. Combine intel-ucode and initramfs into single bin file | |
# cat /boot/intel-ucode.img /boot/initramfs-linux-dracut.img > /boot/EFI/arch/initrd.bin | |
3. Copy (or just create) file with current command line options to be passed to .efi | |
# cat /proc/cmdline | sudo tee /boot/cmdline-linux.txt | |
4. Use objcopy to create .efi output file (last argument, /boot/EFI/arch/linux-dracut.efi) | |
##/EFI/Linux is searched for specially prepared kernel files, which bundle the kernel, the init RAM disk (initrd), the kernel command line and /etc/os-release into one single file. This file can be easily signed for secure boot. | |
##Note: systemd-boot requires that the os-release file contain either VERSION_ID or BUILD_ID to generate an ID and automatically add the entry, which the Arch os-release does not. Either maintain your own copy with one of them, or make your bundling script generate it automatically. | |
##Optionally sign the linux.efi file produced above. | |
##Copy linux.efi into esp/EFI/Linux. | |
# objcopy / | |
--add-section .osrel="/usr/lib/os-release" --change-section-vma .osrel=0x20000 / | |
--add-section .cmdline="/boot/cmdline-linux.txt" --change-section-vma .cmdline=0x30000 / | |
--add-section .linux="/boot/vmlinuz-linux" --change-section-vma .linux=0x40000 / | |
--add-section .initrd="/boot/EFI/arch/initrd.bin" --change-section-vma .initrd=0x3000000 / | |
/usr/lib/systemd/boot/efi/linuxx64.efi.stub /boot/EFI/arch/linux-dracut.efi | |
5. Use efibootmgr to confirm or add as needed | |
# efibootmgr --verbose | |
# efibootmgr /dev/sda --part 1 --create --label "Arch Linux Dracut" --loader /EFI/arch/linux-dracut.efi --verbose |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment