VMware vRealize Automation – vRA7 and vRB7 – Automate Cost Calculations

Caution: Articles written for technical not grammatical accuracy, If poor grammar offends you proceed with caution ;-)

There’s a known issue when you have both vRealize Automation and vRealize Business 7.x integrated when you have a newly created blueprint to deploy it may fail with an error “Cannot calculate cost. Contact your system administrator to review the vRA appliance logs.”  Typically this means vRB hasn’t run a cost calculation on the new blueprint to determine the cost of the blueprint.  You either have to wait up to 12 hours for the cost collection to run or you can manually force a collection by triggering a vRA Data Collection and a Cost Calculation as shown below.

To help alleviate the extra steps to this workaround I have created a vRealize Orchestrator package that can be used to completely automate this during blueprint creations.  Here are the steps to make this happen.

Grab the vRO package here:



Import the downloaded package into vRO from the Design dropdown as shown below

Once the package is installed it’s now time to configure the collection workflow and add the Event Subscription to trigger from new blueprint.


First lets configure the “Force vRB Cost Collection” workflow

  1. From the Workflows tab go edit the workflow in SET – vRB – Force vRB Cost Collection and right click to edit the workflow
  2. In the General tab all we have to do is edit the attributes to make sure we connect to vRA for authentication and vRB to force the collections.
  3. The following attributes will need to be edited:
    1. baseUrl – This is the vra appliance URL – https://<vra-fqdn>
    2. vraUsername – This is the account that should have Business Management Administrator role assigned.
    3. vraPassword – Password for the username assigned
    4. tenant – Tenant name created typically the default is vsphere.local
    5. vrbbaseUrl – This is the vRB Std appliance URL – https://<vrb-fqdn>
    6. Optional – delay – This is the delay in seconds between running the vRA data collection and Cost Collection.  60 seconds should work, but if not just increase this value.
  4. Click Save and Close
  5. Optionally you can test to make sure the workflow works.  If you run into an error regarding a certificate error with the vRB appliance the quick workaround is to import the certificate in the vRO Configuration tool.  More information can be found here on importing – Import a Self-Signed Certificate to the Orchestrator Trust Store
  6. Next under the SET – VRB – Configuration folder start the “Create Event Subscription vRB Cost Collection” workflow.
  7. Make sure to fill in the two required parameters for vRA host and Event topic.
    1. Make sure to select the correct vRA host that correlates to the correct vRA tenant.  The example below shows selecting the SETI tenant to create the required Event Subscription.
    2. For the Event Topic select “Blueprint configuration”
    3. Last step is to click Submit.
    4. Once the workflow has ran successfully lets make sure the Event Subscription has been imported into vRA.
    5. If you haven’t already log into vRA and go to the Administration Tab – Events – Subscriptions.  You should see a subscription in the list called “Force vRB Cost Collection”
    6. If the subscription shows published you’re ready to test!

Test the Workflow

Let’s make sure the event gets triggered every time a new blueprint is created.

  1. Create a simple machine blueprint in Design – Blueprints.
  2. Once you save the blueprint within a couple minutes you should see a rotating green arrow in the top right corner of the Business Management tab.

Now while that’s running you can continue to publish and add the new blueprint to the catalog.  By then users will be able to provision the new blueprint without receiving the pricing errors you may encounter without doing the manual process.

Now wasn’t that easy!

Leave a Reply