Reuse VSAN Claimed Disks as VMFS Datastore

During a test I used an old disk that has been previously used by Virtual SAN. The disk did not appear during the datastore creation process. I miss a flash drive here:

datastore-creationThe problem is that the disk has not been cleared from it's VSAN configuration. It has still valid VSAN partitions, so the ESXi "claims it for VSAN" what makes it impossible to create a VMFS filesystem.

To verify, connect to the ESXi with SSH and run esxcli vsan storage list:

[root@esx1:~] esxcli vsan storage list

 Device: t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________
 Display Name: t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________
 Is SSD: true
 VSAN UUID: 523e54f5-9014-8421-d353-4d7a78d777f3
 VSAN Disk Group UUID: 523e54f5-9014-8421-d353-4d7a78d777f3
 VSAN Disk Group Name: t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________
 Used by this host: true
 In CMMDS: false
 Checksum: 13422576951459625586
 Checksum OK: true
 Emulated DIX/DIF Enabled: false

You can also see a VSAN Partition with partedUtil getptbl /dev/disks/[disk]:

[root@esx1:~] partedUtil getptbl /dev/disks/t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________
7783 255 63 125045424
1 2048 6143 381CFCCC728811E092EE000C2911D0B2 vsan 0
2 6144 125045390 AA31E02A400F11DB9590000C2911D1B8 vmfs 0

To remove the disk from VSAN, use esxcli vsan storage remove [-d|-s] [Name] with an appropriate parameter:
-d for Disks
-s for Flash Drives

[root@esx1:~] esxcli vsan storage remove -s t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________

Verify Partitions (gone):

[root@esx1:~] partedUtil getptbl /dev/disks/t10.ATA_____SanDisk_SDSSDP064G______________________132444400028________
7783 255 63 125045424

You can now create a VMFS Datastore on the disk:


Leave a Comment

NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This site uses Akismet to reduce spam. Learn how your comment data is processed.