In VMware vSphere, the displayed free space of a shared VMFS6 datastore differs across ESXi hosts.
Specifically, when a file is deleted from the datastore via the Host Client on a specific host (e.g., ESXi A), the following behavior can be observed:
This discrepancy can be observed when checking the capacity via the ESXi Host Client, PowerCLI or API.
This is the expected behavior by design in vSphere.
When an ESXi host (e.g., ESXi A) performs file operations on a datastore, it updates the VMFS metadata and refreshes its own recognized free space.
Additionally, vCenter Server periodically(every 30 minutes by default) performs a datastore rescan via one representative host to update its inventory.
Therefore, any other ESXi host sharing the datastore (e.g., ESXi B) that did not perform the file operations, and was not selected as the representative host from vCenter Server, will not update its recognized free space.
As a result, the recognized capacity of the shared datastore on that host will remain outdated until a manual storage rescan is executed on it.
If you need to verify the latest capacity value of a shared datastore from an ESXi host, perform a manual datastore rescan.
This retrieves the latest metadata and synchronizes the ESXi host's recognized capacity to the current state.