Link to home
Create AccountLog in
Avatar of discoveranother
discoveranother

asked on

HyperV vhd

How can I copy vhd files from one hyperv server to a new one ? I gather there is a command line to do this to keep everything intact and the same.
Avatar of jpthegeek
jpthegeek

There is multiple ways to move the VM, the easiest is to use the move command, in HyperV Manager simply right click the VM and chose move. If you are logged in on the VM host it will move without giving you any authentication error. You must have live migration set up on both VM hosts. This is in the Settings also within HyperV Manager.

http://blogs.technet.com/b/canitpro/archive/2013/03/21/step-by-step-completing-storage-live-migration-in-hyper-v.aspx

This was an issue I was running into, but like I said above if you log in on the machine you're moving it from, if possible. But if you are running HyperV Server 2012, you will have to set up delegated permissions and make sure you reboot afterwards (the HOST)

https://www.experts-exchange.com/questions/28161172/HyperV-Move-VM-Failure.html
You can try robocopy with copyall parameter
Hello,

Here are the steps to manually move the VM from one host to another.

1)      Shutdown the VM

2)      Copy the VHD from source host to destination host

3)      Create a VM on the destination host without a hard drive (attach the hard drive later)

4)      Move the VM VHD file to this newly created VM’s folder

5)      Attach the VHD file with newly created VM from Hyper-V manager (browse to the VHD file which you moved)

6)      Turn on the VM > logon

7)      Start > run > CMD (type these commands in the same order) > 1. “set devmgr_show_nonpresent_devices=1” > 2. “start devmgmt.msc” (it will open up the device manager) > click on “VIEW” in menu > select SHOW HIDDEN DEVICES > uninstall any greyed out VMBUS network adaptor

NOTE: if you use export/import feature, this all be taken care of automatically, make sure that you have the same virtual Network card name on destination server as the source server. Network configuration is critical here whether copying manually or via the import/export utility.


Prads
Avatar of discoveranother

ASKER

Thanks for the info everyone, will read through them all. Transferring from one 2012 to another 2012.
SOLUTION
Avatar of deviprasad_s
deviprasad_s
Flag of India image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
ASKER CERTIFIED SOLUTION
Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
Thanks very much for the excellent replies. Could a vhd file be moved from an external hard drive to hyperv 2012 in the same way ?
SOLUTION
Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.