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
- From the Workflows tab go edit the workflow in SET – vRB – Force vRB Cost Collection and right click to edit the workflow
- 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.
- The following attributes will need to be edited:
- baseUrl – This is the vra appliance URL – https://<vra-fqdn>
- vraUsername – This is the account that should have Business Management Administrator role assigned.
- vraPassword – Password for the username assigned
- tenant – Tenant name created typically the default is vsphere.local
- vrbbaseUrl – This is the vRB Std appliance URL – https://<vrb-fqdn>
- 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.
- Click Save and Close
- 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
- Next under the SET – VRB – Configuration folder start the “Create Event Subscription vRB Cost Collection” workflow.
- Make sure to fill in the two required parameters for vRA host and Event topic.
- 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.
- For the Event Topic select “Blueprint configuration”
- Last step is to click Submit.
- Once the workflow has ran successfully lets make sure the Event Subscription has been imported into vRA.
- 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”
- 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.
- Create a simple machine blueprint in Design – Blueprints.
- 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!