Updated on 2026-07-13 GMT+08:00

Installing the SMS-Agent on Linux

Scenarios

Before the migration, you must install the Agent on the source server to be migrated. During the installation, you need to enter the AK/SK pair of the Huawei Cloud account you are migrating to. After the Agent is started, it automatically reports source server information to SMS. The information is used for migration only. To learn what source server information is collected by SMS, see What Information Does SMS Collect About Source Servers?

Before using SMS to migrate servers, you need to manually install and register the SMS-Agent on each server to be migrated. If there are more than 50 servers to migrate, you can create a batch server migration workflow on MgC to automate batch installation and registration of the Agent.

Constraints

You need to log in to the source Linux server as user root.

Prerequisites

  • You have confirmed that the source server OS is supported by SMS. Learn more about supported Linux OSs.

Procedure

  1. Sign in to the SMS console.
  2. In the navigation pane, choose Agents. The Agents page is displayed.
  3. Select the Linux card, and in the Linux Agent area, click the icon next to Agent URL to copy the Agent download command. Run the command on the source server to download the Agent installation package.

  4. Copy and run the commands to download the CMS and CRL files to the Linux source server, then verify the integrity of the Agent installation file. For details, see How Do I Verify the Integrity of the Agent Installation File?

  5. Decompress the SMS-Agent software package.

    tar -zxvf SMS-Agent.tar.gz

  6. Switch to the SMS-Agent directory on the source server.

    cd SMS-Agent

  7. Determine whether to use an HTTP/HTTPS proxy server for the migration. If your source server cannot access Huawei Cloud over the Internet, you can use a proxy server. You will need to configure the proxy server yourself. In a migration over a private line or VPN, a proxy server is only used for registering the source server with SMS. It is not used for data migration.

    • If you do not need an HTTP/HTTPS proxy server, skip this step and go to the next step.
    • If you need to use an HTTP/HTTPS proxy, do as follows:
      1. Run the following command to go to the config directory:
        cd SMS-Agent/agent/config
      2. Open and edit the auth.cfg file. Do not edit the auth.cfg file unless you need to use an HTTP/HTTPS proxy.
        vi auth.cfg

        The values shown here are for reference only.

        [proxy-config]
        enable = true
        proxy_addr = https://<your-proxy-address>.com
        proxy_port = 3128
        proxy_user = root
        use_password = true

        Configure the parameters according to the table below.

        Table 1 Proxy parameter settings

        Parameter

        Description

        enable

        To use a proxy server, set enable to true.

        proxy_addr

        Enter the IP address of the proxy server, not that of the target server. The proxy is used by the source server to access SMS. Replace your-proxy-addr.com with the IP address of your own proxy server. Configure the protocol based on your proxy server. HTTPS is recommended.

        proxy_port

        Enter the proxy port opened on the proxy server.

        proxy_user

        Enter the proxy username if available, for example, root. Otherwise, leave it blank.

        use_password

        If the proxy server has a password, set this parameter to true. Otherwise, set it to false.

      3. Run the following command to save the auth.cfg file and exit:
        :wq

  8. Start the SMS-Agent.

    ./startup.sh

  9. Read the displayed information carefully, enter y, and press Enter.

    Figure 1 Entering y

  10. Enter the AK/SK pair for the Huawei Cloud account that you are migrating to and the SMS domain name. You can obtain the SMS domain name on the Agents page of the SMS console, as shown in Figure 3.

    Figure 2 Entering the AK/SK pair
    Figure 3 Obtaining the SMS domain name

    If the EPS service has been enabled for your Huawei Cloud account, after you entered the AK/SK pair, the Agent will list all enterprise projects your account is allowed to access. You can select the enterprise project you would like to migrate the source server to. This enables you to isolate permissions, resources, and finance during the migration. For details, see Migrating a Server into an Enterprise Project.

    When the information shown in the figure below is displayed, the SMS-Agent has been started up and will automatically start reporting source server information to SMS. You can go to the Servers page on the SMS console to check the record of the source server.
    Figure 4 Agent running

Uninstalling the SMS-Agent

After the migration is complete, you can uninstall the SMS-Agent from the source server. For details, see Uninstalling the SMS-Agent from Linux.