VMware Cloud Community
eranna
Contributor
Contributor

Script to copy Virtual machine to other ESX server

is there any script that i can copy existing Virtual machine from ESX server to other ESX server and run that script, so that all the Virtual machines can be up and running within no time on other ESX server

Tags (1)
0 Kudos
1 Reply
nabsltd
Enthusiast
Enthusiast

It depends on what type of storage you use.

If the VM files reside on shared storage (SAN, NFS, etc.) that both ESX servers can access, you don't need to copy anything. Just shut down the VM on the first server, register it on the second, and start the VM on the second. You can register using the VI client or the command line (vmware-cmd -s register path-to-vmx-file.vmx).

If the servers don't share storage, you have to copy the files in some way, and that would mean FTP, SFTP, or other methods. How to do this depends on what ports you want to open up on the ESX firewalls, and which services you want to run. After the copy, you would register the VM as above.

0 Kudos