Page 1 of 1

Re: Grub vs updates

Posted: Thu Mar 12, 2009 3:49 am
by Fred
kenberto wrote:
I'm getting pretty frustrated with having to manually muck around with these things.
It sounds as if you are not setting the options in the menu.lst necessary to make your corrections to the menu.lst permanent. Sometimes during an update your grub install is reconstituted for one reason or another related to the specific files that are changed during the update. A kernel update is an example of this.

When you changed your menu.lst did you also set your

# kopt=root=
# groot=
# defoptions=
# updatedefaultentry=
# savedefault=
# howmany=

lines to reflect any changes you made to the menu.lst? If not then this is most likely the problem.

Fred

Re: Grub vs updates

Posted: Thu Mar 12, 2009 4:10 am
by merlwiz79
Linux Mint uses grub-gfxboot.
I am the one who maintains this package.
I have updated it a few times and it shouldn't change anything below:

Code: Select all

### END DEBIAN AUTOMAGIC KERNELS LIST
It should only add or remove kernels that have been installed or uninstalled.
I have Windows 7 beta and XP Pro installed and the entry to boot those never disappear.

Re: Grub vs updates

Posted: Thu Mar 12, 2009 4:18 am
by Fred
merlwiz79,

Yes, but he could have changed his boot preference incorrectly by the placement of the boot stanza, as an example.

Actually there are a number of things that can be done that would wipe out the Windows boot with a update-grub command.

You are making the assumption that any changes he has made were done properly, which is obviously not the case since update-grub seems to be wiping out the apparent ability to boot Windows from his visible menu.

Fred

Re: Grub vs updates

Posted: Fri Mar 13, 2009 4:32 am
by Fred
kenberto,

It appears that you put your Windows boot stanza in with the automagic boot stanzas. Probably to get it to boot by default. Up toward the top of that file is an entry you can use to select the default boot. You want it set as shown below to get Windows to boot by default. The numbering starts at 0 and you count the number of title lines that aren't commented.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
default 4

The boot stanzas at the bottom should look like I have shown below.

## ## End Default Options ##

title Linux Mint, kernel 2.6.22-16-generic
root (hd0,1)
kernel /boot/vmlinuz-2.6.22-16-generic root=/dev/sda2 ro quiet splash
initrd /boot/initrd.img-2.6.22-16-generic
boot

title Linux Mint, kernel 2.6.22-16-generic (recovery mode)
root (hd0,1)
kernel /boot/vmlinuz-2.6.22-16-generic root=/dev/sda2 ro single
initrd /boot/initrd.img-2.6.22-16-generic
boot

title Linux Mint, kernel memtest86+
root (hd0,1)
kernel /boot/memtest86+.bin
boot

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.

title Other operating systems:
#

title Win XP
root (hd0,0)
savedefault
makeactive
chainloader +1

As merlwiz79 pointed out, the stanzas not within the automagic section are not tampered with. Any boot stanzas you want to manually add and be persistent must be before the line:

### BEGIN AUTOMAGIC KERNELS LIST

or after the line:

### END DEBIAN AUTOMAGIC KERNELS LIST

You select the stanza you want to boot by default with the setting I showed you above. By counting the number of "title" lines from the top to the stanza you want to boot, less one. If you want your Windows stanza to appear at the top of your menu you would put that stanza above the "begin" line and leave the default set to 0 to boot it by default.

I hope this helps you. :-)

Fred