Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mybigman/7f6804b68bbf3cb3383aaf187d31b30c to your computer and use it in GitHub Desktop.
Save mybigman/7f6804b68bbf3cb3383aaf187d31b30c to your computer and use it in GitHub Desktop.
Fedora systemd-boot
sudo chroot /mnt/sysroot /bin/bash --login
# set partition codes
sgdisk -t 1:ef00 /dev/vda
sgdisk -t 2:8304 /dev/vda
partprobe
# remove GRUB and exclude it from being reinstalled
rpm -v --nodeps --erase $(rpm -qa | grep "^grub2-\|^os-prober-\|^grubby-")
echo "exclude=grub2-*,os-prober,grubby" >> /etc/dnf/dnf.conf
# install systemd-boot
rm -rf /boot/*
SYSTEMD_RELAX_XBOOTLDR_CHECKS=1 bootctl install --boot-path=/boot --esp-path=/boot
kernel-install add $(uname -r) /usr/lib/modules/$(uname -r)/vmlinuz
exit
systemctl reboot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment