All Products
Search
Document Center

Elastic Compute Service:Upgrade or disable upgrades for Cloud Assistant Agent

Last Updated:Sep 18, 2023

Cloud Assistant Agent is an agent that runs Cloud Assistant commands on Elastic Compute Service (ECS) instances. This topic describes how to upgrade and disable upgrades for Cloud Assistant Agent.

Prerequisites

Cloud Assistant Agent is installed on an ECS instance. For information about how to install Cloud Assistant Agent, see Install Cloud Assistant Agent.

Automatic upgrades

Cloud Assistant Agent runs the aliyun_assist_update upgrade process every 30 minutes. The process resides in one of the following paths:

  • Windows instances: C:\ProgramData\aliyun\assist\{version}\aliyun_assist_update.exe

  • Linux instances: /usr/local/share/aliyun-assist/{version}/aliyun_assist_update

Note

{version} indicates the version number of Cloud Assistant Agent.

Manual upgrades

If automatic upgrades do not take effect, you can run common commands to manually upgrade Cloud Assistant Agent. For information about how to use common commands, see View and run common Cloud Assistant commands.

  • To upgrade Cloud Assistant Agent on a Linux instance, run the ACS-ECS-UpdateAliyunAssist-linux.sh common command.

  • To upgrade Cloud Assistant Agent on a Windows instance, run the ACS-ECS-UpdateAliyunAssist-windows.ps1 common command.

You can also download the latest installation package to upgrade Cloud Assistant Agent. For example, to download the latest installation package in the RPM format and upgrade Cloud Assistant Agent, run the following command. For information about the commands that are used for other installation packages, see Install Cloud Assistant Agent.

wget "https://aliyun-client-assist.oss-accelerate.aliyuncs.com/linux/aliyun_assist_latest.rpm" && rpm -ivh --force aliyun_assist_latest.rpm

Disable upgrades

Disable the automatic upgrade program to disable upgrades for Cloud Assistant Agent

You can disable the automatic upgrade program aliyun_assist_update to disable upgrades for Cloud Assistant Agent.

  • If the instance on which Cloud Assistant Agent is installed runs a Windows Server operating system, run the following command in PowerShell:

    Rename-Item -Path 'C:\ProgramData\aliyun\assist\{version}\aliyun_assist_update.exe'-NewName 'C:\ProgramData\aliyun\assist\{version}\aliyun_assist_update.exe.bk'
  • If the instance on which Cloud Assistant Agent is installed runs a Linux operating system, run the following command:

    chmod a-x aliyun_assist_update
Note

{version} indicates the version number of Cloud Assistant Agent.

Use a configuration file to disable upgrades for Cloud Assistant Agent

For Cloud Assistant Agent 2.2.1.140 or later on Linux instances and Cloud Assistant Agent 2.1.1.140 or later on Windows instances, you can disable upgrades by creating a configuration file in a specified directory.

  • Disable Cloud Assistant Agent from checking for upgrades on startup

    To disable a specific version of Cloud Assistant Agent on an instance from checking for upgrades on startup, find the installation directory of the Cloud Assistant Agent version and create the disable_bootstrap_update file in the config directory. To disable all versions of Cloud Assistant Agent on an instance from checking for upgrades on startup, find the general installation directory of all Cloud Assistant Agent versions and create the disable_bootstrap_update file in the config directory. You do not need to write data to the disable_bootstrap_update file.

    • If the instance on which Cloud Assistant Agent is installed runs a Windows Server operating system, run the following command in PowerShell:

      # For example, run the following command to disable a specific version of Cloud Assistant Agent from checking for upgrades on startup:
      New-Item -Path C:\ProgramData\aliyun\assist\{version}\config\disable_bootstrap_update
      For example, run the following command to disable all versions of Cloud Assistant Agent from checking for upgrades on startup:
      New-Item -Path C:\ProgramData\aliyun\assist\config\disable_bootstrap_update
    • If the instance on which Cloud Assistant Agent is installed runs a Linux operating system, run the following command:

      # For example, run the following command to disable a specific version of Cloud Assistant Agent from checking for upgrades on startup:
      touch /usr/local/share/aliyun-assist/{version}/config/disable_bootstrap_update
      For example, run the following command to disable all versions of Cloud Assistant Agent from checking for upgrades on startup:
      touch /usr/local/share/aliyun-assist/config/disable_bootstrap_update
    Note

    {version} indicates the version number of Cloud Assistant Agent.

  • Disable Cloud Assistant Agent from checking for updates

    To disable a specific version of Cloud Assistant Agent on an instance from checking for updates, find the installation directory of Cloud Assistant Agent version and create the disable_update file in the config directory. To disable all versions of Cloud Assistant Agent on an instance from checking for updates, find the general installation directory of all Cloud Assistant Agent versions and create the disable_update file in the config directory. You do not need to write data to the disable_update file.

    • If the instance on which Cloud Assistant Agent is installed runs a Windows Server operating system, run the following command in PowerShell:

      # For example, run the following command to disable a specific version of Cloud Assistant Agent from checking for updates:
      New-Item -Path C:\ProgramData\aliyun\assist\{version}\config\disable_update
      # For example, run the following command to disable all versions of Cloud Assistant Agent from checking for updates:
      New-Item -Path C:\ProgramData\aliyun\assist\config\disable_update
    • If the instance on which Cloud Assistant Agent is installed runs a Linux operating system, run the following command:

      # For example, run the following command to disable a specific version of Cloud Assistant Agent from checking for updates:
      touch /usr/local/share/aliyun-assist/{version}/config/disable_update
      # For example, run the following command to disable all versions of Cloud Assistant Agent from checking for updates:
      touch /usr/local/share/aliyun-assist/config/disable_update
    Note

    {version} indicates the version number of Cloud Assistant Agent.