Chapter 2. Installation
The installation phase requires the following stages:
- Prerequisites: Installing and configuring the Red Hat environment
- Creating the RHV conversion host(s)
- Configuring the RHV conversion host(s)
- Configuring the maximum number of concurrent migrations (optional, only supported for SSH transformation)
2.1. Prerequisites
Before migration, your environment must have the following prerequisites:
- Target datastore size
- The target datastore must have sufficient space for the virtual machines that will be migrated.
- BIOS settings of hosts
- The BIOS settings of the physical hosts should be set for optimal performance, rather than power-saving, according to the vendor’s recommendations. Where applicable, the C1E halt state should be disabled.
- Red Hat Virtualization Manager 4.2.4 or later installed
- See the Red Hat Virtualization Planning and Prerequisites Guide and Installing the Red Hat Virtualization Manager.
- Red Hat Virtualization Hosts 4.2.4 or RHEL 7.5 hosts or later installed
- See Installing Red Hat Virtualization Host or Installing Red Hat Enterprise Linux Hosts.
- Network
The VMware network must be extended to the RHV environment.
ImportantThe network configuration must not be changed in any way during the migration. IP addresses, VLANs, and other network configurations must be the same, before and after migration, because the conversion process preserves the source virtual machine MAC addresses.
- Ports
The following ports must be enabled:
- 22 - SSH
- 443 - CloudForms, Red Hat Virtualization Manager, and VDDK
- 902 - CloudForms to VMware
-
5480 -
virt-v2vto vCenter
For more information, see Ports used by Red Hat CloudForms Management Engine 5.1 and above.
- Data and ISO storage domains attached to the RHV data center
See Storage in the Red Hat Virtualization Administration Guide.
NoteIMS only supports shared storage, such as NFS, iSCSI, or FCP. Local storage is not supported.
- VirtIO and Guest Tool images uploaded to the ISO storage domain
See Uploading the VirtIO and Guest Tool Image Files to an ISO Storage Domain.
NoteThe VirtIO image file name must include the version number: virtio-win-version.iso.
- Red Hat CloudForms 4.6.4 or later installed
- See Installing Red Hat CloudForms on Red Hat Virtualization.
- VMware and RHV environments added to CloudForms
- See VMware vCenter Providers and Red Hat Virtualization Providers.
- Virtual machine names checked
-
Virtual machine names may contain only upper- or lower-case letters, numbers, underscores (
_), hyphens (-), or periods (.). Special characters and spaces are not permitted. - RHV hosts authenticated
- See Authenticating Red Hat Virtualization Hosts.
- VMware hosts authenticated
- See Authenticating VMware vCenter Hosts.
- RHV conversion hosts created and configured
- See Section 2.2, “RHV Conversion Hosts”.
2.2. RHV Conversion Hosts
All the virtual machines that are specified in a migration plan are migrated at the same time. Therefore, the number of RHV conversion hosts that you create depends on the number of virtual machines you intend to migrate. Red Hat recommends configuring the RHV conversion hosts on physical machines, not nested virtual machines.
Each conversion host is limited to 10 concurrent migrations, unless you change the default value.
The maximum number of concurrent virtual machine migrations per conversion host is 10, for VDDK transformation, and 20, for SSH transformation. The SSH transformation limitation applies only to Red Hat Virtualization 4.2.5, not to later versions.
Multiple conversion hosts are recommended, even for smaller migrations, for load-balancing purposes. The number of virtual machines that you can migrate at the same time depends on your infrastructure capabilities. Each migration requires a certain amount of network bandwidth, I/O throughput, and processing power for the conversion process. You should test your environment to understand how many migrations can occur simultaneously without negative effects.
Datapath Transformation Options: VDDK or SSH
Select the best datapath transformation option for your environment, either VDDK or SSH:
- VDDK
- Recommended because it is approximately twice as fast as SSH
-
Compiled with
nbdkitto provide direct connectivity to the virtual machine disks - VDDK package must be downloaded
- Conversion host configuration requires a location
- Each conversion host supports only 10 concurrent migrations
- SSH
- Does not require additional downloads, packages, tools, or compilation
- RHV and VMware environments must share SSH keys
- SSH access must be enabled on ESXi hosts
- Slower than VDDK
- Suitable for larger scale migrations than VDDK
2.2.1. Creating and Configuring RHV Conversion Hosts for VDDK Transformation
Create and configure RHV conversion hosts for VDDK transformation:
-
Log in to the VMware VDDK Documentation site and download the latest VDDK package (for example,
VMware-vix-disklib-6.5.3-8315684.x86_64.tar.gz) to your local machine. -
Using SCP, copy the VDDK package to
/var/www/htmlon the Manager machine. Go to the Ansible conversion hosts playbooks directory on the Manager machine:
# cd /usr/share/ovirt-ansible-v2v-conversion-host/playbooks/
Create a
conversion_hosts_inventory.ymlinventory file with the following variables:all: hosts: host1.example.com: host2.example.com: vars: ansible_ssh_private_key_file: /etc/pki/ovirt-engine/keys/engine_id_rsa v2v_vddk_package_name: VMware-vix-disklib-version.x86_64.tar.gz v2v_vddk_package_url: http://Manager_FQDN/VMware-vix-disklib-version.x86_64.tar.gzEnable the conversion hosts:
# ansible-playbook -i conversion_hosts_inventory.yml conversion_host_enable.yml
NoteThe Ansible role checks for the presence of the RHV guest tools ISO image in the ISO storage domain. This image is used to migrate Windows virtual machines.
Verify that the conversion hosts are enabled:
# ansible-playbook -i conversion_hosts_inventory.yml conversion_host_check.yml
If you upgrade your RHV environment, you must run the conversion_host_enable playbook again, with the option -e v2v_vddk_override=true, to update the IMS packages.
After creating the RHV conversion hosts, you must configure them in CloudForms. See Section 2.2.3, “Configuring RHV Conversion Hosts in CloudForms”.
2.2.2. Creating and Configuring RHV Conversion Hosts for SSH Transformation
Create and configure RHV conversion hosts for SSH transformation:
Go to the Ansible conversion hosts playbooks directory on the Manager machine:
# cd /usr/share/ovirt-ansible-v2v-conversion-host/playbooks/
Create a
conversion_hosts_inventory.ymlinventory file with the following variables:all: hosts: host1.example.com: host2.example.com: vars: ansible_ssh_private_key_file: /etc/pki/ovirt-engine/keys/engine_id_rsaEnable the conversion hosts:
# ansible-playbook -i conversion_hosts_inventory.yml conversion_host_enable.yml
NoteThe Ansible role checks for the presence of the RHV guest tools ISO image in the ISO storage domain. This image is used to migrate Windows virtual machines.
Verify that the conversion hosts are enabled:
# ansible-playbook -i conversion_hosts_inventory.yml conversion_host_check.yml
Enable SSH on all the VMware hypervisors. See Enable SSH from the vSphere Web Client for details.
NoteIf you created the RHV conversion hosts manually, without using the
ovirt-ansible-v2v-conversion-hostrole, you must create the key pairs on each conversion host for thevdsmuser:# install -o vdsm -g kvm -m 0700 -d /var/lib/vdsm/.ssh # ssh-keygen -t rsa -N '' -C "vdsm@hostname" -f /var/lib/vdsm/.ssh/id_rsa # chown vdsm:kvm /var/lib/vdsm/.ssh/id_rsaCopy the SSH keys to the VMware hypervisors:
# ssh root@esx1.example.com sh -c 'cat >> /etc/ssh/keys-root/authorized_keys' < /var/lib/vdsm/.ssh/id_rsa.pubNoteThis step ensures that each conversion host has the SSH key of the ESXi host in its known_hosts file.
Validate the configuration by connecting to the VMware hypervisor using
ssh-agent, the program thatvirt-v2vuses to connect to the hypervisor:# sudo -u vdsm ssh-agent SSH_AUTH_SOCK=/tmp/ssh-Gi2oSn44DHNL/agent.65904; export SSH_AUTH_SOCK; SSH_AGENT_PID=65905; export SSH_AGENT_PID; echo Agent pid 65905; # sudo -u vdsm SSH_AUTH_SOCK=/tmp/ssh-Gi2oSn44DHNL/agent.65904 ssh-add # sudo -u vdsm \ SSH_AUTH_SOCK=/tmp/ssh-Gi2oSn44DHNL/agent.65904 ssh root@esx1.example.com
If the connection is successful, the RHV conversion host is correctly configured for SSH transformation.
If you are using SSSD with single sign-on, see Troubleshooting for additional information.
After creating the RHV conversion hosts, you must configure them in CloudForms. See Section 2.2.3, “Configuring RHV Conversion Hosts in CloudForms”.
Additional resources
- For more information, see V2V - Conversion Host - Ansible.
2.2.3. Configuring RHV Conversion Hosts in CloudForms
Configure the RHV conversion hosts in CloudForms:
- Click → → and select a Red Hat Virtualization Host.
-
Click the
Policydrop-down button and selectEdit Tags. -
Select
V2V - Transformation Hostfrom the tag drop-down list andtas the assigned value. -
Select
V2V - Transformation Methodfrom the tag drop-down list and eitherVDDKorSSHas the assigned value. See Datapath Transformation Options: VDDK vs. SSH for more information. -
Click
Save. -
Select the same host, click the
Configurationdrop-down button, and selectEdit this item. -
In the
Defaulttab of the Endpoints section, enter theUsernameroot and the password. -
Click
Validate. If a success message is displayed, clickSave.
Conversion Host Properties
2.2.4. Configuring the Maximum Number of Concurrent Migrations
The default limit for concurrent migrations is 10 for a conversion host and 10 for a provider. You can change this value by setting the Max Transformation Runners attribute for the conversion host or for the provider, or both. The limit that is set for the provider has priority over the limit set for the conversion host. For example, if you set the number of concurrent migrations to 20 at the provider level, while having 3 conversion hosts, the number of concurrent migrations is limited to 20 because the provider’s setting overrides the conversion hosts' setting.
The maximum number of concurrent virtual machine migrations per conversion host is 10, for VDDK transformation, and 20, for SSH transformation. The SSH transformation limitation applies only to Red Hat Virtualization 4.2.5, not to later versions.
The following examples show how to set Max Transformation Runners using the Rails console on the CloudForms appliance.
To set Max Transformation Runners for the conversion host host1.example.com to 20:
# vmdb # rails console irb(main):001:0> $evm = MiqAeMethodService::MiqAeService.new(MiqAeEngine::MiqAeWorkspaceRuntime.new) irb(main):002:0> $evm.vmdb(:host).find_by(:name => "host1.example.com").custom_set("Max Transformation Runners", 20)
To set Max Transformation Runners for the provider My RHV to 30:
# vmdb # rails console irb(main):001:0> $evm = MiqAeMethodService::MiqAeService.new(MiqAeEngine::MiqAeWorkspaceRuntime.new) irb(main):002:0> $evm.vmdb(:ext_management_system).find_by(:name => "My RHV").custom_set("Max Transformation Runners", 30)
The following examples show how to get the current configuration of Max Transformation Runners using the custom_get method. This method returns either the current configuration value or nil, if the value has not been set.
To get the configuration of Max Transformation Runners for conversion host host1.example.com:
# vmdb
# rails console
irb(main):001:0> $evm = MiqAeMethodService::MiqAeService.new(MiqAeEngine::MiqAeWorkspaceRuntime.new)
irb(main):002:0> $evm.vmdb(:host).find_by(:name => "host1.example.com").custom_get("Max Transformation Runners")
To get the configuration of Max Transformation Runners for provider My RHV:
# vmdb
# rails console
irb(main):001:0> $evm = MiqAeMethodService::MiqAeService.new(MiqAeEngine::MiqAeWorkspaceRuntime.new)
irb(main):002:0> $evm.vmdb(:ext_management_system).find_by(:name => "My RHV").custom_get("Max Transformation Runners")
Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.