How to Change the Default Kernel on Fedora
To check and change the default kernel on Fedora, we’ll be utilizing a command line tool called “grubby”. This tool is specifically designed for modifying bootloader configuration files.
Install grubby
In case grubby is not already installed, we have the option to install it:
1 | sudo dnf install grubby |
List all installed kernels
To get the index number of all the installed kernels:
1 | sudo grubby --info=ALL | grep -E "^kernel|^index" |
The output should be something like this:
1 | index=0 |
Change the default kernel using index
Now we can change the default kernel by using the index number:
1 | sudo grubby --set-default-index=1 |
Verify the default kernel
Verify that the right kernel has been set as default:
1 | sudo grubby --default-title |
The output will be the default kernel title:
1 | Fedora Linux (5.15.10-lqx1.0.fc35.x86_64) 35 (Workstation Edition) |
How to Change the Default Kernel on Fedora