This Blog is to share our knowledge and expertise on Linux System Administration and VMware Administration

Tuesday, June 14, 2016

VMFS volume on the VMware ESX/ESXi host is locked due to an I/O error.

If naa.60060160b3c018009bd1e02f725fdd11:1 represents one of the partitions used in a VMFS volume, you see this message when the VMFS volume is inaccessible:
volume on device naa.60060160b3c018009bd1e02f725fdd11:1 locked, possibly because remote host 10.17.211.73 encountered an error during a volume operation and couldn’t recover.

If this issue occurs, the VMFS volume (and the virtual machines residing on the affected volume) are unavailable to the ESX/ESXi host.
In the /var/log/vmkernel.log file, you may see similar message indicating the same issue:
WARNING: LVM: 13127: The volume on the device naa.6000eb3b3638efa50000000000000258:1 locked, possibly because some remote host encountered an error during a volume operation and could not recover.
LVM: 11786: Failed to open device naa.6000eb3b3638efa50000000000000258:1 : Lock was not free

To resolve this issue, remove the lock on the indicated volume.
  1. Log in to the ESX/ESXi console.
    • For information on how to log in to ESXi 4.1 and 5.x hosts
    • For information on how to log in to ESXi 4.0, see 
  2. Log in to the terminal of the VMware ESX or ESXi host and run these commands:

    To break the lock:
    1. Break the existing LVM lock on the datastore by running this command:
      # vmkfstools –B vmfs deviceNote: You can also use the parameter --breaklock instead of -B with the vmkfstools command.

      From the preceding error message, this command is used:

      # vmkfstools -B /vmfs/devices/disks/naa.60060160b3c018009bd1e02f725fdd11:1You see output similar to:

      VMware ESX Question:

      LVM lock on device /vmfs/devices/disks/naa.60060160b3c018009bd1e02f725fdd11:1 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]:
    2. Enter 0 to break the lock.
    3. Re-read and reload VMFS datastore metadata to memory by running this command:

      # vmkfstools –V
    4. From the vSphere UI, refresh the Storage Datastores View under Configuration tab.
Note: This issue can also be resolved by restarting all the hosts in the cluster.

No comments:

Post a Comment