Unable to claim a disk for vSAN when adding to an existing disk group or creating a new disk group as disk is ineligbile.
vSAN 8.X
vSAN 9.X
There is currently an existing partition on the disk, which can't be used for vSAN.
When querying the disk with this command, an already existing partition is on the disk already. Note: Please put the naa ID of the ineligible device into the below command:
disk="/vmfs/devices/disks/naa.################################"; offset="128 2048"; echo $disk; partedUtil getptbl $disk; { for i in `echo $offset`; do echo "Checking offset found at $i:"; hexdump -n4 -s $((0x100000+(512*$i))) $disk; hexdump -n4 -s $((0x1300000+(512*$i))) $disk; hexdump -C -n 128 -s $((0x130001d + (512*$i))) $disk; done; } | grep -B 1 -A 5 d00d; echo "---------------------"
Example output from the above command:
gpt466945 255 63 75014765281 2048 20971519 EBD0A0A2B9E5443387C068B6B72699C7 linuxNative 02 62916608 83886079 EBD0A0A2B9E5443387C068B6B72699C7 linuxNative 03 125831168 209715199 EBD0A0A2B9E5443387C068B6B72699C7 linuxNative 04 293603328 7501475839 EBD0A0A2B9E5443387C068B6B72699C7 linuxNative 0---------------------
Alternatively, this can be checked in the /dev/disks folder on an SSH session on the ESXi host. If the naa device contains a number after the colon, then there is already a partition on the device.
See example below of device with no partition.
lrwxrwxrwx 1 root root 36 Jul 27 16:40 vml.02000##################030 -> naa.##################011
Below is device with partition.
lrwxrwxrwx 1 root root 36 Jul 27 16:40 vml.02000##################030 -> naa.##################011lrwxrwxrwx 1 root root 38 Jul 27 16:40 vml.02000##################030:1 -> naa.##################011:1
If the partition is not needed and doesn't contain important data, then proceed with disk deletion either by command line or through the GUI. It's recommended to put the host into maintenance mode when carrying out deletion.
Warning: This operation cannot be undone once initiated, ensure that the data on this disk is not required before proceeding.
partedUtil delete "/vmfs/devices/disks/naa.xxxxxxxxxxxxxxxxxxxxxxxx" 1
This can also be achieved through the vSphere interface.