Help Center/ Host Security Service/ FAQs/ Agent/ What Do I Do If the Agent Fails to Be Installed on a Server?
Updated on 2026-08-18 GMT+08:00

What Do I Do If the Agent Fails to Be Installed on a Server?

If the agent fails to be installed, rectify the fault by following the instructions provided in this section.

Failed to Install the Agent on the HSS Console

If the agent fails to be installed on the console, rectify the fault based on the information displayed on the HSS management console and Table 1.

Table 1 Suggestions for troubleshooting agent Installation failures

Console Message

Suggestion

Network disconnected and access timed out. Check your network configurations.

  • Linux
    1. Check whether the server can access the network.
      • If the network access is normal, go to 2.
      • If the network access is abnormal, check the network configuration to ensure that the server can access the network.
    2. Check whether port 22 is enabled in the inbound direction of the security group that the server belongs to.

      HSS will log in to the server using SSH to install the agent. If port 22 is not enabled, HSS cannot install the agent.

      For details about how to configure a security group, see Configuring Security Group Rules.

  • Windows
    1. Check whether the server can access the network.
      • If the network access is normal, go to 2.
      • If the network access is abnormal, check the network configuration to ensure that the server can access the network.
    2. Check whether port 5985 is enabled in the inbound direction of the security group that the server belongs to.

      Port 5985 needs to be enabled if agents are batch-installed on servers using scripts.

      The server where the script is executed needs to access the port 5985 on other servers. You need to modify the inbound rules of the security groups on those servers to allow access from the IP address of the script-executing server. HSS uses the script-executing server as the executor and logs in to other servers through port 5985 to install the agent.

      For details about how to configure a security group, see Configuring Security Group Rules.

Authentication failed due to incorrect password. Check the password.

The password is incorrect. Check the password information you entered.

There are no private keys managed by DEW. Please check DEW.

Check and restore your DEW key pair to the Managed state.

Metadata check failed. Check the metadata information.

Failed to obtain the metadata. For details, see Why Can't My Linux ECS Obtain Metadata?

Failed to install Expect. Check the Expect installation information.

Check whether the network fluctuates. After the network recovers, install the agent again.

If the network is normal but the installation still fails, choose Service Tickets > Create Service Ticket in the upper right corner of the Huawei Cloud management console to contact technical support.

Failed to connect to VPC. Acquire VPCOperatePolicy permissions and try again.

HSS does not have the VPCOperatePolicy permission so it cannot communicate with each other between VPCs. You are advised to perform the following operations to grant the permission:

  1. Log in to the HSS console.
  2. Click in the upper left corner and select a region and a project.
  3. In the navigation pane, choose Installation & Configuration > Permissions Management.
  4. Click Assign in the upper left corner of the permission list to grant the VPCOperatePolicy permission to HSS.

For details about the VPCOperatePolicy permission, see Authorization.

Cannot find the key pair of this server in DEW. Check whether the key pair exists.

Check whether your DEW key pair exists.

Failed to connect to VPCEP. Ensure you have VPCOperatePolicy permissions and check available IP addresses.

HSS cannot create a VPC endpoint (used for communication between the agent and the HSS server) because the VPCEPOperatePolicy permission is not granted to HSS. As a result, the agent fails to be installed. You are advised to perform the following operations to grant the permission:

  1. Log in to the HSS console.
  2. Click in the upper left corner and select the desired region and project.
  3. In the navigation pane, choose Installation & Configuration > Permissions Management.
  4. Click Assign in the upper left corner of the permission list to grant the VPCEPOperatePolicy permission to HSS.

For details about the VPCEPOperatePolicy permission, see Authorization.

Failed to log in using the key. Check whether the key is correct.

The key is incorrect. Check the key information you entered.

Insufficient permissions to run the installation command.

Possible cause: The script cannot be executed in the /tmp directory, or bash does not have the execution permission.

Suggestion:

  • You are advised to check whether the preceding directories or files have the corresponding permissions.
  • If the permissions have been granted but the installation still fails, choose Service Tickets > Create Service Ticket in the upper right corner of the Huawei Cloud management console to contact technical support.

Failed to download the installation file. Log in to the server, run the installation command, and check whether the master can be accessed. If the access fails, check security group and DNS configurations.

This error occurs only on Linux servers. You are advised to perform the following operations to check the security group and DNS configurations.

  • Checking the security group

    Log in to the server and run the following command to check whether port 10180 of the 100.125.0.0/16 CIDR block is allowed in the outbound direction of the server security group:

    curl -kv https://hss-agent.region code.myhuaweicloud.com:10180

    Each region has a unique region code. For details about the region code, see Regions and Endpoints.

    Take CN North-Beijing1 as an example. The complete command is as follows: curl -kv https://hss-agent.cn-north-1.myhuaweicloud.com:10180
    • If the ping command is successfully executed, port 10180 of 100.125.0.0/16 CIDR block has been enabled.
    • If the page is suspended after the ping command is executed, the port 10180 in the 100.125.0.0/16 network segment is not allowed. For details about how to allow the port, see Adding a Security Group Rule.
  • Checking DNS configurations

    Log in to the server and run the following command to check whether the DNS of the server can resolve the domain name for downloading the agent:

    ping -c 1 hss-agent.RegionCode.myhuaweicloud.com

    Each region has a unique region code. For details about the region code, see Regions and Endpoints.

    Take CN North-Beijing1 as an example. The complete command is as follows: ping -c 1 hss-agent.cn-north-1.myhuaweicloud.com

    • If the resolved IP address is displayed, the DNS resolution is normal.
    • If name or service not known is displayed or no IP address is resolved, the DNS resolution fails. For details, see Modifying the DNS.

Insufficient disk space.

Check the following directories to ensure that the disk capacity is sufficient:

  • Linux

    /usr/local: default installation path of the agent. Ensure the available disk space is greater than 300 MB.

  • Windows
    • C:\Users\xxx\Downloads: path for downloading the agent installation package. Ensure the available disk space is greater than 100 MB.
    • C:\Program Files\HostGuard: default installation path of the agent. Ensure the available disk space is greater than 300 MB.

No key pairs returned from DEW. Verify permissions first.

Check and ensure your key pair is managed by DEW.

If the key pair is already managed by DEW, but HSS still displays a message indicating that the managed private key is not found when you install the agent, the possible cause is that your current account is an IAM member account or delegated account and does not have the permissions for KPS in DEW. You can go to the IAM console and use any of the following methods to grant permissions:

  • Authorization method 1
    Grant the DEW KeypairFullAccess permission (full permissions for KPS) to the agent installation account.
    • Account authorization:
      1. Hover the cursor to the username in the upper right corner.
      2. Click Identity and Access Management. Choose Users. Search for the user to be authorized and click the username.
      3. On the User Groups tab, click any user group.
      4. On the Permissions tab, click Authorize. Search for DEW KeypairFullAccess, select it, and click Next.
      5. Click OK.
    • Agency account authorization:
      1. Hover the cursor to the username in the upper right corner.
      2. Click Identity and Access Management. Choose Agencies. Search for hss_policy_trust and click the agency name.
      3. On the Permissions tab, click Authorize. Search for DEW KeypairFullAccess, select it, and click Next.
      4. Click OK.
  • Authorization method 2

If you do not want the agent installation account to have the permission to delete key pairs, you can create the following custom policy and grant the policy to the account. For details, see Creating a Custom Policy.

Policy for allowing users to query and export key pairs:

{     
       "Version": "1.1",
       "Statement": [  
           {
              "Action": [
                    "kps:domainKeypairs:exportpk",
                    "kps:domainKeypairs:list",
                    "kps:domainKeypairs:get"
              ], 
              "Effect": "Allow
           } 
      ]

After creating a policy, grant permissions by referring to Authorization method 1. You only need to change DEW KeypairFullAccess in authorization method 1 to a custom policy.

Installation error.

Perform the following operations:

  1. Log in to the HSS console.
  2. Click in the upper left corner and select the desired region and project.
  3. In the navigation pane, choose Installation & Configuration > Permissions Management.
  4. Check whether the VPCEPOperatePolicy and VPCOperatePolicy permissions are in the permission list.
    • If yes, contact technical support. In the upper right corner of the management console, choose Service Tickets > Create Service Ticket and submit a service ticket.
    • If no, click Assign in the upper left corner of the permission list and grant the VPCEPOperatePolicy and VPCOperatePolicy permissions to HSS. Install the agent again.

      For details about the permissions, see Authorization.

Cannot connect to the target VPC due to NIC route conflicts. Install the agent using the CLI, or upgrade an agent in that VPC.

A route conflict occurs between the NIC of your server and the elastic NIC attached to the server where the agent is being installed. The VPC network cannot be connected. You are advised to install the agent using commands.

For details, see Using the Commands or Script to Install the Agent on Huawei Cloud Servers (Current-account Installation).

There is no VM with an online agent in the VPC of this server. Install or upgrade the agent using commands in the VPC.

  1. Check whether there is at least one server with an online agent in the VPC where the target server is located.
  2. Check whether the agent version is 3.2.13 or later.

Installation failed

Install the agent again. If the installation fails again, Click Service Tickets > Create Service Ticket in the upper right corner of the management console to contact technical support.

Failed to Install the Agent Using Commands

If you fail to install the agent using commands (that is, by logging in to the server and running commands), rectify the fault based on the command output.