Blog

Force Removal of Folders on VSAN

When folder deletion fails in the UI, you can fall back to the CLI and force deletion.

SSH into your ESXi instance and use the osfs-rmdir utility.

This type of error can also occur due to connectivity issues as per this thread: https://communities.vmware.com/thread/489842.

6caefd94-4a0f-45a5-b299-01e32b7121f9.png

List directory

1
2
3
[[email protected]:/vmfs/volumes/vsan:5218ef34de66cc64-1d0ef14adba2e0e5] ls -la
ls: ./648f3f59-5df4-e11f-00d0-a02bb83182fc: No such device or address
ls: ./fd8f3f59-ade1-802d-c5a3-a02bb83182fc: No such device or address
list-directory.png

Force delete (cli)

1
/usr/lib/vmware/osfs/bin/osfs-rmdir 648f3f59-5df4-e11f-00d0-a02bb83182fc -f
force-delete--cli-.png