How to boot some GRUB entry only once during next boot.

Tagged:  

This little howto will help you boot some linux kernel from your grub configuration only once. During the next boot grub will boot as usual.

Imagine you have such line in your /etc/grub.conf:

...
default=0
...

and you want to reboot your linux system (but only once, this time) to the grub entry 1, then you can you execute follwoing command as user root

bash# echo -e "savedefault --default=1 --once\nquit\n" | grub --device-map=/boot/grub/device.map

This might be helpful if you want to install new linux kernel remotely and you are not sure if it will boot properly, for example.

Your rating: None