Manually Upgrading an Endpoint Operations Agent
search cancel

Manually Upgrading an Endpoint Operations Agent

book

Article ID: 337506

calendar_today

Updated On:

Products

VMware Aria Suite

Issue/Introduction

It's recommended to use the Admin UI method to upgrade Endpoint Operations agents as outlined in Upgrade the End Point Operations Management Agent.  However, if you need to upgrade agents manually, follow the steps outlined in this article.

Note: After upgrading from vRealize Operations Manager 8.1.1 or older versions to vRealize Operations Manager 8.3 or later, it is necessary to upgrade End Point Operations Management agents. If you are upgrading from vRealize Operations Manager 8.2 to 8.3 or later, you do not need to upgrade the End Point Operations Management agents.

You can use a REST API to upgrade Endpoint Operations agent. The API downloads the agent bundle upgrade from the vRealize Operations node, backs up the previous bundle in the event that a rollback is required if installation of the upgrade fails, and replaces the existing bundle with the upgrade. It then restarts the agent.

To perform multiple upgrades, see Upgrading Multiple Endpoint Operation Management Agents Simultaneously from a Script (2138748).
Before you can upgrade an Endpoint Operations agent:
  1. Verify that the following ordered list of prerequisites are met.
  2. Follow the upgrade steps described in the Solution section.
Prerequisites
  1. vRealize Operations must be installed.
  2. Use one of the following options to identify the token of the Endpoint Operations Management agent to upgrade.
    • Use this REST query to fetch a platform resource by IP. The agent token is stored in the agentID identifier property of the platform resource.

      https://<vR Ops IP\Host>/suite-api/api/resources?adapterKind=EP%20Ops%20Adapter&propertyName=ip&propertyValue=<Target Platform IP>

      Verify that the IP address matches the IP listed on the platform on which the agent resides.
    • Use this REST query to fetch a platform resource by FQDN:

      https://<vR Ops IP\Host>/suite-api/api/resources?adapterKind=EP%20Ops%20Adapter&propertyName=fqdn&propertyValue=<Target Platform FQDN>

      Verify that the FQDN matches the FQDN listed on the platform on which the agent resides.
       
  3. Download the agent upgrade bundle that is appropriate for the operating system and architecture on which the agent runs, from the Product Download page.
    1. In the Product Downloads tab, locate vRealize Operations under Standard, Advanced, and Enterprise.
    2. For the Standard, Advanced, or Enterprise level of vRealize Operations, click Go to Download.
    3. On the Download Product page, scroll to Agent Upgrade Bundle and click Read More.
    4. To download the agent upgrade bundle, click Download Now.
       
  4. Verify that there are no upgrade bundles from earlier upgrades in the upgrade directory. Upgrade bundles must be uploaded to every node in a cluster, including remote collectors. The upgrade directory must be named as:
    • On Unix/Linux operating systems: $VCOPS_BASE/user/plugins/inbound/agent_adapter/conf/plugins/agent_plugins/bundles/agent_version/
      Where, agent_version is the version of the upgrade. For example, 8.2.0.
    • On Windows operating systems:
      %VCOPS_BASE%/user/plugins/inbound/agent_adapter/conf/plugins/agent_plugins/bundles/agent_version/
      Where, agent_version is the version of the upgrade. For example, 8.2.0.
  5. Verify that the user who is running the upgrade process has these permissions:
    • AgentManager role
    • Access to all EP Ops Adapter objects
    • The All other Read, Write APIs, and Read access to APIs permissions under REST API
    • The Edit permission under Resource Management
For more information about access control, see Creating User Roles.

For more information about working with Endpoint Operations Management agents, see the vRealize Operations Information Center.


Resolution

Caution: Run the curl commands on the vRealize Operations Node.
  1. Run one of the following commands for the agent, replacing the parameter variables with the appropriate values.
    Note: Upgrading the agent might take several minutes, generally depending on network bandwidth. Metrics might be delayed or lost around the time of the agent upgrade.
    • Use this command to upgrade the agent bundle without providing the bundle file name. In this case, the upgrade process will try to resolve the bundle name automatically.

      curl --tlsv1 -k –u<vR Ops User>:<vR Ops Password>-H "X-vRealizeOps-API-use-unsupported: true" -H "Content-Type: application/json" -d '{"agentId":"<Target Agent Token>", "fileLocation":"<Agent Bundle Files Location>"}'https://<vROps IP/HOST>/suite-api/internal/agent/upgrade

      If you follow the example provided in step 3 of the Prerequisites section, the Agent Bundle Files Location is bundles/8.2.0.
    • Use this command to upgrade the agent and specify the bundle file name:

      curl --tlsv1 -k –u<vR Ops User>:<vR Ops Password>-H "X-vRealizeOps-API-use-unsupported: true" -H "Content-Type: application/json" -d '{"agentId":"<Target Agent Token>", "fileLocation":"<Agent Bundle Files Location>", "agentBundleFile":"<Agent Bundle Files Name>"}'https://<vROps IP/HOST>/suite-api/internal/agent/upgrade

      If you follow the example provided in step 3 of the Prerequisites section, the Agent Bundle Files Location is bundles/8.2.0.

      Note: If the folder location bundles/<version> does not exist, then create the folders under $VCOPS_BASE/user/plugins/inbound/agent_adapter/conf/plugins/agent_plugins/.
       
  2. Use this URL to check the agent_upgrade_status of the upgraded agent.

    After you started the upgrade process, the API call is complete but the process continues to run. This URL enables you to check the status during and after the upgrade process.

    https://<vR Ops IP/host>/suite-api/api/adapterkinds/EP%20Ops%20Adapter/resourcekinds/EP%20Ops%20Agent/resources?identifiers[agentID]=<target agent token>
     
  3. On the URL page, check the following parameters to verify that the upgrade completed successfully:
    • Verify that agent_upgrade_status is COMPLETED
    • Verify that the version of agent_upgrade_target_bundle is the upgrade version
    • Verify that the agent_upgrade_timestamp matches the upgrade time
       
  4. Select the EP Ops Agent resource in the vRealize Operations user interface inventory, and click the Show Detail icon.
  5. In the Analysis tab > EP Ops Agent Resources pane, verify that the agent version number reflects the newer version number.

    For troubleshooting purpose, you can view additional data in the following logs:
    • vRealize Operations: <VCOPS_BASE>/user/log/aim-agent-bundle-upgrade.log
    • Endpoint Operations Management agent: <agent home>/log/agent.log

      Note: The agent upgrade log is also accessible from the vRealize Operations user interface.

Additional Information

Troubleshooting

This section contains information to troubleshoot upgrade issues.

Note: You can also use the aim-agent-bundle-upgrade.log in the vRealize Operations collector machines for further troubleshooting. To view the file, go to Administration > Support > Logs, and select the log file under OTHER.

Issue 1

Agent bundle upgrade status is FAILED_TIMEOUT.

Resolution 1

  1. Verify that the agent is up and running.
  2. Check for network latency between the agent and vRealize Operations nodes.

Issue 2

Agent bundle upgrade status is FAILED.

Resolution 2

Verify that the agent has rolled back to the previous version and continues to use the previous bundle.
 

Issue 3

User Authentication for Running the Upgrade Commands

Resolution 3

In the event that your user name or password includes any non-alpha numeric characters that might be misread by the shell, escape the characters.
For example, change u$er to u\$er.



For translated versions of this article, see:
Below are examples taken from postman: