If you cannot use Workbench or connection software such as PuTTY, Xshell, and SecureCRT to connect to an Elastic Compute Service (ECS) Linux instance, you can use Virtual Network Computing (VNC) in the ECS console to connect to the Linux instance and view the real-time status of the instance operation interface.

Prerequisites

A logon password is set for the instance.
Note If you have not set a logon password for the instance or forget the password, you can reset the password. For more information, see Reset the logon password of an instance.

Background information

The following passwords are involved when you use VNC to connect to an instance:
  • VNC password: the password of VNC used to connect to an instance.
  • Instance logon password: the password used to log on to the instance operating system.

By default, a VNC connection session lasts for about 300 seconds. If you do not perform operations within these 300 seconds, the connection to the instance is automatically closed. You must connect to the instance again.

If you cannot use Workbench or connection software to connect to your instance, you can use VNC in the ECS console to connect to the instance. After the instance is connected, you can view the status of the instance and perform operations to resolve the issues described in the following table.

IssueSolution
Various processes can slow startup time, such as system checks during system startup.Check the self-check progress.
The firewall of the instance operating system is enabled by mistake.Disable the firewall.
The instance is intruded, which causes a high CPU utilization and high bandwidth usage.Troubleshoot and terminate abnormal processes.

Procedure

The following figure shows how to use VNC to connect to an instance. Procedure
  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Instances & Images > Instances.
  3. In the top navigation bar, select a region.
  4. On the Instances page, find the instance to be connected and click Connect in the Actions column.
  5. In the Remote connection dialog box, click Connect in the VNC Connection section.
  6. Connect to a VNC management terminal.
    Note In this step, use the VNC password.
    • The first time you connect to a VNC management terminal, perform the following operations:
      1. Change the VNC password. For more information, see the Change the VNC password section in this topic.
      2. In the Enter VNC Password dialog box, enter the new password.
      3. Click OK.
    • If you are not connecting to a VNC management terminal for the first time, perform the following operations:
      1. In the Enter VNC Password dialog box, enter the password.
      2. Click OK.
  7. Log on to the instance operating system.
    Note In this step, use the instance logon password.
    1. Enter the username root or ecs-user and press the Enter key.
    2. Enter the logon password of the instance and press the Enter key.
      Note The characters of the password are hidden when you enter the password. After you enter the password, press the Enter key.
      You can switch between up to 10 different VNC management terminals when you connect to the Linux instance. The default terminal is CTRL+ALT+F1. For example, you can choose Send Remote Call > CTRL+ALT+F2 to switch to CTRL+ALT+F2. A persistent black screen indicates that the instance is in sleep mode. Press a key to wake up the instance.

Change the VNC password

The first time you connect to the VNC management terminal, you must change the VNC password. You can also change the VNC password when you forget the password or when you want to update the password.
Important After you change the VNC password for a non-I/O optimized instance, you must restart the instance in the ECS console for the new password to take effect. Before you restart the instance, you must stop it. This can lead to service interruption. Proceed with caution.
  1. On the Instances page, find the instance to be connected and click Connect in the Actions column.
  2. In the Remote connection dialog box, click Connect in the VNC Connection section.
  3. In the Enter VNC Password dialog box, click Reset VNC Password.
  4. In the Reset VNC Password dialog box, enter and confirm the new password, and then click OK.
  5. Optional: If the instance is a non-I/O optimized instance, restart the instance.
    For more information, see Restart instances.

Copy long commands

If you want to copy a long-text item such as a download URL from your computer to the instance, you can use the command copy feature.

  1. On the Instances page, find the instance to be connected and click Connect in the Actions column.
  2. Connect to a VNC management terminal.
  3. In the upper-left corner of the interface, click Enter Copy Commands.
  4. In the Copy and Paste Commands dialog box, enter the content to be copied and click OK.