PDA

View Full Version : [kubuntu] [SOLVED] How can I change GRUB's default OS?



tlinux
November 19th, 2008, 05:54 AM
I have Kubuntu and Windows XP loaded in a dual boot system. Grub automatically opens Kubuntu by default. I want to change that to Windows. I thought there was a menu in one of the GRUB folders that I could edit to make this change, but I can'f find that menu.

How do I change the default OS in GRUB?

Thank you.

zymjh
November 19th, 2008, 05:58 AM
I am pretty sure that the menu.lst is in the /boot/grub/ folder.

girishsasikumar
November 19th, 2008, 07:16 AM
u need to edit /boot/grub/menu.lst for which u need to have administrative privileges.

sudo gedit /boot/grub/menu.lst
the change # in the line 'default #', to whichever OS/kernel u want 1, 2 ... etc as default

tlinux
November 19th, 2008, 10:19 PM
I am pretty sure that the menu.lst is in the /boot/grub/ folder.

You are correct. I overlooked the menu when I first searched for it.

Next question: Is there a way to get into Administrator Mode without using the terminal and entering command-line instructions?

Thanks for your help.

taurus
November 19th, 2008, 10:21 PM
sudo nano -Bw /boot/grub/menu.lst
<Ctrl>x to exit.

Chazall1
November 19th, 2008, 10:33 PM
In your /boot/grub/menu.lst on the upper half of the page, there is an examlpe area, which gives you an example of an XP boot. These lines have a # in front of them, make any changes HERE not in the Main Kernel area. If you place your grub XP into the Kerel area, It will only work up until you get a kernel update, and grub will not function properly.
Look in the example area near the top of the /boot/grub/menu.lst.

aysiu
November 19th, 2008, 10:36 PM
In Kubuntu I don't think you have Gedit.

So you would paste this command into Konsole terminal (http://www.psychocats.net/ubuntu/terminal):
kdesu kate /boot/grub/menu.lst and then change the default 0 to a different number. 0 is for the first entry. 1 is for the second. 2 for the third. And so on.

dabl
November 19th, 2008, 10:38 PM
If your Kubuntu version is 8.10, then you can use KMenu>System Settings>Advanced>Grub Editor (or something like that) to change the sequence on the menu.

In version 8.04 or earlier, to avoid the CLI, your can do Alt-F2 "kdesu kate /boot/grub/menu.lst" with no quote marks, and change the order by cutting and pasting the "stanzas" at the bottom of the file.

In 8.10, the command is "kdesudo kate /boot/grub/menu.lst".

And if you're editing /boot/grub/menu.lst, in addition to the edit mentioned by aysiu, make sure the "groot=" line has the hd(x,y) partition where your Ubuntu OS is located.

HTH. :)

tlinux
November 20th, 2008, 04:55 AM
"In version 8.04 or earlier, to avoid the CLI, your can do Alt-F2 "kdesu kate /boot/grub/menu.lst" with no quote marks, and change the order by cutting and pasting the "stanzas" at the bottom of the file."

This worked like a charm! Thank you for your help.

PROBLEM SOLVED