This guide demonstrates a full migration cycle from VMware to OpenStack using the OS Migrate Ansible collection. You can find all details here:
https://github.com/os-migrate/vmware-migration-kit
The example assumes you already have a conversion host deployed in your destination OpenStack cloud.
There are multiple ways to use the vmware-migration-kit:
- Full migration: Run the provided playbook to migrate VMs.
- Discovery mode: Collect and discover ESXi nodes and export data into a JSON file, which can be updated and reused for migration.
In this example, we will execute a full migration cycle using the playbook migration.yml.
podman pull matbu/aee-fedora-osmpodman run -it matbu/aee-fedora-osm /bin/bashpushd /root/vmware-migration-kit/vmware_migration_kitgit pullmkdir /root/.ssh/
cat <<EOF > /root/.ssh/conv_host
-----BEGIN OPENSSH PRIVATE KEY-----
XXX
-----END OPENSSH PRIVATE KEY-----
EOF
chmod 600 /root/.ssh/conv_hostmigrator:
hosts:
localhost:
ansible_connection: local
ansible_python_interpreter: "{{ ansible_playbook_python }}"
conversion_host:
hosts:
10.0.79.209:
ansible_ssh_user: cloud-user
ansible_ssh_private_key_file: /root/.ssh/conv_hostcp ../vars.yaml .- Set the vCenter password and VDDK thumbprint.
- Ensure the list of VMware guests is specified in the
vmssection:
vms:
- my_vmware_guest_1
- my_vmware_guest_2Run the following command to obtain the VDDK thumbprint:
openssl s_client -connect ESXI_SERVER_NAME:443 </dev/null |
openssl x509 -in /dev/stdin -fingerprint -sha1 -nooutExecute the migration playbook:
ansible-playbook -i inventory.yml migration.yml -e @vars.yaml- Replace placeholders (e.g.,
XXX, IPs, and paths) with actual values. - Ensure the conversion host and VMware environment are properly configured before running the playbook.
Happy migrating! ๐