Changing kernel guide

Well, you can use our very own akm tool.


Using this you can install almost all the kernels in the Arch repo.

To boot from the kernel you can use this. If you’re using systemd-boot. If you’re using GRUB then you have to edit /etc/default/grub.

Use sudo nano /etc/default/grub and change GRUB_DEFAULT=0 to GRUB_DEFAULT="1>2" So if the linux-rt is the first in the sub-menu it’ll make it boot. If you want more clarification on this use this post in StackExchange. Or you can just replace the number in front of GRUB_DEFAULT= and see what works (I can’t remember how to find the correct number).

After editing the GRUB config you need to recreate the actual grub.cfg file to do this you just have to run sudo dracut-rebuild. Now reboot to test.

EDIT: Remembered how to find the kernel ID.

  • To find $menuentry_id_option use:
$ sudo grep submenu /boot/grub/grub.cfg
submenu 'Advanced options for Debian GNU/Linux' $menuentry_id_option 'gnulinux-advanced-38ea4a12-6cfe-4ed9-a8b5-036295e62ffc' {
  • To find $menuentry_id_option for the ernel you want to use:
menuentry 'EndeavourOS, on linux-lts' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-advanced-f2f94842-8952-4808-9752-1a9608e5af53' {
menuentry 'EndeavourOS, on linux-lts (fallback initramfs)' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-fallback-f2f94842-8952-4808-9752-1a9608e5af53' {
menuentry 'EndeavourOS, on linux' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-f2f94842-8952-4808-9752-1a9608e5af53' {
menuentry 'EndeavourOS, on linux (fallback initramfs)' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-f2f94842-8952-4808-9752-1a9608e5af53' {

Above 4 entries are numbered 0, 1, 2, and 3. So when you are counting you should count it like below.

0 ---- menuentry 'EndeavourOS, on linux-lts' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-advanced-f2f94842-8952-4808-9752-1a9608e5af53' {
1 ---- menuentry 'EndeavourOS, on linux-lts (fallback initramfs)' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-fallback-f2f94842-8952-4808-9752-1a9608e5af53' {
2 ---- menuentry 'EndeavourOS, on linux' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-f2f94842-8952-4808-9752-1a9608e5af53' {
3 ---- menuentry 'EndeavourOS, on linux (fallback initramfs)' --class endeavouros --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-f2f94842-8952-4808-9752-1a9608e5af53' {

From the list, you can just select the one you want to use and then change GRUB_DEFAULT= to the number. If you want to use the normal kernel from the above list then change GRUB_DEFAULT=0 to GRUB_DEFAULT=2. Save the file and then sudo dracut-rebuild.

Then reboot and use uname -a to double-check what kernel you have been booted into.

5 Likes