Query the Status of Appliance Patching / update Operation
search cancel

Query the Status of Appliance Patching / update Operation

book

Article ID: 372619

calendar_today

Updated On:

Products

VMware SDDC Manager

Issue/Introduction

An error "A vCenter upgrade is already running" can be seen during vCenter reduced downtime upgrade is in progress and the vcenter reduced downtime upgrade operation will be failed.

Environment

VCF 5.2.1

Cause

There can be a previous appliance patching/update operation in progress because of which a precheck error is thrown,
 in such cases please query the status of appliance patching / update with the help of steps provided in this KB

Resolution

  1. SSH to sddc manager.
  2. Create vcenter cis session.

    curl -X POST -H "Authorization: Basic $base64_encoded_sso_admin_credentials" -H "Content-Type: application/json" https://vcenter.example.com/api/session

  3. Invoke the update API using the session ID generated in step 2.
    1. curl -k -H "Content-Type: application/json" -H "vmware-api-session-id: $session" -X GET https://vcenter.example.com/rest/appliance/update
    2. Note state from the response ["value"]["state"] 
    3. If the response ["value"]["state"] is STAGE_IN_PROGRESS or INSTALL_IN_PROGRESS or ROLLBACK_IN_PROGRESS then monitor the status by repeating step 3.a , until response["value"]["state"] reaches UP_TO_DATE or the response ["value"]["task"]["status"] is FAILED and retry the upgrade.
      Note: The response[value]["task"]["progress"] will be updated with progress and related messages.