[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Configure GRUB 2



On Thu, Nov 08, 2012 at 12:47:28PM +0000, Darac Marjal wrote:
> On Thu, Nov 08, 2012 at 01:40:37PM +0100, tv.debian@googlemail.com wrote:
> [cut]
> > 
> > 
> > If you don't want to boot the previous kernel, but a specific one
> > (known to work), cat the /boot/grub/grub.cfg and locate the entry of
> > the kernel you want as a default. What you want is the part
> > immediately following the "menuentry" stanza, usually in between
> > single quotes (you don't need the whole line. Here is and example
> > grub.cfg menu entry:
> > 
> > 
> > menuentry 'Debian GNU/Linux, avec Linux 3.2.0-3-amd64 [...]
> > 
> > 
> > You would need to put the following entry in /etc/default/grub:
> > 
> > GRUB_DEFAULT='Debian GNU/Linux, avec Linux 3.2.0-3-amd64'
> > 
> > 
> > Then execute "update-grub".
> > 
> > I think this is a bad idea outside of a temporary test situation, if
> > you forget such a hack you'll be booting an old kernel possibly
> > vulnerable or troublesome as the default one. The config will also
> > break when this specific kernel version is removed by the package
> > manager.
> 
> A couple of points.
> 
> GRUB_DEFAULT takes a menu, not a title.

Bah, I meant it takes a NUMBER, not a title. So your first kernel is 0,
you probably then have the same kernel in emergency mode as 1, the next
kernel as 2 and so on.

> 
> Also, if you want to simulate the setting of GRUB_DEFAULT on a one-off
> basis, look at the "grub-reboot" command.


Attachment: signature.asc
Description: Digital signature


Reply to: