Hey there! In this post we shall see how a Disk Group is created using the disks attached to the ESXi hosts. Before diving into the creation process, lets gain some understanding of the Role of Flash Disks, vsanDatastore and the Objects associated with a VM.
Flash Device Role
Each Flash Disk that is part of the VSAN cluster will either be used for Read Cache or Write Buffer.
Flash device used as a Read Cache
- Keeps a record of the frequently accessed disk blocks, enabling faster access.
- Reduces I/O read latency and any cache misses are retrieved directly from the HDD.
- 70% of the flash is used for Read Cache.
Flash device used for Write Buffer
- Acts as a non-volatile write buffer, the write operations are later moved to the HDD’s
- Reduces latency for write operations
- 30% of the flash is used for the Write Buffer
Note: In case of a All-Flash VSAN cluster, the flash devices configured for cache tier are used only for Write Buffer as the Read Cache provided by the capacity tier flash devices would be sufficient. Writes are performed at the cache layer and de-staged to the capacity layer when needed.
A vsanDatastore is created by using all disk groups from multiple hosts in the cluster. Hosts in the cluster see the storage as a single pool (one datastore). Irrespective of how the data is distributed by VSAN across the physical devices, any VM in the cluster can access the data. A VM can have data blocks on any of the hosts in the clusters and can be running on a different hosts, this is the reason a 10Gig ethernet is recommended for VSAN enabled cluster.
The Datastore capacity is determined by the magnetic disks capacity alone and flash disk capacity does not contribute to the vsanDatastore capacity. VMFS formatting of the magnetic disks adds some metadata overhead. This overhead is subtracted from the overall HDD capacity.
vsanDatastore grows dynamically i.e if when a storage device is added to host or a new host with storage is added to the VSAN cluster, this is a scale out solution. VMware recommends 1:10 ratio of SSD to HDD. SSD must be at least 10% of the overall storage capacity.
Each VM deployed on a VSAN datastore may have 4 different kinds of storage objects with it.
- vmdk Objects – virtual machine disk files
- Delta Objects – vm disks created for snapshots; each delta disk is an object
- Swap Objects – swap disks created when VM is powered on
- Namespace Object – Everything else excluding the vmdk, delta and swap files of a VM are residing in the namespace directory of the VSAN. These include vmx, vmdk descriptor files, log files etc..
The Capacity, Performance and Availability of a VM can be defined in the form of a storage policy. Several storage policies can be created based on the requirements and can be applied during the creation/editing of a vm. Each vmdk on the vsanDatastore has a storage policy attached to it.
Now its time for us to get going with the lab. To create a Disk Group, from the Virtual SAN section of the Cluster settings, click on the Disk Management, on the right side pane, use the create Disk Group icon.
On the next screen, select the Flash and HDDs from each host that you want to make a part of this disk group and click OK.
Once done, you should see the DiskGroups created with UUID’s.
A datastore is automatically created after the disk group creation and is accessible to all hosts in the cluster.
Hope this was informative. Thanks!