Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save myst3k/2ccab6001b296432d52cd211e687aa9c to your computer and use it in GitHub Desktop.
Save myst3k/2ccab6001b296432d52cd211e687aa9c to your computer and use it in GitHub Desktop.
#install ovftool
# connect to system and check current virtual machines
ovftool vi://root:<password>@<ip-address>/
#shut down VM's which you want to copy
#disable ssl verification if you need to, you can this with the following operations if you need to
ovftool --noSSLVerify
#copy from one esxi host to another esxi host which has the same network names
ovftool vi://root:<pass>@<ip-address>/"<VM Name>" vi://root:<pass>@<ip-address>
#example with different network names
ovftool --net: "<src-net-name>"="<dst-net-name>" vi://root:<pass>@<ip-address>/"<VM Name>" vi://root:<pass>@<ip-address>
#backup directly to local ova
ovftool vi://root:<pass>@<ip-address>/"<VM Name>" vCenter.ova
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment