Start by determining the device backing up the locker partition

commands: 
ls -ltrh / | grep store
 vmkfstools -P /vmfs/volumes/5cdce747-375af1f6-b185-0050569674de
Output: 
[root@is-dhcp41-13:~] ls -ltrh / | grep store
lrwxrwxrwx    1 root     root           6 May 13 23:03 locker -> /store
lrwxrwxrwx    1 root     root          49 May 16 04:29 store -> /vmfs/volumes/5cdce747-375af1f6-b185-0050569674de


[root@is-dhcp41-13:~] vmkfstools -P /vmfs/volumes/5cdce747-375af1f6-b185-0050569674de
vfat-0.04 (Raw Major Version: 0) file system spanning 1 partitions.
File system label (if any):
Mode: private
Capacity 299712512 (36586 file blocks * 8192), 299712512 (36586 blocks) avail, max supported file size 0
Disk Block Size: 512/0/0
UUID: 5cdce747-375af1f6-b185-0050569674de
Partitions spanned (on "disks"):
        mpx.vmhba0:C0:T0:L0:8
Is Native Snapshot Capable: NO
[root@is-dhcp41-13:~]

Make a note of the device under the line Partitions spanned (on “disks”):

Note: The :8 on the above result signifives that this is partition 8 of the disk
Note: On a default install, the locker/tools iso are always stored to partition 8 of the installed disk/drive.

Format the partition with fat filesystem using the below command: Ensure you DO NOT MISS the partition number

vmkfstools -C vfat /dev/disks/mpx.vmhba0:C0:T0:L0:8
eg:
[root@is-dhcp41-13:~] vmkfstools -C vfat /dev/disks/mpx.vmhba0:C0:T0:L0:8
create fs deviceName:'/dev/disks/mpx.vmhba0:C0:T0:L0:8', fsShortName:'vfat', fsName:'(null)'
deviceFullPath:/dev/disks/mpx.vmhba0:C0:T0:L0:8 deviceFile:mpx.vmhba0:C0:T0:L0:8
Checking if remote hosts are using this device as a valid file system. This may take a few seconds...
Creating vfat file system on "mpx.vmhba0:C0:T0:L0:8" with blockSize 1048576 and volume label "none".
Successfully created new volume: 5cdcf45e-68f98eec-adb0-0050569674de


Note: If the format fails with the resource in use errors, the host will need a reboot.

re-create the symlink for store:

ln -snf /vmfs/volumes/5cdcf45e-68f98eec-adb0-0050569674de /store

ln -snf /vmfs/volumes/5cdcf45e-68f98eec-adb0-0050569674de /locker

Copy contents of the store partition from a working host, same Esxi build

One Reply to “Fixing the broken/corrupt Locker Partition on Esxi”

  1. Similar issue happened to one of my clients, when we tried to update patches from command line, we get following error

    Error getting data for filesystem on ‘/vmfs/volumes/575f104d-62bb26d7-06f6-000af790c9ec’: Cannot open volume: /vmfs/volumes/575f104d-62bb26d7-06f6-000af790c9ec, skipping.
    cause = Errors:
    Error getting data for filesystem on ‘/vmfs/volumes/575f104d-62bb26d7-06f6-000af790c9ec’: Cannot open volume: /vmfs/volumes/575f104d-62bb26d7-06f6-000af790c9ec, skipping.
    Please refer to the log file for more details.

    when we check in virtual flash resources on vsphere-webclient none found.
    df -h also will not work to identify linked naa.xxx, this store was orphaned
    ls -l shows following line
    lrwxr-xr-x 1 root root 35 Dec 7 12:30 vffs-32a79800-dc89-1b3c-c3c8-f69647ef9dd8 -> 51360b11-459861b5-2737-000af79
    we finally solved this issue by unmounting the problem volume using following command
    esxcli storage filesystem unmount -p /vmfs/volumes/vffs-32a79800-dc89-1b3c-c3c8-f69647ef9dd8

    hope this helps

Leave a Reply

Your email address will not be published. Required fields are marked *