Preparing VMs for Conversion to OpenStack - For Linux VMs that Run in VMware

Updated

Before you perform a backup operation for Linux virtual machines that you plan to convert, prepare the VMs for conversion to OpenStack.

Before You Begin

  • Note that virtual machines running the following guest operating systems can be converted to OpenStack instances:

    • CentOS 7

    • RHEL 7

  • For UNIX flavors that do not include VirtIO drivers, install VirtIO drivers on source VMs. By default, RHEL 7.0 and CentOS 7.0 have VirtIO drivers pre-loaded.

  • If the source VM has more than four disks, override the controller type by adding the additional setting sConvertControllerTypeTo to the source VM, and and then setting the value of the additional setting to scsi. For more information, see Overriding the Controller Type.

  • If the source VM contains a device entry in etc/fstab in the following format:

    /dev/device_name mountpoint fs_type mount_args

    change the entry in the source VM to use the following format instead:

    UUID=fs_uuid mountpoint fs_type mount_args

    You can run the lsblk -f command on the source VM to return a list of the UUIDs for block devices in the source VM.

  • To convert a VM with more than four disks, libvirt version 1.3.3 or later is required on the destination Nova compute nodes for the converted OpenStack instance.

    Red Hat Bug 1343302 reports an issue with attaching more volumes for earlier libvirt versions.

  • Perform a full VM backup of the VMware (source) virtual machines.

Procedure

If the source VM has more than four disks, make changes to the source VMs to ensure that they can be converted successfully.

  1. Verify that required drivers are included in the initramfs RAM disk image.

    Although virtio drivers are preloaded with Linux, the drivers might not be included in the initramfs RAM disk image that drivers are loaded from.

    1. To check whether the drivers are included in the initramfs disk image, run the following command:

      lsinitrd | grep -i virtio

      If virtio drivers are already included, you do not need to make any further changes to the Linux VMs.

      If the command does not list virtio drivers, then perform Step b through Step h, below.

    2. Run the following command to identify the initramfs file version:

      uname -r
    3. Create a backup of the current initramfs image as follows:

      cp /boot/ Current_Image_Name /boot/ Current_Image_Name.backup

      where Current_Image_Name is the initramfs file version.

    4. Run the following command to edit the dracut.conf file:

      vi /etc/dracut.conf
    5. Uncomment the line that contains "add-drivers", and then add the drivers to the line, with spaces separating each module as shown in the following example:

      add_drivers+= " virtio virtio_ring virtio_pci virtio_scsi virtio_net virtio_balloon "
    6. Go to the boot folder: cd /boot

    7. Recut the initramfs image as follows:

      dracut -f -v
    8. List the RAM disk image contents and verify that the virtio drivers were added, as follows:

      lsinitrd | grep -i virtio
  2. Perform a backup operation for the modified source VMs.