How to set Windows as Default OS in Grub

by Chinmoy Kanjilal | Translate | Print
Monday, 24th Aug 2009 | Share


Share How to set Windows as Default OS in Grub on Twitter Share How to set Windows as Default OS in Grub on Facebook Save How to set Windows as Default OS in Grub To Delicious Favorites Stumble How to set Windows as Default OS in Grub Share How to set Windows as Default OS in Grub on Digg Get Instant Updates as RSS Feeds from Techie Buzz

Some of us, or rather most of us dual boot windows and Linux. Bot the operating systems are equally important to me unless you are a Linux fanatic. Windows is as much my development platform as Linux. Now, most of us using Linux also use the Grub boot loader.

Grub

Grub

An installation of Linux after windows, places Linux on the top of the grub list and Windows at the end. That also initializes with Linux in selection and our workstation boots into Linux if allowed automatically.

To change this and put Windows as the default as well as the first OS in the list, use the steps below.

  1. Boot into Linux, that is where you will get the file to edit the boot menu for Grub.
  2. Open up the terminal, enter gksudo gedit /boot/grub/menu.lst This brings up the grub file in Gedit, the text editor.
  3. Look for the lines :
    title        Microsoft Windows XP
    root        (hd0,2)
    makeactive
    chainloader    +1

    without a ‘#’ comment at the line beginning.

  4. Bring it above the lines for booting into Linux. That should look something like kernel/ vmlinuz****Version** root=**** .
  5. You are all set. Save the file, reboot.

Your windows should be on top of the grub, and the selected OS as well. Alternatively, you can set the default selection to 1, in the same file or use SUM to change these settings. I will write about SUM in a future post.



Share

No Responses so far | Share Your Opinions!

Leave a Comment

Note: We discourage users from using keywords in their names while posting comments, most of them get caught by spam, also it really would be more fruitful in knowing people who comment by their real name, rather than by using a name no one relates to. In future we reserve the right to delete comments from users using a name other than their own.

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>