Monday, February 7, 2022
Having to change our grub menus with a text editor every time we want to make a change and be cumbersome and error prone. Luckily there's a tool that we can use to work with grub called grubby. In this post we are going to go over some of the useful commands that comes with grubby.
The first command we are going to look at is the grubby --default-kernel as you may have guess this will display the current default kernel
In addition to showing the default kernel we could set the default kernel with the command --set-default kernel command, with this command though you need to know the exact path to the kernel. Let's set the default kernel to be the second choice. To do that we want to see all the choices first, to list all the kernels we type the command grubby --info=ALL
From the command we see that the second choice is kernel=/boot/vmlinuz-3.10.0-1160.el7.x86_64
Now we can set the default kernel to be the second choice by typing gubby --set-default /boot/vmlinuz-3.10.0-1160.el7.x86_64
No comments:
Post a Comment