Upgrade VM hardware version for BOSH VM managed in vSphere
search cancel

Upgrade VM hardware version for BOSH VM managed in vSphere

book

Article ID: 293689

calendar_today

Updated On:

Products

Operations Manager

Issue/Introduction

In a vSphere environment, the default VM hardware version for the VM deployed by BOSH is 9. This article describes how to force the BOSH Director to upgrade the VM hardware version to the highest level compatible with the ESX host.

There is a flag called "upgrade_hw_version" that is set to false by default in BOSH director. View the resource below for additional information: 
https://bosh.io/jobs/vsphere_cpi?source=github.com/cloudfoundry/bosh-vsphere-cpi-release&version=54.1.0#p%3dvcenter.upgrade_hw_version

Environment

Product Version: 2.7

Resolution

1. Access the Ops Manager API and retrieve your UAA Access Token Value: https://docs.pivotal.io/ops-manager/2-10/install/ops-man-api.html

2. Use the following API command to globally upgrade the VM hardware version:
curl -v -k "https://OPSMAN_FQDN/api/v0/staged/director/iaas_configurations/DIRECTOR_ID" \
-X PUT \
-H "Authorization: Bearer $UAA_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"iaas_configuration":{"additional_cloud_properties":{"upgrade_hw_version":true}}}'
  • OPSMAN_FQDN is the Ops Manager name
  • DIRECTOR_ID is the ID shown when browsing the BOSH director tile in Ops Manager GUI. An example in the following URL:
    • https://opsmgr-14.slot-59.pez.vmware.com/infrastructure/iaas_configurations/5fc5925f5387047e706f/edit 
    • DIRECTOR_ID is 5fc5925f5387047e706f
  • UAA_ACCESS_TOKEN is your UAA Access Token Value from step 1

3. Select "Recreate All VMs" in the BOSH Director tile and Apply Changes.