[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: change default os
From: |
David WE Roberts |
Subject: |
Re: change default os |
Date: |
Mon, 25 Mar 2013 10:37:39 +0000 (UTC) |
User-agent: |
Pan/0.139 (Sexual Chocolate; Unknown) |
On Sun, 24 Mar 2013 21:57:48 -0700, Jordan Uggla wrote:
<snip>
>
>> It would be much more friendly if you could select the order in which
>> various OS are added to the menu.
>
> Indeed, it is unfortunate how hard it is to change the order of menu
> entries in grub when using grub-mkconfig, I can't think of a great
> interface currently for setting the order menu entries are displayed,
> though it's likely that someone else could. If you have a proposal for a
> good interface for this please share it.
>
<snip>
O.K. - I suspect that most of the bits needed are already lying about
somewhere.
First, the reordering of the boot menu (grub-reorder or reorder-grub?)
should be at least apparently stand alone so it can be run at any time.
[I don't know if merely shuffling the grub.cfg is enough to achieve what
we want.]
Secondly a flag should be set if the grub order has been changed so that
any invocation of update-grub knows to either check that the same list of
entries is present but in a different order, and shuffle the new entries
to match the order, and/or to fire up reorder-grub for the user to confirm
the required boot order.
Legacy grub attempted to do something similar but not very successfully
(for me, at least).
Now from my limited understanding the booting is controlled by grub.cfg
which is basically an ordered list of scripts.
The boot menu is a list condensed from this, with scrolling up and down
and selection using the keyboard, so something that looks like the boot
menu with the ability to select an entry (space bar?) then move it up or
down the list (left/right arrow keys?) should do as the main interface.
Once the new order has been selected, this can be confirmed and then
grub.cfg can be reshuffled.
[Reshuffling a series of scripts within a file should be relatively
trivial to an experienced coder.]
Tools like clonezilla use a very similar interface which works on text and
graphics consoles.
BIOS/UEFI interfaces offer similar functionality.
So, as a rough first cut, does this sound reasonable and doable?
Much like hand reordering grub.cfg but with protection against loss of the
changes when update-grub is run.
Cheers
David
change default os, Tom Davies, 2013/03/14
Re: change default os, Simon Hobson, 2013/03/14
Re: change default os, Simon Hobson, 2013/03/14
Re: change default os, Simon Hobson, 2013/03/26