change boot order for dual boot(Windows XP and Ubuntu)

If you installed Windows and Ubuntu as dual boot then by default windows will boot 1st. To change the boot order we need to change the boot order.

Change default operating system at boot
 To change which operating system starts by default when the computer starts up, edit the grub configuration file.
1.Make a backup of the configuration file, and open it in a text editor:
  cp /boot/grub/menu.lst /boot/grub/menu.lst backup-menu.lst  ### this will to keep a backup of original file
  vi /boot/grub/menu.lst  ### open menu.lst file
2. Find “default 0” line in the menu.lst file
   Ex: type /default and press enter to go to that line.
3. Replace with the following line:
      default X

    Note: You should replace X with a number, according to the order which your operating systems appear in the configuration file. You should start counting from 0. For example, if you wish the default operating system to be the first in the list, replace X with 0, if you wish the default operating system to be the second in the list, replace X with 1, and so on.

No comments:

Post a Comment