• ARTICLES
SEARCH

How-To Geek

Create Shortcuts to Quickly Reboot to the Alternate OS in a Vista/XP Dual-Boot

If you have a dual boot system and often switch back and forth from Vista to XP, you’ve probably already been annoyed with the fact that you have to wait until the boot menu comes up and choose the right OS… and half the time you step away and it ends up booting into the wrong one anyway.

With some simple batch files and command line magic, we can make two shortcuts so you can just simply click to “Reboot Into XP” or “Reboot into Vista”, and be done with it.

Create the Shortcut to Reboot into XP

To create the shortcut we’ll need to create a simple batch file, which we can do by opening up notepad and then pasting in the following text:

bcdedit /bootsequence {ntldr} /addfirst
Shutdown /r /t 0

The first line runs the bcdedit tool and sets the XP partition as a one-time boot default, and then the second line calls the shutdown command with the reboot option.

Once you are done, save the batch file into a folder, making sure to name the file with the .bat extension and choose All Files in the “Save as type” drop-down (very important).

image

Now you’ll want to create a shortcut to the batch file in a location that is easy to access, and give it a useful name. Open up the shortcut properties and click the Advanced button, then choose Run as administrator. Very important!

image

You can also give the shortcut a fun icon if you want, or not. Either way, you’ll now have a shortcut that will reboot you into XP by clicking on it (and clicking through the UAC prompt if you have UAC enabled).

image

For extra credit you can also create a shortcut that doesn’t prompt for UAC, but it takes a few more steps to create.

Create the XP Shortcut to Reboot into Vista

The next part of the tutorial requires you to be in Windows XP because we’re going to create the shortcut that reboots you back into Vista.

The first thing you need to do is figure out which drive letter has Windows Vista on it when you are in XP. In my installation, Vista is located on the E: drive:

image

We’ll need to know this so we can run the same bcdedit command that we did in the first step. Just run it from the command prompt without any arguments like this:

E:\Windows\System32\bcdedit

You’ll need to take a look at the output for something similar to the highlighted portion below, which is the unique ID of your Vista partition as far as bcdedit is concerned.

image

If you right-click and choose Mark in the command prompt, you can select it and copy to the clipboard by using the Enter key. We’ll need it for the next command.

Open up notepad to create a new batch file just like we did before, and paste in the following, replacing IDGOESHERE with the text that you copied from the command prompt above, and making sure to replace E: with your drive letter if it’s different.

E:\Windows\System32\bcdedit /bootsequence IDGOESHERE /addfirst
shutdown /r /t 0

For example, my command looks more like this:

E:\Windows\System32\bcdedit /bootsequence {005f3343-44da-11dd-82b2-9c50424120af} /addfirst
shutdown /r /t 0

Now save the batch file, making sure to choose a .bat extension and choose All Files under “Save as type”.

image

Under XP there’s no reason to make a shortcut, although you certainly can if you’d like.

image

This batch file will immediately reboot you back into Vista.

Speed Up the Reboot Process

One of the first things you’ve probably noticed if you reboot all the time is that waiting 30 seconds for the default OS is a waste of time. You likely already know how to speed this up, but if you don’t we’ll cover it anyway.

Open up Control Panel \ System and click on the “Advanced system settings” link on the left-hand corner.

image

Then click on the Settings button under the “Startup and Recovery” section.

image

You can change the default of 30 seconds down to something much less… I usually choose 3 seconds, but you can use whatever amount you’d like. I wouldn’t recommend setting it much less, cause it’ll be very difficult to choose manually otherwise.

image 

Even Quicker Reboots

You can speed up the reboot process even more by setting up Vista and XP to automatically login. Of course, you should only do this on a personal desktop at home, I wouldn’t recommend automatic login on a laptop or work computer.

The title says Windows Vista, but the same exact steps work on XP as well:

Make Windows Vista Login Automatically

Lowell Heddings, better known online as the How-To Geek, spends all his free time bringing you fresh geekery on a daily basis. You can follow him on if you'd like.

  • Published 08/13/08

Comments (14)

  1. InDiSent

    Nice. How do i make one for Ubuntu also?

  2. Squee

    And also one in Ubuntu to boot automatically to Vista.

  3. Rothgar

    Yep, booting into linux and visa versa would be a great tip too. :)
    I think you would need access to the boot partition to edit grub to do it but it shouldn’t be too hard.
    especially not for uber geeks like yourselves.

  4. ender

    Also interested in an ubuntu version.

  5. mmg1818

    I run only Shutdown /r /t 0 for Vista ;)

    Thanks

  6. ASLM

    If you use grub you can do this very easily in ubuntu.
    –First, make a backup copy of your /boot/grub/menu.lst file.
    –Create as many copies of this file as the number of OS you want to boot to.
    –give these copies distinguishing names like “menu_XP.lst”
    –In each of the copies change the entry “Default N” so that N corresponds to the number of the corresponding OS. You might wanna change the “timeout X” too. (In my case, I put 0 for ubuntu and 3 for XP.)
    –Then you just write a command that changes the menu.lst file for each of the OS. To do that, write a text file with the lines:
    —-cd /boot/grub
    —-sudo cp menu.lst
    –Name it whatever you want, mark it as executable, and copy it to your /bin folder.

    I have no idea how one might make a shortcut in windows that changes the menu.lst file in the linux partition. Which is why I couldn’t leave timeout 0 for windows. I’d be glad if anyone knows how to do that.

  7. ASLM

    Also, if you want the system to reboot immediatly after changing the menu.lst, just add a “sudo shutdown now -r” line at the end of the text file.

  8. olad

    did anyone mention that your site is a paradigm of clarity and readability? everytime i visit, i enjoy not just the article but the mini-forum that follows each one – most are from informed and thinking minds, even if they disagree with you.

  9. Pham Nuwen

    Awesome!

    Now I just need to get me some Vista (for the Direct X 10 goodness coming up in STALKER Clear Skies) and figure out how to get sound and networking working in Ubuntu, and I will be in Computing ZEN. SOOOOOO bored of XP!

    Sidenote: I haven’t checked this in Ubuntu, but I know in PC Linux OS 2007 Final, when you go to shut down, you can click and hold the restart button and choose which Grub session to load, thereby bypassing the Grub screen.

  10. Miro

    hi,
    all is ok, but i dont reboot from XP to XP..
    1.partition is Vista, 2.partition is XP..
    Vista MBR.

    Please HELP


    VISTA – reboot = VISTA
    VISTA – reboot into XP = XP
    XP – reboot = VISTA ( please help with XP into XP)
    XP – reboot into VISTA = VISTA

  11. Michael

    I am currently having two problems with the shortcut from XP to Vista. (By the way, everything else worked great! The only site that helped me on achieve success with an HP). The first time I tried it I was able to run bcedit successfully, but when I did the reboot I got a blue screen of death. I had to go back and reinstall Vista to clear the problem. Since then, when I run bcedit in XP, it flashes by extremely fast and closes itself so I cannot even try to get the ID number again. Any ideas?

  12. Bjorn

    Neither methods worked as supposed, I was a bit disappointed (sorry for this) …

  13. SteveB

    The reboot to Vista64 from XP32 Pro will not work. Anyone know how to achieve this?

  14. Bry

    @miro

    how bout this

    in your xp startup folder create a shortcut of “bcdedit /bootsequence {ntldr} /addfirst”

    and d-o-n-e

Get Free Articles in Your Inbox!

Join 134,000 newsletter readers

Email:

Go check your email!