Virtual Machine displays two datastores in Summary tab despite all its files being located on one datastore
search cancel

Virtual Machine displays two datastores in Summary tab despite all its files being located on one datastore

book

Article ID: 323058

calendar_today

Updated On:

Products

VMware vCenter Server VMware vSphere ESXi VMware vSAN 8.x

Issue/Introduction

This article provides steps to resolve the issue where a virtual machine displays two datastores where it should only be one as all its files are located in the same datastore.

When all VMware virtual machine files are located in one datastore, the following symptoms are seen:

  • A virtual machine appears on two datastores in the vSphere Web Client inventory.
  • The Summary tab displays two datastores despite all disks residing on a single volume.
  • The "Datastores and Datastore Clusters" view displays the Virtual Machine in two datastores within the vSphere Web Client.
  • VM still shows a reference to a source datastore after a Storage vMotion task.
    • In rare occasion in a vSAN cluster, a virtual machine might still show registered in both vSAN cluster (source/destination)
    • it might display virtual objects inaccessible in source cluster after migration.

Environment

VMware vSphere ESXi 7.x

VMware vSphere ESXi 8.x

VMware vSAN 8.x

Cause

 This behavior occurs if the virtual machine maintains a reference to a file on the secondary datastore, such as:

  • An actively mounted ISO or floppy image.
  • A serial output file configured to a secondary datastore.
  • Snapshots taken while an ISO was mounted.
  • VDI delta disks (harddisk-xd-delta.vmdk) referencing a parent disk on another volume.
    • This can be verified by navigating to the datastore holding the vmdk's and then cat the same vmdk file. The 'parentFileNameHint' parameter will show the UUID of the other datastore still showing up on the VM. Also, the file name would be ending with delta.vmdk.
    • esxcli storage vmfs extent list | grep -i Datastore_name
      Datastore_name                 ########-########-####-############              0  naa.####################          1
    • cat harddisk-xd-delta.vmdk
      # Disk DescriptorFile
      version=1
      encoding="UTF-8"
      CID=b09d5b6c
      parentCID=b09dxxxx
      createType="seSparse"
      parentFileNameHint="/vmfs/volumes/########-########-####-############/datastore/<vm_name>.vmdk"
      # Extent description
      RW 209715200 SESPARSE "harddisk-xd-delta-sesparse.vmdk"

Note: In some cases, the vmware.log file of the virtual machine is configured to write to another datastore.

Resolution

To resolve this issue, either do one of the following:

  • Consolidate the virtual machine snapshot. For steps and for more information, see Consolidate Snapshots.
  • Unmount the ISO file currently mounted to the virtual machine.
  • Reconfigure the VM to store the serial output file onto a different datastore. 
  • For VMs running on Hardware Version 10 or lower, unmount the floppy drive reference (This would be visible only through the Windows Desktop Client).
  • For the VDI VMs still referencing the older datastore and running on the snapshot delta file, we will need to ask the respective VDI vendor to change the hard disk of the VM to not run on a delta disk.
Note: If the ISO file (or floppy drive) is not in use by the virtual machine, select Client Device from the drop-down next to the CD/DVD drive. 

From the vSphere Web Client:

  1. Right click the virtual machine and select Edit Settings.
  2. Expand the CD/DVD drive, verify if an ISO file is mounted to virtual machine from another datastore.
  3. From the drop-down next to the CD/DVD drive, select Client Device.
  4. Click OK to save the changes to the virtual machine.

To address if the vmware.log file of the virtual machine is configured to write to another datastore

  1. Navigate to VM Options > Advanced > Edit Configuration:
  2. Search for the custom field: log.fileName.
  3. If the field exist, power off the virtual machine and remove or delete this field.
  4. Power on the virtual machine.

If the virtual machine still displays two datastores, try one of the below workarounds.

Workaround:

A) Compute vMotion the VM to another ESXi host, or re-register the VM:

  1. Power off the virtual machine.
  2. Remove the virtual machine from the inventory.
  3. Re-register the .vmx file. For steps and for more information, see Register an Existing Virtual Machine in the VMware Host Client

B) Storage vMotion the VM to the datastore that contains the VM's .vmx file.

C) On a vSAN cluster after Storage vMotion task, virtual machine shows registered in both cluster due ISO file still pointing on a source cluster:

  1. Make sure virtual machine objects are healthy and located on the destination cluster before clean up activity. 
  2. Review VM setting configuration and review virtual disk/ISO are pointing to destination cluster.
  3. If ISO file still mounted from source cluster.
    1. Power-off virtual machine
    2. Remove virtual machine from inventory in source cluster (Note: Do no remove virtual machine from disk) 
    3. Remove ISO file if not longer needed. 
    4. Power-on virtual machine on destination cluster. 

If the issue still persists, Contact Broadcom Support.