Mon 01 Jul 2002 03:17:40 PM UTC, original submission:
I have a grub menu with several items on it. I almost always choose the same one. Occasionally, I want to boot from a different item on the next boot, but then want to return to by default for subsequent boots. I would like to be able to override the menu item that will appear as the default on the next boot only and to be able to do this from my running system before rebooting. This is different from using savedefault.
For example, once in a while, I boot into Windows instead of Linux. I have a menu item called "dark" that does this. I want to be able to run bootdark from Linux and have the system boot into windows the next time I boot. Then, the time after that, I want it to go back to Linux again.
You could do this with lilo by using lilo -R.
Right now, I'm acheiving this goal by having a bunch of different grub configuration files that do various setups and installs, and I have a script that changes which grub configuration file is in use, but this is not clean.
It seems to me that savedefault must be writing something like this somewhere -- perhaps at the beginning of stage2 -- and that it wouldn't be a hard software change to support this request in a similar fashion.
The main reason for doing this is to be able to control booting remotely in a safe way. I want to be able to control my next boot without having to be physically present at the machine. For example, I can boot once into Windows, and then reboot from there using VNC. I can't run grub from Linux, so the only way to get back once I've done that (short of messing with active partitions, etc.) is to have the default switch back upon the next boot.
Thanks for your consideration.
|