Preparing UNIX VMs with Oracle Linux 8, RHEL 8, and Later for Conversion to VMware Cloud Director

Before restoring a UNIX-based virtual machine (VM) to VMware Cloud Director, specific preparatory steps are required to ensure a successful conversion and power-on. All necessary steps are described below, including an important additional step for Oracle Linux 8, RHEL 8, and later versions to ensure the vmw_pvscsi driver remains persistently loaded.

Applies To

  • Oracle Linux 8 and later

  • RHEL 8 and later

Overview

During the VM conversion process to VMware Cloud Director, certain SCSI drivers, especially vmw_pvscsi, must be available in the initial RAM disk (initrd) or built into the kernel. Without these, the converted VMs will fail to boot.

Procedure

  1. Check if vmw_pvscsi is built into the kernel. Check the kernel configuration by running the following command:

    grep -i pvscsi /boot/config-$(uname -r)
    
    Interpret the output as follows:

    • If it contains CONFIG_SCSI_VMW_PVSCSI=y, then the driver is built into the kernel. No further action is needed.

    • If it shows CONFIG_SCSI_VMW_PVSCSI=m, the driver is a module and must be included in the initrd.

  2. Check if vmw_pvscsi is in the initrd. Run the following command:

    lsinitrd | grep -i vmw_pvscsi
    
    If no output is returned, the module is not included in the initrd and must be added.

  3. Ensure the vmw_pvscsi driver is persistently loaded. Run the following command to persist the module across reboots:

    echo "vmw_pvscsi" | sudo tee /etc/modules-load.d/vmw_pvscsi.conf
    
    This ensures that the vmw_pvscsi module is loaded every time the system boots.

  4. Rebuild the initrd image as follows:

    1. Make a backup of your existing initrd by running the following command:

       cp /boot/initramfs-$(uname -r).img /boot/initramfs-$(uname -r)-backup.img
      
    2. Rebuild the initrd with the required driver by running the following command:

      dracut --force --add-drivers "vmw_pvscsi" -v
      

      Alternatively, regenerate all initrd images (not usually required unless you need full regeneration) by running the following command:

      dracut --force --regenerate-all
      
      Or for the current kernel only:

      dracut -f /boot/initramfs-$(uname -r).img $(uname -r)
      
  5. Verify vmw_pvscsi is in the rebuilt initrd by running the following command:

    lsinitrd | grep -i vmw_pvscsi
    
    The output will confirm that the driver is included.

  6. Reboot the VM running the following command:

    reboot
    
  7. After the VM reboots, verify that the vmw_pvscsi module is loaded by running the following command:

    lsmod | grep vmw_pvscsi
    
    The output will indicate that the module is loaded.

Other Important Considerations

  • Ensure DHCP is configured for the source VM. Static IPs are not retained during conversion.

  • For Linux VMs, the failure to load required drivers such as vmw_pvscsi will prevent the VM from booting in VMware Cloud Director.

  • For Azure VMs, do the following:

    • Ensure that Windows VMs have the pagefile enabled on the C: drive.

    • Ensure that Linux VMs have fstab entries using UUIDs, not disk names.

Post-Conversion Actions

  • You may need to manually update disk assignments, especially for UEFI-booted systems or when multiple disk controller types are used.

  • VMware Tools is not automatically installed. Use the vSphere client to install them after conversion.

  • Disks for Windows VMs may be offline post-conversion. Bring them online manually.

×

Loading...