The Cloud Assistant Agent is an agent that runs Cloud Assistant commands on Elastic Compute Service (ECS) instances. This topic describes how to start, stop, or uninstall the Cloud Assistant Agent.

Start or stop the Cloud Assistant Agent on a Windows instance

To start or stop the Cloud Assistant Agent on a Windows instance, perform the following steps.
Warning AliyunService is the process of the Cloud Assistant Agent. If you stop AliyunService on an instance, the Cloud Assistant Agent also stops. This may cause an exception on the instance, and the instance cannot be stopped in the ECS console. Proceed with caution when you stop AliyunService.
  1. Connect to the Windows instance.
  2. Click Start and choose Windows Administrative Tools > Computer Management.
  3. Choose Computer Management (Local) > Services and Applications > Services.
  4. Find AliyunService and click Stop the service or Restart the service.
    Restart the service

Uninstall the Cloud Assistant Agent from a Windows instance

If the Cloud Assistant Agent is no longer needed, perform the following operations to uninstall the Cloud Assistant Agent:

  1. Stop the Cloud Assistant Agent. For more information, see the Start or stop the Cloud Assistant Agent on a Windows instance section of this topic.
  2. Delete the C:\ProgramData\aliyun\assist directory.

Start or stop the Cloud Assistant Agent on a Linux instance

Note Before you stop the Cloud Assistant Agent, you must uninstall the Cloud Assistant daemon process. For more information, see the Uninstall the Cloud Assistant daemon process from a Linux instance section of this topic.

To start or stop the Cloud Assistant Agent on a Linux instance, perform the following steps.

  1. Connect to the Linux instance.
  2. Run the following commands based on the initialization process of the Linux instance.
    • Linux operating systems that are based on new Linux kernel versions typically use the systemd initialization process. Perform the following steps:
      • Check whether the instance uses the systemd initialization process. If the instance uses systemd, a command output is displayed.
        strings /sbin/init | grep "/lib/system"
      • Stop the Cloud Assistant Agent.
        systemctl stop aliyun.service
      • Start the Cloud Assistant Agent.
        systemctl start aliyun.service
      • Restart the Cloud Assistant Agent.
        systemctl restart aliyun.service
    • Ubuntu 14 and earlier operating systems typically use the UpStart initialization process. Perform the following steps:
      • Check whether the instance uses the UpStart initialization process. If the instance uses UpStart, a command output is displayed.
        strings /sbin/init | grep "upstart"
      • Stop the Cloud Assistant Agent.
        /sbin/initctl stop aliyun-service
      • Start the Cloud Assistant Agent.
        /sbin/initctl start aliyun-service
      • Restart the Cloud Assistant Agent.
        /sbin/initctl restart aliyun-service
    • Linux operating systems that are based on early Linux kernel versions typically use the sysvinit initialization process. Perform the following steps:
      • Check whether the instance uses the sysvinit initialization process. If the instance uses sysvinit, a command output is displayed.
        strings /sbin/init | grep "sysvinit"
      • Stop the Cloud Assistant Agent.
        /etc/init.d/aliyun-service stop
      • Start the Cloud Assistant Agent.
        /etc/init.d/aliyun-service start
      • Restart the Cloud Assistant Agent.
        /etc/init.d/aliyun-service restart

Uninstall the Cloud Assistant daemon process from a Linux instance

The Cloud Assistant daemon process is used to monitor the resource consumption of the Cloud Assistant Agent, report the running state of the client, and restart the client if the client fails. Before you uninstall the Cloud Assistant Agent, you must uninstall the Cloud Assistant daemon process.
Note The Cloud Assistant daemon process is available only for Linux instances.
  1. Connect to the Linux instance.
  2. Stop the Cloud Assistant daemon process.
    /usr/local/share/assist-daemon/assist_daemon --stop
    Note In the preceding command, /usr/local/share/assist-daemon/assist_daemon is the default path of the Cloud Assistant daemon process.
  3. Uninstall the Cloud Assistant daemon process.
    /usr/local/share/assist-daemon/assist_daemon --delete
  4. Delete the directory of the Cloud Assistant daemon process.
    rm -rf /usr/local/share/assist-daemon

Uninstall the Cloud Assistant Agent from a Linux instance

If the Cloud Assistant Agent is no longer needed, perform the following operations to uninstall the Cloud Assistant Agent.

  1. Connect to the Linux instance.
  2. Uninstall the Cloud Assistant daemon process.
    For more information, see the Uninstall the Cloud Assistant daemon process from a Linux instance section of this topic.
  3. Stop the Cloud Assistant Agent.
    For more information, see the Start or stop the Cloud Assistant Agent on a Linux instance section of this topic.
  4. Use one of the following methods to uninstall the Cloud Assistant Agent:
    • Run the following command to uninstall the Cloud Assistant RPM package:
      sudo rpm -qa | grep aliyun_assist | xargs sudo rpm -e
    • Perform the following operations to uninstall the Cloud Assistant DEB package:
      1. Run the sudo dpkg -l command to query the name of the Cloud Assistant DEB package.
      2. Run the sudo dpkg -r <Name of the Cloud Assistant DEB package> command to uninstall the Cloud Assistant DEB package.
    • Run the rm -rf /usr/local/share/aliyun-assist command to delete the directory of the Cloud Assistant Agent.