Datastore corruption issue resolution
From Notes_Wiki
Home > VMWare platform > VMWare vSphere or ESXi > Datastore corruption issue resolution
The below is not applicable for vSAN. Use this only for normal VMFS datastores.
It is possible to have datastore corruption especially when underlying storage becomes inaccessible to ESXi host temporarily while there are VMs running from given datastore. When such incidents happen we can see some log lines related to datastore corruption in '/var/log/vmkernel' file.
Once datastore is found to be corrupted, the best course of action is:
- Shutdown all VMs running from datastore. If graceful shutdown is not working then poweroff the VMs.
- If a VM is too critical to be powered off then we can attempt storage migration of this VM to another datastore.
- Either way all VMs on datastore should either be powered off or migrated to another datastore before proceeding further.
- List datastores available to host via:
- localcli storage vmfs extent list
- The name of datastore, UUID of datastore or device name of datastore should be part of the vmkernel error log message.
- Check partition table, LVM and VMFS on the affected device using:
- voma -m ptbl -f check -d /vmfs/devices/disks/naa.<device-id>
- voma -m lvm -f check -d <full-device-path>
- voma -m vmfs -f check -d <full-device-path>
- voma -m vmfs -f fix -d <full-device-path>
- If the above does not results into successful fix of datastore then we need to plan restoring the affected VMs from backup.
Refer:
Home > VMWare platform > VMWare vSphere or ESXi > Datastore corruption issue resolution