Using VMware VM Storage Policies
VMware Virtual Machine Storage Policies fall under the realm of Storage Policy Based Management that assists with virtual machine provisioning. When defined, Storage Based Policies define which type(s) of storage are presented for the virtual machine and how the virtual machine is placed within storage and also data services. There are certain builtin storage policies that are provided as default selections. However, built-in VASA providers can present storage based on vendor capabilities and functionality and also we can create and assign custom storage policies as well. With custom VM storage policies we can “tag” storage with certain tag metadata so that VMs are placed accordingly to the levels of service our application requires based on tags we define. Let’s take a look at creating storage polices, using VMware VM storage policies, and how we can assign these policies to virtual machines we provision.
Create Tags Category and Tags to Assign to Storage
Our first step to using storage policies if we want to tag our datastores with custom metadata that we define is to create tag category and tags.ย First we select to create a newย tag category.ย Click the Categories button and the + sign.
Here we need to define the tag category to include object typesย Datastore andย Datastore Cluster.
Now that we have our tag category defined, we can create a newย tag.ย I am simply calling the tagย iSCSI+datastore for the lab.
Now that we have our tag category and tags in place, we can tag our Datastore(s) with specific tags that we want to use to define our policy.
Tag the VMware vSphere Datastore(s)
Now we will assign the new tag to the datastore of our choosing.ย Right click your datastore and select theย Assign Tag option from theย Tags & Custom Attributes menu option.
Now, we select our tag we created.
Creating VMware Virtual Machine Storage Policies
The process to create VMware virtual machine storage policies is fairly straightforward.ย In this walkthrough, I will be using the HTML5 web client to create the policy.ย The first thing we do is navigate toย Menu >> Policies and Profiles in the web client, or theย Home buttonย >>ย Polices and Profiles.
In Step 1, we add a name and description to our new VM storage policy.
Next we select eitherย Host based services orย Datastore specific rules, or both.ย Here I have both selected.
- Host based services – Create rules for data services provided by hosts including encryption and I/O control
- Datastore specific rules – Rules for different storage types, these can come from VASA or custom tags.ย ย Note about VASA –ย The list of storage capabilities that a storage array can deliver is defined and published by the storage array’s storage provider service. Using vStorage APIs for Storage Awareness VASA the storage prividers inform vCenter Server about the specific storage device characteristics and capabilities. These are vendor specific.
Under the Host based services, we can configure options for Encryption or Storage I/O control.
I configured a custom Storage I/O Control using the default values provided.
Noteย If you don’t have any storage related tag categories defined, you will see the error on theย Tag based placementย screen showingย No storage related tag categories available.
However, once we have the tag category and tags in place, we can add the tag we created earlier.
Now we have defined our tag category and Usage option along with defined tags.
Since we tagged our storage earlier with the custom storage tag, we see it listed in theย Compatible storage.
Finally, we review the custom VM Storage Policy we are about to create.
Using VMware VM Storage Policies
As we can see below, when we get to theย Select storage screen, we can select the custom VM Storage Policy which results in the compatible datastore.
Thoughts
Using VMware VM Storage Policies are a powerful tool that administrators can use to allow the software to drive where VMs are placed in the infrastructure.ย With the power of today’s storage arrays often delivering tiered storage all in a single device, using storage policies allows a much more powerful way of defining the desired performance and provisioning of new virtual machines.ย VASA provided capabilities from manufacturers or custom tags can provide directives for delivering expected performance by defining this at the virtual machine level.