I was following this guide: http://www.howtogeek.com/howto/ubuntu/set-windows-as-default-os-when-dual-booting-ubuntu/ in order to make windows the default os when I boot the computer but the problem is that the file which opens when I run the commend which manshened in the text is empty and dosn't have any of the lines it should have according to the guide so can anybody help and tell me how to see the text or give another way of making windows 7 the default os?


Run this: sudo apt-get install startupmanager. Then you can launch startupmanager which gives you a GUI to change many settings, including default OS to boot.


What you also can do is:

sudo mv /etc/grub.d/30_os-prober /etc/grub.d/09_os-prober
sudo update-grub

Now Windows (or any other non-linux OS) is always on top of the list and you don't have to care about the menu position if there is a new kernel.

  • 1
    IMO a better solution than the selected answer because it fixes the problem for good.
    – dandan78
    Apr 6 '11 at 9:02

you can do it yourself :

gksudo gedit /etc/default/grub

This file contains information formerly contained in the upper section of Grub Legacy's menu.lst and items contained on the end of the kernel line. The items in this file can be edited by a user with administrator (root) privileges.



  • GRUB_DEFAULT - Sets the default menu entry. Entries may be numeric

    • GRUB_DEFAULT=0 - Sets the default menu entry by menu position. As Grub Legacy, the first "menuentry" in /boot/grub/grub.cfg is 0, the second is 1, etc.

after that do that :

sudo update-grub


I guess the file menu.lst does not exist in newer versions of ubuntu. Even I couldn't find it when I was in your situation. I suggest you install startup-manager from synaptic which offers an easy to use and intuitive GUI.


Alternative: Edit manually /boot/grub/grub.cfg and change the value of "default" entry:

set default="0"

"0" means first OS entry at grub.cfg

  • 1
    The very first line of grub.cfg says "DO NOT EDIT THIS FILE." It says that because that file is autogenerated and any changes you make will be lost the next time it is generated which happens every time grub or your kernel is updated. Instead follow sroecker's advice. Mar 15 '11 at 11:28

hey this solution works for sure. try this link http://www.youtube.com/watch?v=dr4lYivo4rU

  • 2
    Welcome to Ask Ubuntu! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. Sep 14 '12 at 15:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.