Install grubby

dnf install grubby

Listing the Default Kernel

List the default kernel:

grubby --default-kernel
/boot/vmlinuz-4.2.0-1.fc23.x86_64

This is the kernel that's currently in use by the operating system.

grubby --info=ALL

[root@nas ~]# grubby --info=ALL
index=0
kernel="/boot/vmlinuz-5.3.13-300.fc31.x86_64"
args="ro resume=UUID=d86a0984-e056-45db-88bd-1acbd0144d75 rhgb quiet"
root="UUID=cc901d7f-f002-4880-a4b1-476c06a80a00"
initrd="/boot/initramfs-5.3.13-300.fc31.x86_64.img"
title="Fedora (5.3.13-300.fc31.x86_64) 31 (Thirty One)"
id="0a1b8851c7cc422a8ce760a20346b81d-5.3.13-300.fc31.x86_64"
index=1
kernel="/boot/vmlinuz-5.3.12-300.fc31.x86_64"
args="ro resume=UUID=d86a0984-e056-45db-88bd-1acbd0144d75 rhgb quiet"
root="UUID=cc901d7f-f002-4880-a4b1-476c06a80a00"
initrd="/boot/initramfs-5.3.12-300.fc31.x86_64.img"
title="Fedora (5.3.12-300.fc31.x86_64) 31 (Thirty One)"
id="0a1b8851c7cc422a8ce760a20346b81d-5.3.12-300.fc31.x86_64"

Find out the index number of the default kernel:

grubby --default-index
0

Reference the index number shown here to the list from the previous task to figure out which kernel is the default one.

Change the Default Boot Entry

This will make a persistent kernel choice change.

grubby --set-default /boot/vmlinuz-4.2.0-1.fc23.x86_64

Published

Category

Fedora

Tags

Contact