VM Storage Policy APIs aka Storage Profile APIs will be available in vSphere 5.5

September 13, 2013

How To

VM Storage Policy APIs aka Storage Profile APIs will be available in vSphere 5.5

A frequently requested feature from customers and partners have been around the Storage Profile APIs and with the upcoming vSphere 5.5 release, it will now be possible to automate the management and consumption of Storage Profiles. In vSphere 5.5, Storage Profiles has been renamed to VM Storage Policy and they have been enhanced from the previous version of Storage Profile. VM Storage Policy introduces new concept of a rule set also known as a sub-profile or sub-policy from an API perspective.
A VM Storage Policy can contain multiple rule sets which describes a requirement for a virtual machine storage resource. Each rule can either be an underlying storage capability or a user defined vSphere Tag.

One important thing to note about the VM Storage Policy API (SOAP API), is that it is exposed as a separate API endpoint (similar to how the SMS API is exposed) on vCenter Server and it will not be accessible through the normal vSphere API. To consume this API, you will need to connect to the PBM (Policy Based Management) Server which requires an authenticated vCenter Server session.

Here is the high level workflow for connecting to the PBM Server:

  1. Login to vCenter Server
  2. Extract the session cookie
  3. Add vCenter Server session cookie & connect to PBM Server

Once connected to the PBM Server, you will have access to PBM ServiceInstance with following three managed objects:

  • ProfileProfileManager (not a typo, repeat of Profile for some reason)


ComplianceManager vm-storage-policy-api-2.png
As mentioned earlier, a VM Storage Policy can be made up of several rule sets and each rule set contains a property rule. Here is the specification for what the VM Storage Policy looks like from an API perspective:
For managing and creating VM Storage Policies, you will need use the new VM Storage Policy API and for consuming and assigning VM Storage Policies to a virtual machine, you will need to use the vSphere API. When provisioning or cloning a virtual machine, there is a new profile property that denotes the MoRef ID for a particular VM Storage Policy.

As part of the VM Storage Policy API, there will be a Java SDK that includes a programming guide that goes over the VM Storage Policy API in greater detail as well as several sample programs exercising the various API methods. Since the VM Storage Policy API is a SOAP API similar to the vSphere API, the WSDL will also be available if you wish to generate your own language binding to the API.

Here is a screenshot of the available sample programs leveraging the new VM Storage Policy API:
Here is an example of one of the sample programs which lists all the VM Storage Policies for a given vCenter Server:

run.bat ListProfiles –vcurl administrator –password vmware –ignorecert

In the screenshot, you will see four VM Storage Policy being shown, one which I had created earlier and there others which are VM Storage Policies created by VSAN. You will notice that you will need three pieces of information when connecting: vCenter Server endpoint, SSO Server endpoint and PBM Server endpoint. You can find more details by referring to the VM Storage Policy Programming Guide.


, ,


Subscribe to our RSS feed and social profiles to receive updates.

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: