Genz
Rajesh Radhakrishnan
21/02/2018 Published 2 weeks ago
Share
https://vmarena.com/wp-content/uploads/2024/11/cloud-services-isometric-composition-with-flat-silhouette-pictograms-big-cloud-storage-with-people-vector-illustration_1284-30499.jpg

VM Storage Policies- vSphere 6.5

 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.

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.
                                                                                                   Configure Storage IO control options
Here we need to define the tag category to include object types Datastore and Datastore Cluster.
                                                                                                          Add objects to Tag category
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
                                                                                                                   Create a new Tag
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

Select to tag a datastore
Now, we select our tag we created.
Select the tag to assign to the datastore

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.
Create a New VM Storage Policy
In Step 1, we add a name and description to our new VM storage policy.

Choose Name and Description for 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.

                                   Select Host based services datastore specific rules
Under the Host based services, we can configure options for Encryption or Storage I/O control.

                                                       Select Encryption options
I configured a custom Storage I/O Control using the default values provided.

                                    Configure Storage IO control options
***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.

                                                 Error if no storage related tags
However, once we have the tag category and tags in place, we can add the tag we created earlier.
Adding our storage tag to the policy
Now we have defined our tag category and Usage option along with defined tags.

                                      After choosing our tag category and storage tags
Since we tagged our storage earlier with the custom storage tag, we see it listed in the Compatible storage.

                                                         Storage compatibility is shown
Finally, we review the custom VM Storage Policy we are about to create.

                                           Finish creating the new VM storage policy

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.