Hyper-V Program Manager
The first thing that I needed to do as part of my big rebuild was to move non-critical virtual machines to a remote file server. The easiest way to do this would have been to export the virtual machines to a local location and then move them up to a network share. Unfortunately I did not have enough space on the local hard disk to do this. So what I needed to do was to export the virtual machines directly to a remote network share.
Luckily I had two things working in my favor:
Now it is possible to do this still if the above two items are not true – but it gets a lot more complicated.
Given this setup I needed to create and configure a share for the exported virtual machines to be created on. I logged into my desktop computer and created a share – which granted full access to my user account by default. But this is not enough for Hyper-V.
Hyper-V does a lot of operations using local service accounts on the Hyper-V computer. So the network share needs to have permission granted for both the user account that you are using and for the computer account for the Hyper-V server. The user account is easy to setup (and in my case was setup by default). Setting up the computer account is a little trickier.
To do this on a Windows 7 computer you will need to go to the folder that is being shared and:
Now that all of that is done you can go to the Hyper-V server, select the virtual machine that you want to export, and when you are prompted for a location you can type in the UNC path of the share you have just created, and specify a subfolder for the virtual machine. For example – if I was exporting a virtual machine called “WDS Server” to the “Export” share on my computer “Benjamins-PC” I would enter “\\Benjamins-PC\Export\WDS Server” into the export location for the virtual machine.
When you want to import the virtual machines back off the network share – you need to ensure that you select to “Duplicate all files so the same virtual machine can be imported again” – as we do not support running virtual machines from a network share.
One final note to make – while we do not support running virtual machines from folders where NTFS compression is enabled – you can enable it on a folder where you are storing exported virtual machines to reduce the amount of space needed.
I want to export the VM to a NAS System which is Unix based, so I cannot use the description given here. I would have to set up an account on the NAS with the same User name and Password to make it work. How can I solve this problem?
Hi Ben. It looks like a very useful sulution. Unfortunately, I must export/backup VMs from various hardwares in a DMZ, so no domain is implemented.
If I try to add VMserverNAME$ as you explained, I am not able to complete the operation, since the object cannot be found :-( I supose because it is a workgroup environment :-((((
Do you have a eorkaround ?
Have a nice day
Hi Ben. It looks like a very useful solution. Unfortunately, I must export/backup VMs from various hardwares in a DMZ, so no domain is implemented.
Do you have a workaround ?
Hi Ben , Is there a way to use export onto a library server and later import from library server onto the host ?
I mistakenly copied the VM's to a USB attached drobo from 2008r2 and delted them from the host. What a mistake, Since I did no export.
I exported a new one and now see a structure and a couple xml type files. Two files and a file structure are missing from the ones I had earlier moved/copied out. Can I fake it to get them back? Looks like one file is easy but the other looks like a cab file with a familiar xml structure, but lacks info I cannot see that needs edit...
Many thanks for taking the time to post this - explains the strange error I am getting while attempting to export to a network share.. Thank you.
I did what you mentioned above. Yet it does not work in my environment. Could it be because I'm using the Hyper-V console from the destination host? The source host is server Core therefore it has no console.
Do I have to this if I'm exporting the VMs to Cluster Shared Volumes (CSV)?
I need to export 5 VMs from Hyper-V R2 (W2K8 R2) to Hyper-V 3.0 (W2K12).....
Thanks in advanced.
both Hyper-Vs joined to the same domain (or trusted domains):
the Computername$ trick will work.
the source joined to the domain and the destination not joined:
enable Guest account temporarily, give Share and NTFS permission to guest. the export will work.
the source not joined to the domain, the destination joined:
have not tested!
neither the source nor the destination joined to the domain:
I can NOT get the export working what so ever! will not give up on this though.
Do you have any idea why this is like this? my VMs are rather big and it takes twice the time to export it to a local storage and then manually copy over the network. I prefer to be able to export over the network even if the 2 hyper-Vs are not joined to any domain.
Another solution, on Hyper-V 2012 R2 core, this is what I used...
1. Connected usb ext drive to host, not joined to domain. Shared drive: net share <share name>=e:\ /GRANT:<hyper-v admin user>,FULL
2. From domain member VM, SBS 2011(or other vm of your choice), map network drive, check reconnect at logon and connect using different credentials. \\<host server name>\<share name above> and enter the credentials for the hyper-v admin user above.
Used to backup files for off-site using 2 external drives to alternate backups. Works for using the same drive mapping on the VM for file backups.