How to Copy a Virtual XP machine

Page 1 of 2 12 LastLast

  1. Posts : 1
    Windows 7 RC
       #1

    How to Copy a Virtual XP machine


    I have tried to make a copy of a virtual XP machine for backup purposes, but the new Virtual machine will not open. Any Ideas on the correct procedure to make a copy of an existing virtual machine?
      My Computer


  2. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #2

    Hello, jpgailey, and welcome to SevenForums, The Ultimate Windows 7 site.

    Every virtual hard drive (vhd) created with Virtual PC consists of three files if it is turned off, or of four files if it is hibernated or running. The file extensions for these files are:

    • .vhd = Virtual Machine virtual hard drive image
    • .vmc = Virtual Machine settings file
    • .vsv = Virtual Machine saved state file
    • .vmcx = Virtual Machine description and registration settings

    First three files are located in C:\Users\Your_Username\AppData\Local\Microsoft\Windows Virtual PC\Virtual Machines, the last one in C:\Users\Your_Username\Virtual Machines. The two latter files are created automatically; to make a copy of a Virtual Machine we only need .vhd and .vmc files. In this example we call the original virtual drive Windows XP Mode, and the copy we create Windows XP Mode- Copy. You can name all your virtual drives as you like, as long as you remember to modify the settings file as described here.

    Copying Virtual XP or any other virtual hard disk created with Virtual PC is very easy and fast. Here's what you have to do:

    1. Turn off your Virtual XP, do not hibernate it
    2. Open Folder Options, choose Show hidden files, folders and drives. Uncheck Hide extensions for known file types
      How to Copy a Virtual XP machine-hide_extension.png
    3. Goto C:\Users\Your_Username\AppData\Local\Microsoft\Windows Virtual PC\Virtual Machines
    4. Copy Windows XP Mode.vhd and Windows XP Mode.vmc files. To be sure you copy the right files you can open Folder Options and uncheck "Hide extensions for known file types" and click OK
    5. Paste files to the same folder. Windows adds word Copy to both filenames, so now you have two new files: Windows XP Mode - Copy.vhd and Windows XP Mode - Copy.vmc
    6. Open Windows XP Mode - Copy.vmc with Notepad. It is a xml-file, so you can edit it normally with Notepad
    7. Find the following string containing virtual drives name: <drive_type type="integer">1</drive_type>
      How to Copy a Virtual XP machine-name_of_vhd.png
    8. Under the <drive_type...> change the vhd-file name to Windows XP Mode - Copy.vhd both in <absolute type="string"> and <relative type="string">
    9. Find the following place under <virtual_network> containing MAC-adress for Virtual XP's ethernet adapter: <id type="bytes">
      How to Copy a Virtual XP machine-ethernet.png
    10. To allow two copies of Virtual XP to connect to network simultaneously , we have to change the MAC-adress of the ethernet adapter to avoid MAC-adress conflict. Adress is given in hex, 0-9 and A-E. It is enough to change one bit. In this example we have changed the last bit from 1 to 0
    11. Save and close the file
    12. Go to C:\Users\Your_Username\Virtual Machines , copy Windows XP Mode.vmcx and paste it to same folder
    13. Open the file Windows XP Mode - Copy.vmcx with Notepad
    14. Change the vhd-file name to Windows XP Mode - Copy.vhd both in <primary_disk1 type="string"> and <vmc_path type="string">
      How to Copy a Virtual XP machine-name_vmcx.png
    15. Save and close the file
    16. Open Folder Options and choose Don't show hidden files, folders or drives. Check Hide extensions for known file types and click OK.

    That's it. Now you can run two Virtual XP's simultaneously.

    How to Copy a Virtual XP machine-virtualxp_copy.png

    Have fun,

    Kari
    Last edited by Kari; 02 Dec 2009 at 11:37. Reason: posting back to back (double posting) is frowned upon
      My Computer


  3. Posts : 7,878
    Windows 7 Ultimate x64
       #3

    Here is how I do it
    1). Shut down original machine
    2). Copy the large virtual hard drive file to another location
    3). Create a new VM and give it a new hard drive of any size
    4). Copy the large virtual hard drive file from the backup location into the new folder
    5). Go into the new VM and delete it's hard drive from the hard drive
    6). Choose add hardware, add an existing hard drive and point at the file that you just copied over
    7). Start the new VM.
      My Computer


  4. Posts : 5,941
    Linux CENTOS 7 / various Windows OS'es and servers
       #4

    Hi there
    If you use a product like vmware just power off the vm and then on the menu choose CLONE VM>

    You can either make a "linked" clone or a full clone. the full clone is what you need as the "linked" clone will still require access to the state of the original vm.


    (I think virtual box has this facility as well).


    Another method is to install acronis true image on your VM and back it up.

    Then create another vm. install acronis true image and restore your original vm.

    Cheers
    jimbo
      My Computer


  5. Posts : 78
    Windows 7 RC 64bit
       #5

    will this let you have more than 1 XP vm, if you copy the "xp mode" vm?
      My Computer


  6. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #6

    s0me0ne said:
    will this let you have more than 1 XP vm, if you copy the "xp mode" vm?
    Yes. I have currently 3 separate, individual Virtual XP's for test purposes. Come back if you have any problems.

    Three separate Virtual XP's starting, same time on same computer:

    How to Copy a Virtual XP machine-starting_virtual_machines.png


    Three different users logging each on own XP:

    How to Copy a Virtual XP machine-login_three_virtualxps.png


    Three XP's running:

    How to Copy a Virtual XP machine-three_users_three_xps.png


    Kari
      My Computer


  7. Posts : 78
    Windows 7 RC 64bit
       #7

    Sweet. So copying XPMode wont mess things up? I was worried it might confuse win7 since you could pull apps from 3 different xpmode vms
      My Computer


  8. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #8

    Guten abend, s0me0ne. Willkommen in das SevenForum.

    Of course every virtual session uses a lot of your computers resources, other than that there are no problems.

    Kari
      My Computer


  9. Posts : 2
    Windows 7 Professional
       #9

    Kari,

    I was able to follow your directions, but the copy of the WinXP Mode has greyed out login credentials in the settigs. That makes me feel that it's not a fulluy independent virtual session. Is it necessary to duplicate the parent disk as well? My purpose is to test potential malware and be able to just delete one copy if need be and revert to a backup virtual XP. (I am aware of the undo disk feature, but I'd feel more comfortable simply having a full second clean copy.)

    Thanks,
    Mick
      My Computer


  10. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #10

    Hi Mick, welcome to the Seven Forums.

    I'm running three separate XP virtual machines for testing purposes and they are all working well, indepently. Any copy of XP Mode is always looking the base (or parent) drive in C:\Program Files\Windows XP Mode and it should remain there. It is not necessary to copy the base when copying the XP Mode.

    A bit more "easy to read" tutorial is found here.

    Kari
      My Computer


 
Page 1 of 2 12 LastLast

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 23:29.
Find Us