VMware Cloud Community
Panzer
Enthusiast
Enthusiast

Move VM between datacenters

I want to bring with me a VM (with some management tools) between different datacenters, all running ESX3. What is the best way to do this?

0 Kudos
11 Replies
soleblazer
Hot Shot
Hot Shot

No way to really do this with vmotion if they are in different datacenters. You could simply shutdown the vm and scp it from one ESX host to the other. There are also some fancy perl scripts people have written here and tools such as ESX Ranger and Replicator.

0 Kudos
Panzer
Enthusiast
Enthusiast

which files do you copy?

0 Kudos
JonT
Enthusiast
Enthusiast

You can also use the VIC to move the VM if it is powered off, but you have to have the hosts sorted in the same "datacenter" for the move to work. I have tested this and it works fine between two of my Datacenters. Speed on this will totally depend on your network though.

0 Kudos
vmmeup
Expert
Expert

I would clone a copy and keep on in each datacenter. If you ever have to update it just update one and then reclone to new machine and copy to other DataCenter.

In my test environment I keep a esx server that doesn't belong to any datacenters so I can clone to a from with out any problems....works pretty well.

Sid Smith ----- VCP, VTSP, CCNA, CCA(Xen Server), MCTS Hyper-V & SCVMM08 [http://www.dailyhypervisor.com] - Don't forget to award points for correct and helpful answers. 😉
0 Kudos
acr
Champion
Champion

This is actually possible and ive done it..! Assumming you have the pre-reqs betwenn datacenters, fiber etc..

With EqualLogics iSCSI SAN you can move while live an entire VMFS Partition from on Storage Array to another, it doesnt need to be the same Staorage Array either.. (caveat: the same ESX Server still has access to it)

ESX isnt aware it happened... The VMs keep working without interruption..

Oh and this is all out of the box.. No add on Licensing..

Try that in the FC world..

0 Kudos
mbrkic
Hot Shot
Hot Shot

Assuming that all the files are in the same directory on a vmfs, the easiest is to copy the whole directory.

If the VM is shut down and has no snapshots all you really need are the .vmx file, all the .vmdk files and the nvram file.

woharrow
Enthusiast
Enthusiast

I would get a good sized USB drive that you can attach to your laptop.

Then use WinSCP3. (make sure you use the SCP option.) and then just copy the entire directory, or the files you want to the USB drive and you can import them the same way whereever you want! (if you are really up to it there are ways to run the VM in Workstation off of your USB drive, but that's a very different topic.)

Then again I always like ACR's method!!! all you need is a few EQL arrays and you're good to go!

Wade

0 Kudos
Paul_Lalonde
Commander
Commander

If you don't want to bring down the VM, you could always use a hot-backup drive image tool like Acronis True Image. It allows you to create complete backups of your OS environment while the server is running, and it can create the archive on CD, DVD, FTP, or a network share.

Paul

0 Kudos
acastle
Contributor
Contributor

The solution that I came up with for moving between ESX3 Datacenters that are physically sepparated is this.

Open port in firewall for nc to use such as 4242 or something else not being used.

source server: esxcfg-firewall -o 4242,tcp,out,nc

destination server: esxcfg-firewall -o 4242,tcp,in,nc

On the destination computer do the following:

make a folder whith the apropriate rights and cd into it.

nc -l -p

Depending on the network connection between hosts/datacenters and the size of the VM the transfer speed will vary. The part I was avoiding was the encription overhead of SCP.

Since tar doesn't "listen" for a port there's not much of a security risk. For those that are paranoid edit your ip tables or close the ports that were opened.

0 Kudos
eharvill
Enthusiast
Enthusiast

Yuck.

Using tar across the network is as bad as when I used cpio/remsh across hosts to accomplish the same thing back in the day. lol

0 Kudos
acastle
Contributor
Contributor

Certainly not pretty I agree. Concidering the through put on SCP was 1Mbps verses tar over nc connection at 3.5 Mbps. I'm not waiting 2 hours and 40 + minutes for a scp copy. I'll kill a SCP transfer any day when it can be done faster.

0 Kudos