[arch-general] How to choose which grub entry boots next from the cli via ssh in Arch?

Tim Gelter tgelter at gurulabs.com
Wed Aug 26 17:30:36 UTC 2009


Tim Gelter wrote:
> David C. Rankin wrote:
>> On Tuesday 25 August 2009 09:51:50 pm Sven-Hendrik Haase wrote:
>>
>>> There are multiple ways:
>>> You can put "default   2" at the very top of your menu.lst which will
>>> always select the 2nd entry (0-based) by default.
>>> Another and maybe more modern way to do it is to add "default   saved"
>>> at the top and then add "savedefault" below each individual entry. This
>>> way, Grub will always select the last selected entry.
>>>
>> Sven,
>>
>> 	Thanks, sorry, I know all that. I'm looking for a quick command that does NOT 
>> alter the menu.lst file, but sets some type of flag that tells grub do NOT 
>> boot the default entry, instead, boot entry 5.
>>
>> 	I know there is something in kde4 that will do it because when you hold-down 
>> the Restart option, you can set the next OS you want to boot if you have more 
>> than 1 entry in menu.lst. Ever hear of anything like that for Arch?
>>
>> 	With grubonce, you just enter grubonce (without arguments) and it returns a 
>> list of what is in your menu.lst file:
>>
>> [23:52 dcrgx/home/david/scripts/file] # grubonce
>> 0: openSUSE 11.0 - 2.6.25.20-0.5
>> 1: Failsafe -- openSUSE 11.0 - 2.6.25.20-0.5
>> 2: openSUSE 11.1 - 2.6.27.19-3.2 (/dev/sdb1)
>> 3: Windows
>>
>> 	Then all you have to do is issue the command:
>>
>> # grubonce 2
>>
>> and you will boot suse 11.1 next time. That's what I'm looking for. I'll keep 
>> digging.
>>
> David,
> When you find it, please respond to this thread as I'm also interested
> in finding a method such as you describe.
> -Tim
> 
whoops, hadn't checked mail again before sending that last message.
thanks for including your solution.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 489 bytes
Desc: OpenPGP digital signature
URL: <http://www.archlinux.org/pipermail/arch-general/attachments/20090826/60607268/attachment.pgp>


More information about the arch-general mailing list