To resolve this issue, remove the lock on the affected ESXi host, run the below commands or reboot the host:
- Connect to the ESXi host with an SSH session and root credentials.
- Break the existing LVM lock on the datastore:
vmkfstools –B vmfs_device:<partition number>
Note: You can use the parameter --breaklock instead of -B with the vmkfstools command.
For example:
vmkfstools -B /vmfs/devices/disks/naa.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx:<partition number>
- You will prompted similar to:
VMware ESX Question:
LVM lock on device /vmfs/devices/disks/naa.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx:<partition number> will be forcibly broken. Please consult vmkfstools or ESX documentation to understand the consequences of this.
Please ensure that multiple servers aren't accessing this device.
Continue to break lock?
0) Yes
1) No
Please choose a number [0-1]:
- Enter 0 to break the lock.
- Re-read and reload VMFS datastore metadata to memory with:
vmkfstools –V
- From the vSphere UI, refresh the Storage Datastores View under Configuration tab.