You can send remote commands to a cloud desktop to perform operations and maintenance (O&M) operations without logging on to the cloud desktop.

Prerequisites

The cloud desktop is in the Running state.

Background information

Cloud Assistant must be used. Cloud Assistant is an Alibaba Cloud proprietary tool used to perform O&M and deployment tasks. Cloud Assistant can automatically run Bat, PowerShell, or Shell commands on cloud desktops without the need to connect to the cloud desktops. You can use Cloud Assistant to perform tasks such as running automated O&M scripts and installing or uninstalling software.
Notice Do not stop Cloud Assistant. By default, Cloud Assistant is pre-installed and runs automatically on cloud desktops. You can log on to cloud desktops to view the service. On Windows cloud desktops, the Cloud Assistant service name is Aliyun Assist Service. On Linux cloud desktops, the Cloud Assistant service name is aliyun.

Procedure

  1. Log on to the EDS console.
  2. In the top navigation bar, select a region.
  3. In the left-side navigation pane, click Cloud Desktops.
  4. On the Cloud Desktops page, find the cloud desktop to send remote commands and use one of the following methods to send remote commands:
    • Click the More icon in the Actions column corresponding to the cloud desktop and select Send Remote Commands.
    • Click the cloud desktop ID to go to the details page. Click the Command Execution Details tab and then click Send Remote Commands.
  5. In the Send Remote Commands dialog box, perform the following operations:
    1. Set Command Type.
      • For Windows cloud desktops, select PowerShell or Bat.
      • For Linux cloud desktops, select Shell.
    2. In the Command Content code editor, enter a command.
      Note The command must be able to return the results of a single execution. Interactions with returned information are not allowed.
    3. Click Execute.
      • You can click Stop to stop executing the command.
      • After the command is executed, you can view the command output in the Command Output section.
    Note After a command is executed, you can enter another command in the Command Content code editor and execute the command.

Result

After the command is executed, you can view the command execution information for the cloud desktop on the Command Execution Details tab on the desktop details page. You can also view the command execution information for all cloud desktops on the Remote Commands page.