All Products
Search
Document Center

Simple Application Server:Use WinSCP to connect to a simple application server

Last Updated:Jan 30, 2024

If your on-premises computer runs a Windows OS, you can use WinSCP to remotely connect to a Linux simple application server for file management.

Prerequisites

WinSCP is downloaded and installed. For more information about how to download and install WinSCP, visit the WinSCP official website.

Background information

You can use the following methods to connect to a Linux simple application server by using WinSCP. You can choose one of the methods based on your business requirements.

By default, Secure Shell (SSH) is not installed on Windows simple application servers. Therefore, WinSCP cannot be used to connect to Windows servers. To manage files on a Windows server, you can use Remote Desktop Connection (RDC) to connect to the server. For more information, see Connect to a Windows server.

Use a key pair to connect to a Linux server

  1. Create a key pair for the Linux server to which you want to connect.

    For more information, see Create a key pair.

    Note

    If a key pair is already created for the Linux server, skip this step.

  2. Open WinSCP and configure the key pair.

    1. Start WinSCP. In the Login dialog box, click Advanced... in the Session section.

      If the Login dialog box does not appear, you can choose Sessions > New Session... in the top navigation bar of the WinSCP window to open the dialog box.

    2. In the left-side navigation pane of the Advanced Site Settings dialog box, choose SSH > Authentication.

    3. In the Authentication parameters section, click ... in the Private key file field.

    4. Select the server key file in the .pem format that is stored on your computer.

      If the server key file in the .pem format is not found, you must select All Private Key Files to view all private key files. 所有私钥文件

    5. In the message that appears, click OK.

      WinSCP supports only key files in the PuTTY format. After you click OK, WinSCP converts the key file from the .pem format to the PuTTY format.

    6. After the key file is converted, click OK in the Information message.

      The key file is converted into the .ppk format, as shown in the following figure. ppk

    7. In the Advanced Site Settings dialog box, click OK.

  3. Connect to the Linux server.

    1. In the Session section of the Login dialog box, configure parameters as shown in the following figure.

      root loginParameter description:

      • File protocol: Select SCP from the drop-down list.

      • Host name: Enter the public IP address of the Linux server.

      • Port number: Enter 22.

      • User name: Enter the username of the simple application server.

        Note

        If you want to connect to the Linux server by using a key pair, you do not need to configure the Password parameter.

    2. Click Login.

      After you are logged on to the Linux server, you can upload, download, create, or delete files. The following figure shows the WinSCP window. winscp界面 The interface consists of the following sections:

      • ①: a section for information about the on-premises host, in which the directory information of the on-premises host is shown.

      • ②: a section for information about the server, in which the directory information of the Linux server is shown.

Use a password to connect to a Linux server

  1. Configure a password for the user of the Linux server to which you want to connect.

    For more information, see Set or reset the password of a server. If a password is already configured for the user of the Linux server, skip this step.

  2. Start WinSCP. The Login dialog box appears.

    If the Login dialog box does not appear, you can choose Sessions > New Session... in the top navigation bar of the WinSCP window to open the dialog box.

  3. In the Session section, configure parameters as shown in the following figure.

    用户密码登录Parameter description:

    • File protocol: Select SCP from the drop-down list.

    • Host name: Enter the public IP address of the Linux server.

    • Port number: Enter 22.

    • User name and Password: Enter the username and password of the simple application server.

  4. Click Login.

    If the cache does not contain the host key of the server, the Warning dialog box appears. You can select Yes, No, or Cancel. In this example, Yes is selected.

    After you are logged on to the Linux server, you can upload, download, create, or delete files. The following figure shows the WinSCP window. winscp界面 The interface consists of the following sections:

    • ①: a section for information about the on-premises host, in which the directory information of the on-premises host is shown.

    • ②: a section for information about the server, in which the directory information of the Linux server is shown.

References