All Products
Search
Document Center

Elastic Compute Service:Connect to a Linux instance by using a username and password from a mobile device

Last Updated:May 14, 2024

You can connect to a Linux Elastic Compute Service (ECS) instance by using a username and password from a mobile device, such as an iOS or Android mobile device, to manage and configure the instance anywhere anytime. This topic describes how to use iTerminal on an iOS device or JuiceSSH on an Android device to connect to a Linux instance by using a username and password.

Prerequisites

  • A Linux instance is created.

  • A logon password is set for the instance. If you have not set a password for the instance or if you have forgotten the password, you must reset the password for the instance. For more information, see Reset the logon password of an instance.

  • A public IP address or an elastic IP address (EIP) is associated with the instance.

  • The instance is in the Running state.

  • The following rules are added to the security group to which the instance belongs. For more information, see Add a security group rule.

    Network type

    NIC type

    Rule direction

    Action

    Protocol type

    Port range

    Priority

    Authorization type

    Authorization object

    Virtual Private Cloud (VPC)

    N/A

    Inbound

    Allow

    SSH (22)

    22/22

    1

    IPv4 CIDR blocks

    0.0.0.0/0

    Classic network

    Internet

Use iTerminal on an iOS device to connect to a Linux instance

In this example, a username and a password are used for authentication.

  1. Download iTerminal.

  2. Start iTerminal.

  3. In the upper part of the page, tap SSH.SSH

  4. Configure the following parameters and tap Connect:

    • Nickname: Enter a name for the session. In this example, DocTest is entered.

    • Host Name or IP Address: Enter the auto-assigned public IP address or elastic IP address (EIP) of the Linux instance to which you want to connect.

    • Port: Enter the port number 22.

    • User Name: Enter the username that you specified when you created the Linux instance. Example: root or ecs-user.

    • Password: Enter the logon password for the Linux instance.

    iOS环境中连接Linux实例-003

    The page shown in the following figure indicates that you are connected to the Linux instance.iOS环境中连接Linux实例-014

Use JuiceSSH on an Android device to connect to a Linux instance

In this example, a username and a password are used for authentication.

  1. Install JuiceSSH.

  2. Start JuiceSSH.

  3. Tap Manage Connections.

    juicessh管理连接.jpg

  4. Tap the + icon.

  5. Configure the following parameters and tap the icon:

    • Nickname: Enter a name for the session. In this example, DocTest is entered.

    • Type: Use the default value SSH.

    • Address: Enter the auto-assigned public IP address or EIP of the Linux instance to which you want to connect.

    • Perform the following steps to configure the Identity parameter:

      1. Tap Identity and select New from the drop-down list.

      2. Configure the following parameters and tap the icon:

        • Nickname: optional. You can enter an identity name to facilitate subsequent management. In this example, DocTest is entered.

        • Username: Enter the username that you specified when you created the Linux instance. Example: root or ecs-user.

        • Password: Tap UPDATE/CLEAR and enter the logon password for the Linux instance.

    • Port: Enter the port number 22.

  6. Confirm the prompt and tap ACCEPT.

  7. (Optional) The first time you connect to the Linux instance, you are prompted to enter information such as the font size. Confirm the information and tap OK - I'VE GOT IT!.

The page shown in the following figure indicates that you are connected to the Linux instance.