[Techtalk] Grub defaults after new kernel image install

Gina Lanik geekgrrl at geekgrrl.priv.at
Tue Jul 25 15:33:39 UTC 2006


On Tue, Jul 25, 2006 at 08:14:23AM -0700, Carla Schroder wrote:
> On Tuesday 25 July 2006 07:48, Gina Lanik wrote:
> > I'm updating a few of our RHEL servers at work, which in some case also
> > means a newer kernel image. Now I seem to recall that if in grub.conf the
> > "default" line was set to anything other than 0, this would be honored on a
> > new kernel image install so the server would boot from the "old" already
> > existing and former default kernel. Is my memory faulty or was this
> > behavior changed some time ago?
> > 
> The kernel stanzas are numbered in order starting from 0, so you can make any 
> of them the default. For example, if you have three different kernel stanzas 
> you can make the third one the default with 'default 2'. I don't recall what 
> happens when RHEL updates, you might have to configure this manually to get 
> the one you want.

That's what I was doing now as we have special stanzas for a few machines
(custom built initrd because of changed settings for the SAN environment).

> A slick trick is to use the 'savedefault' option, which probably isn't what 
> you want, but I feel like telling about it anyway. :) If you are 
> multi-booting or have multiple kernels, GRUB will boot whatever you booted to 
> last, instead of always having the same default. It looks like this:

[...]

I remember seeing this on our Debian boxen. Confused me to no end because
-every- stanza had the savedefault option listed, no idea why.
It might do the trick for the RHEL boxen, though. Thanks Carla!

Cheers,

Gina
-- 
Gina Lanik                      :: LinuxChix member
SysAdmin & DBA                  :: http://www.linuxchix.org/
http://www.geekgrrl.priv.at/    :: LUGA member
http://nilasae.livejournal.com/ :: http://www.luga.at/


More information about the Techtalk mailing list