Change Nutanix AHV Virtual Machine Disk Bus Type

I have had a few questions about how to change bus type for a Nutanix AHV based virtual machine (VM) over the past month so this blog post will be how to change the disk bus type for a CentOS 7.3 based VM running on the Nutanix hypervisor AHV.

You can add new disk and also delete existing disk, which is what I’ll be doing in this blog, from acli without shutting down the VM, but since we will be messing around with the system disk I’ll start with shutting down the VM.

Log on to any Nutanix Controller Virtual Machine (CVM) in the Nutanix cluster and follow the below steps to change bus type for a VM disk.

    1. Shut down the VM and identify the disk you want to change bus type for. Interested in the ide.0 one here.
    2. Clone the existing IDE disk to a new SCSI based disk by running the following command (skip acli if your in the acli shell):
      1. acli vm.disk_create <vm-name> bus=scsi clone_from_vmdisk=<vm-disk>

    3. Delete the old disk unless you want to save it for verification purposes for a while. You can delete the disk from PRISM (not when the VM is running) or via acli by running the below command:
      1. vm.disk_delete <vm-name> <disk>

    4. Verify the new configuration via:
      1. acli
      2. PRISM
    5. Power on the VM using the below command or use PRISM.
      acli vm.on <vm-name>

    6. Launch the VM console or connect via remote access protocol (in this case SSH) to verify the VM is ok.

As outlined in the Nutanix AHV Best Practices Guide it is recommended scsi based disk unless specific reasons exists not to.,

The environment used for this test was AOS 5.0.1 and AHV 20160925.30.

1 ping

Comments have been disabled.