Esta página aún no está disponible en su idioma local. Estamos trabajando arduamente para agregar más versiones de idiomas. Gracias por tu apoyo.
- What's New
- Function Overview
- Service Overview
-
Billing
- Billing Overview
- Billing Modes
- Billing Items
- Billing Examples
- Billing Mode Changes
- Subscription Renewal
- Bills
- Arrears
- Billing Termination
- Cost Management
-
Billing FAQ
-
Billing Modes
- What Are the Differences Between Yearly/Monthly and Pay-per-Use Billing Modes?
- Will I Be Billed After ECSs Are Stopped?
- Can I Switch Between Yearly/Monthly and Pay-per-Use Billing Modes?
- FAQs About ECS Frozen, Deletion, and Unsubscription
- How Can I Stop an ECS from Being Billed?
- FAQs About Spot ECSs
- Renewal and Unsubscription
-
Billing Modes
- Getting Started
-
User Guide
- Using IAM to Grant Access to ECS
- Instances
- Images
- Disks
- Elastic Network Interfaces
- EIPs
- Security
- Backup Using CBR
- Passwords and Key Pairs
- Resources and Tags
-
Monitoring Using Cloud Eye
- Monitoring ECSs
- Basic ECS Metrics
- OS Monitoring Metrics Supported by ECSs with the Agent Installed
- Process Monitoring Metrics Supported by ECSs with the Agent Installed
- OS Monitoring Metrics Supported by ECSs with the Agent Installed and Using Simplified Monitoring Metrics
- Setting Alarm Rules
- Viewing ECS Metrics
- Audit Using CTS
-
Best Practices
- Best Practices Summary
- Setting Up Websites on ECSs
- Configuring an ECS
- Setting Up an Environment
- Setting Up a Website
-
Setting Up an Application
- Setting Up an FTP Site
- Building Microsoft SharePoint Server 2016
- Deploying Docker
- Deploying an ECS for Handling Text Messages from an Official WeChat Account
- Manually Deploying GitLab (CentOS 7.2)
- Manually Deploying RabbitMQ (CentOS 7.4)
- Setting Up Master-Slave Replication on PostgreSQL
- Manually Installing a BT Panel (CentOS 7.2)
- Installing and Deploying Jenkins on an ECS
- Using auditd to Record File Changes (Linux)
- Restoring Accidentally Deleted Data Using Extundelete (Linux)
- Setting Up a ThinkPHP Framework
- Securing an ECS
- Migrating an ECS
- Accessing OBS from an ECS over the Intranet
- Using VNC Viewer to Access a Linux ECS
-
API Reference
- Before You Start
- API Overview
- Calling APIs
-
APIs (Recommended)
- Lifecycle Management
-
Status Management
- Reinstalling an ECS OS (Using an Image with Cloud-Init Installed)
- Changing an ECS OS (Using an Image with Cloud-Init Installed)
- Reinstalling an ECS OS (Using an Image Without Cloud-Init Installed)
- Changing an ECS OS (Using an Image Without Cloud-Init Installed)
- Cold Migrating an ECS
- Obtaining the VNC Login Address
- Modifying the Specifications of an ECS
- Modifying the Specifications of an ECS (Pay-per-Use)
- Batch Operations
- Flavor Management
- NIC Management
- Disk Management
- Metadata Management
- Tenant Quota Management
- Task Status Management
- Tag Management
- ECS Group Management
-
OpenStack Nova APIs
- API Version Query
- Lifecycle Management
- Status Management
- Network Management
- Security Group Management
- Flavor Management
- NIC Management
- Disk Management
- Metadata Management
- Tenant Quota Management
- Key and Password Management
- ECS Group Management
- ECS Operation Management
- ECS Console Management
- AZ
- Tag Management
- Historical Versions
- Application Examples
- Data Structure
-
Permissions and Supported Actions
- Introduction
- Lifecycle Management
- ECS Status Management
- Batch Operations
- Network Management
- Image Management
- Security Group Management
- Specifications Query
- NIC Management
- Disk Management
- Metadata Management
- Tenant Quota Management
- SSH Key Management
- Floating IP Address Management
- ECS Group Management
- ECS Management Through Console
- AZ Management
- Tag Management
- Common Parameters
-
Out-of-Date APIs
- Status Management
- Flavor Management
- NIC Management
- Disk Management
- Tag Management
- Image Management (OpenStack Nova APIs)
- Security Group Management (OpenStack Nova APIs)
- Disk Management (OpenStack Nova APIs)
-
Floating IP Address Management (OpenStack Nova APIs)
- Binding a Floating IP Address (Discarded)
- Unbinding a Floating IP Address (Discarded)
- Assigning a Floating IP Address (Discarded)
- Querying Floating IP Addresses (Discarded)
- Querying Details About a Floating IP Address (Discarded)
- Releasing a Floating IP Address (Discarded)
- Querying Floating IP Address Pools (Discarded)
- Snapshot Management (OpenStack Nova APIs)
- Appendix
- Change History
- SDK Reference
-
FAQs
- Common FAQ
- Product Consulting FAQ
-
ECS Creation FAQ
- What Should I Do If the ECS Resources to Be Purchased Are Sold Out?
- How Can I Set Sequential ECS Names When Creating Multiple ECSs?
- What Is the Creation Time and Startup Time of an ECS?
- Why Does the Failures Area Show an ECS Creation Failure But the ECS List Displays the Created ECS?
- Why Cannot I View the ECSs Being Created Immediately After I Pay for Them?
- Why Does It Take Longer to Create ECSs When I Use a Full-ECS Image?
- What Do I Do If I Selected an Incorrect Image for My ECS?
- How Quickly Can I Obtain an ECS?
- How Can I Manage ECSs by Group?
- ECS Deletion and Unsubscription FAQ
-
Remote Login FAQ
- Login Preparations
-
Remote Logins
- Why Can't I Log In to My Linux ECS?
- How Can I Change a Remote Login Port?
- Why Cannot I Use a Non-Default SSH Port to Log In to My Linux ECS?
- What Browser Version Is Required to Remotely Log In to an ECS?
- How Can I Log In to an ECS After It Exchanged the System Disk with Another ECS Running the Same OS?
-
VNC Login
- Why Are Garbled Characters Displayed When I Log In to My ECS Using VNC?
- What Should I Do If I Cannot View Data After Logging In to an ECS Using VNC?
- Why Does a Blank Screen Appear After I Attempted to Log In to an ECS Using VNC?
- What Should I Do If Error Code 1006 or 1000 Is Displayed When I Log In to an ECS Through the Management Console?
-
Remote Login Errors on Linux
- Why Am I Seeing the Error Message "Module is unknown" When I Remotely Log In to a Linux ECS?
- What Should I Do If Error Message "Permission denied" Is Displayed When I Remotely Log In to a Linux ECS?
- What Should I Do If Error Message "read: Connection reset by peer" Is Displayed When I Remotely Log In to a Linux ECS?
- Why Am I Seeing the Error Message "Access denied" When I Remotely Log In to a Linux ECS?
- What Should I Do If Error Message "Disconnected: No supported authentication methods available" Is Displayed When I Remotely Log In to a Linux ECS?
-
Billing FAQ
- What Are the Differences Between Yearly/Monthly and Pay-per-Use Billing Modes?
- Will I Be Billed After ECSs Are Stopped?
- Can I Switch Between Yearly/Monthly and Pay-per-Use Billing Modes?
- FAQs About ECS Frozen, Deletion, and Unsubscription
- How Can I Stop an ECS from Being Billed?
- FAQs About Spot ECSs
- How Can I Renew ECSs?
- How Can I Automatically Renew a Yearly/Monthly ECS?
- Will I Receive a Notification If My Account Balance Is Insufficient?
-
Region and AZ FAQ
- What Is AZ and How Can I Select and View an AZ?
- What Is a Region?
- Are Products Different in Different Regions?
- Is Data Transmission Between AZs Billed?
- Can I Change the Region or AZ After an ECS Is Purchased?
- Can I Migrate an ECS to Another Region, AZ, or Account?
- Can a Load Balancer Distribute Traffic to ECSs in Different Regions?
- Can Components Contained in an Application Be Distributed to Different Regions?
-
OS FAQ
- Do ECSs Support GUI?
- How Can I Install a GUI on an ECS Running CentOS 6?
- How Can I Install a GUI on an ECS Running CentOS 7?
- How Can I Install a GUI on an ECS Running Ubuntu?
- Why Does the OS Fail to Respond When kdump Occurs on a Linux ECS?
- How Can I Upgrade the Kernel of a Linux ECS?
- Why Cannot My ECS OS Start Properly?
- How Can I Fix the Meltdown and Spectre Security Vulnerabilities on Intel Processor Chips?
- How Can I Enable SELinux on an ECS Running CentOS?
-
Disk Partition, Attachment, and Expansion FAQ
- How Can I Adjust System Disk Partitions?
- How Can I Obtain the Mapping Between Disk Partitions and Disk Devices on a Linux ECS?
- How Can I Add the Empty Partition of an Expanded System Disk to the End Root Partition Online?
- How Can I Add the Empty Partition of an Expanded System Disk to the Non-end Root Partition Online?
- Can I Attach Multiple Disks to an ECS?
- What Are the Requirements for Attaching an EVS Disk to an ECS?
- Which ECSs Can Be Attached with SCSI EVS Disks?
- How Do I Obtain My Disk Device Name in the ECS OS Using the Device Identifier Provided on the Console?
- Why Does a Linux ECS with a SCSI Disk Attached Fails to Be Restarted?
- How Can I Check Whether the ECSs Attached with the Same Shared SCSI Disk Are in the Same ECS Group?
- Can All Users Use the Encryption Feature?
- How Can I Add an ECS with Local Disks Attached to an ECS Group?
- Will My EVS Disk Be Deleted When I Delete Its Server?
- Why Does the Disk Drive Letter Change After the ECS Is Restarted?
- How Can I Obtain Data Disk Information If Tools Are Uninstalled?
- How Can I Rectify the Fault That May Occur on a Linux ECS with an NVMe SSD Disk Attached?
- Why Are Disk Error Logs Printed After a Disk Attached to an ECS Is Formatted with the ext4 File System?
- Data Backup and Restoration FAQ
-
Network Configuration FAQ
- How Can I Configure the NTP and DNS Servers for an ECS?
- Does HUAWEI CLOUD Provide the NTP Server and How Can I Configure It?
- How Do I Configure DNS for an ECS?
- Can the ECSs of Different Accounts Communicate over an Intranet?
- Will ECSs That I Purchased Deployed in the Same Subnet?
- How Do I Change the CIDR Block of an ECS Subnet?
- How Do I Configure Port Mapping?
- How Can I Obtain the MAC Address of My ECS?
- How Can I View and Modify Kernel Parameters of a Linux ECS?
- Why Is the NIC Not Working?
- Why Can't I Use DHCP to Obtain a Private IP Address?
- How Can I Test the Network Performance of Linux ECSs?
- What Should I Do If NIC Flapping Occurs After My ECS Specifications Are Modified?
- Will NICs Added to an ECS Start Automatically?
- How Can I Check Whether the Network Communication Is Normal Between Two ECSs Equipped with an InfiniBand NIC Driver?
- How Can I Manually Configure an IP Address for an InfiniBand NIC?
- How Can I Add a Static Route to a CentOS 6.5 OS?
- EIP FAQ
-
Password and Key Pair FAQ
- How Can I Change the Password for Logging In to a Linux ECS?
- What Is the Default Password for Logging In to a Linux ECS?
- How Can I Set the Validity Period of the Image Password?
- Resetting the Password for Logging In to an ECS in the OS
- What Should I Do If the System Displays a Message Indicating that the Password Is Incorrect When I Remotely Log In to My ECS?
- What Should I Do If I Cannot Log In to My ECS Using the Initial Password After I Use It for a Period of Time?
- Disabling SELinux
- How Can I Obtain the Key Pair Used by My ECS?
- How Can I Use a Key Pair?
- Can I Download a Key Pair from My Phone?
- What Should I Do If a Key Pair Cannot Be Imported?
- Why Does the Login to My Linux ECS Using a Key File Fail?
- What Should I Do If I Cannot Download a Key Pair?
- Why Does a Key Pair Created Using puttygen.exe Fail to Be Imported on the Management Console?
- What Should I Do If Cloud-Init Does Not Work After Python Is Upgraded?
- Application Deployment and Software Installation FAQ
-
File Upload/Data Transfer FAQ
- How Do I Upload Files to My ECS?
- How Can I Use WinSCP to Transfer Files from a Local Windows Computer to a Linux ECS?
- How Can I Use SCP to Transfer Files Between a Local Linux Computer and a Linux ECS?
- How Can I Use SFTP to Transfer Files Between a Local Linux Computer and a Linux ECS?
- How Can I Use FTP to Transfer Files from a Local Windows Computer to a Linux ECS?
- How Can I Use FTP to Transfer Files Between a Local Linux Computer and a Linux ECS?
- What Should I Do If the Connection Between the Client and the Server Times Out When I Upload a File Using FTP?
- What Should I Do If Writing Data Failed When I Upload a File Using FTP?
- Why Am I Seeing an FTP Folder Error When I Open a Folder on an FTP Server?
- Why Do I Fail to Connect to a Linux ECS Using WinSCP?
-
ECS Failure FAQ
- How Do I Handle Error Messages Displayed on the Management Console?
- What Should I Do If Emails Configured on an ECS Cannot Be Sent?
- Why Is the Memory of an ECS Obtained by Running the free Command Inconsistent with the Actual Memory?
- Why Is the Hostname of My ECS Restored to the Original Name After the ECS Is Restarted?
- Is an ECS Hostname with Suffix .novalocal Normal?
- Why Does a Forcibly-Stopped Linux ECS Fail to Be Restarted?
- How Can a Changed Static Hostname Take Effect Permanently?
- Why Can't My Linux ECS Obtain Metadata?
- Slow ECS Response FAQ
- Specification Modification FAQ
-
OS Change FAQ
- Does OS Change Incur Fees?
- Can I Install or Upgrade the OS of an ECS?
- Can I Change the OS of an ECS?
- How Long Does It Take to Change an ECS OS?
- Will I Lose My Disk Data If I Reinstall ECS OS, Change the OS, or Change the ECS Specifications?
- Does OS Reinstallation Incur Fees?
- Can I Select Another OS During ECS OS Reinstallation?
- How Long Does It Take to Reinstall an ECS OS?
- ECS Security Check FAQ
- Resource Management and Tag FAQ
-
Image Source Management FAQ
- How Can I Use an Automated Tool to Configure a Huawei Cloud Image Source (x86_64 and Kunpeng)?
- How Can I Use an EPEL Image Source (x86_64 or Kunpeng) Provided by Huawei Cloud?
- How Can I Use a Pypi Image Source (x86_64 or Kunpeng) Provided by Huawei Cloud?
- What Can I Do If the Download Speed Is Slow After the yum makecache Command Is Executed?
- Internet Inaccessible FAQ
- Website or Application Inaccessible FAQ
- Slow Website or Application Response FAQ
-
Troubleshooting
-
General Issues
- Why Accessing a Website Outside the Chinese Mainland Is Slow on an ECS?
- How Do I Troubleshoot a Ping Failure or Packet Loss Using a Link Test?
- How Do I Troubleshoot Slow Connections to a Website Hosted on My ECS?
- How Do I Troubleshoot an Unresponsive Website Hosted on My ECS?
- Why Am I Unable to Connect to a Port on an ECS?
- How Can I Resolve High Bandwidth Usage on My ECSs?
- Why Is My Windows ECS Running Slowly?
- Why Is My Linux ECS Running Slowly?
- How Can I Handle Slow ECS Startup?
- How Do I Configure Multiple IP Addresses for an ECS with Multiple NICs Attached?
-
Windows ECS Issues
- How Can I Retain a Session on a Windows ECS?
- How Can I Fix the Difference Between the System Time and the Local Standard Time?
- How Do I Attach an Extension NIC to a Windows ECS for Accessing the Internet?
- How Can I Fix Grayed Out Copy and Paste Options?
- How Do I Configure File Sharing and Network Disk Mapping for a Windows ECS?
- How Do I Troubleshoot an In-Service Port During Tomcat Startup?
- How Do I Troubleshoot Unavailable Input Methods?
- How Do I Share Files Between Windows ECSs?
- How Do I Restore Data in the Event of a Startup Failure on a Windows ECS?
- How Do I View Login Logs of a Windows ECS?
-
Linux ECS Issues
- Why Is My Linux ECS Not Booting and Going Into Emergency Mode?
- How Do I Fix a "Read-Only" Error When I Edit the /etc/fstab File?
- How Do I Change the Time Zone on ECSs Running CentOS or EulerOS?
- How Do I Troubleshoot "nf_conntrack:table full, dropping packet"?
- How Do I Change the Default Boot Kernel in Ubuntu?
- How Do I Configure atop and kdump on Linux ECSs for Performance Analysis?
- Why Is the OS Version of My ECS Not the One in the Image I Selected During ECS Creation?
- How Do I Enable My ECS to Boot From the Second Kernel If It Fails to Boot from the First Kernel?
- How Can I Make /etc/rc.local Run at Startup in CentOS 7?
- What OSs Are Supported If I Want to Install Docker on a Linux ECS?
- Why Do the Modifications to /etc/security/limits.conf Not Take Effect After the ECS Restarts?
- How Do I Set vCPU Affinity for Processes Using taskset?
- What Should I Do If Error "command ´gcc´ failed with exit status 1" Occurs During PIP-based Software Installation
- What Can I Do If Switching from a Non-root User to User root Times Out?
- What Can I Do If the Permissions on the Root Directory of My CentOS ECS Changed to 777?
- What Should I Do If the IP Settings of My Linux ECS Are Lost?
- Why Does My Linux ECS Restart Unexpectedly?
- What Do I Do If Error "Cannot allocate memory" Is Displayed?
-
Configuring the Network
- Why Does My ECS Running CentOS 7 Fail to Obtain an IP Address Using dhclient?
- Why Does the NIC Names Change After I Start a Linux ECS?
- Why an Entry Is Automatically Added to /etc/hosts After a Linux ECS Is Restarted?
- How Do I Fix a Network Startup Failure Due to Multiple NIC Configuration Files?
- Why Do I Get the Error "Name or service not known" When I Ping a Public Domain Name Configured for a Linux ECS?
- Why Cannot the EIP Bound to the Extension NIC of My ECS Access the Internet?
- How Do I Fix Too High Memory Usage by NetworkManager When Multiple Docker Containers Are Running?
- Why Is the ECS IP Address Lost After the System Time Changes?
- What Can I Do If resolv.conf Gets Reset?
-
Disk Space Management Issues
- Why Can't I Mount a Disk on an Old Mount Point by Modifying fstab in CentOS 7?
- How Do I Create a Swap Partition or File in Linux?
- Why Is the Space Not Released After I Delete a Large File on a Linux ECS?
- What Should I Do If the "Read-only file system" Error Message Is Displayed When I Attempt to Delete a File on a Linux ECS?
- How Do I Fix File Creation Failures Due to Inode Exhaustion?
- Why Do I Get the Error "No space left on device" When I Create a File on a Linux ECS?
- Why the Buffer and Cache Occupy Too Much Memory of a Linux ECS?
- GPU Driver Issues
-
SSH Connection Issues
- How Do I Keep an SSH Session Alive?
- How Can I Allow or Deny Login from Specific Users or IP Addresses to an ECS Using SSH?
- Why Can't I Access an ECS Running CentOS 7 Using SSH After I Changed the Default SSH Port?
- How Can I Resolve ECS Login Failures Due to Corrupt /etc/passwd?
- Why Does It Takes a Long Time to Connect to an ECS Using SSH After UseDNS Is Enabled?
- Why Does sshd Fail to Be Started on a Linux ECS?
- How Do I Disable Login to an ECS Using SSH Password?
- Why Are Connections to a Linux ECS Using SSH or to Applications on the ECS Interrupted Occasionally?
-
Multi-User Login Issues
- How Do I Configure Multi-User Logins for an ECS Running Windows Server 2012?
- Why Does a Browser Launch Error Occur in Multi-User Login?
- How Do I Apply for a License for Authenticating Multi-User Sessions and Activate an ECS?
- How Do I Troubleshoot Login Screen Flickering After Configuring Multi-User Login?
-
Passwords and Key Pairs Issues
- How Do I Reset the Password for User root in Single-User Mode on a Linux ECS?
- How Do I Reset the Password for Logging In to a Linux ECS?
- How Do I Fix the "Authentication token manipulation error" When I Reset the Password Using passwd on a Linux ECS?
- How Do I Change the Key Pair for a Linux ECS?
- How Do I Change the Login Mode of a Linux ECS from Key Pair to Password?
- Firewall Configuration Issues
- BSOD Issues
- IIS Installation Issues
- Change History
-
General Issues
- Videos
Why Is My Linux ECS Running Slowly?
- Your ECS is a shared ECS.
Multiple ECSs share CPU resources. When resources are insufficient, ECSs may contend for CPU resources, causing slow responses.
- The bandwidth or CPU usage of the ECS may be excessively high.
If you have created an alarm rule in Cloud Eye, the system automatically sends an alarm to you when the bandwidth or CPU usage reaches the threshold specified in the rule.
- Fault locating: Check the instance type. For details about dedicated and shared ECSs, see ECS Types.
- Troubleshooting: If you have high requirements on service stability, you are advised to change a shared ECS to a dedicated ECS by referring to General Operations for Modifying Specifications.
To handle this issue, perform the following operations:
- Check whether the processes are malicious and handle the issue accordingly.
- If the processes are normal, optimize them or modify ECS specifications.
- If the processes are malicious, stop these processes manually or use a third-party tool to stop them automatically.
Common Commands
The following uses the CentOS 7.2 64bit OS as an example to describe common commands. The commands may vary depending on Linux OS editions. For details, see the official documentation for the specific OS edition.
The common commands for checking Linux ECS performance metrics, such as the CPU usage, are as follows:
- ps -aux
- ps -ef
- top
Locating High CPU Usage
- Log in to the ECS using VNC.
- Run the following command to check the OS running status:
Information similar to the following is displayed.
- View the command output.
- The first line in the command output is "20:56:02 up 37 days, 1 user, load average: 0.00, 0.01, 0.05", indicating that:
The current system time is 20:56:02; the ECS has been running for 37 days; there is one login user; the last three values indicate the average CPU load in the last 1 minute, 5 minutes, and 15 minutes, respectively.
- The third line in the command output shows the overall CPU usage.
- The fourth line in the command output shows the overall memory usage.
- The lower part of the command output shows the resource usage of each process.
NOTE:
- On the top page, enter q or press Ctrl+C to exit.
- Alternatively, click Input Command in the upper right corner of the VNC login page, paste or enter commands in the displayed dialog box, and click Send.
- Common parameters in top commands are as follows:
s: Change the image update frequency.
l: Show or hide the first line for the top information.
t: Show or hide the second line for tasks and the third line for CPUs.
m: Show or hide the fourth line for Mem and the fifth line for Swap.
N: Sort processes by PID in ascending or descending order.
P: Sort processes by CPU usage in ascending or descending order.
M: Sort processes by memory usage in ascending or descending order.
h: Show help for commands.
n: Set the number of processes displayed in the process list.
- The first line in the command output is "20:56:02 up 37 days, 1 user, load average: 0.00, 0.01, 0.05", indicating that:
- Run the ll /proc/PID/exe command to obtain the program file specified by a PID.
Troubleshooting High CPU Usage
If the processes leading to high CPU usage are malicious, run the top command to stop them. If the kswapd0 process leads to high CPU usage, optimize the program for the process or upgrade the ECS specifications for a larger memory capacity.
- For the detected malicious processes
Quickly stop such processes on the top page. To do so, perform the following operations:
- Press the k key during the execution of the top command.
- Enter the PID of the process to be stopped.
The PID of the process is the value in the first column of the top command output. For example, to stop the process with PID 52, enter 52 and press Enter.
- After the operation is successful, information similar to the following is displayed. Press Enter.
- For the kswapd0 process
To check the memory usage of a process, perform the following operations:
- Run the top command to check the resource usage of the kswapd0 process.
- If the process remains in non-sleeping state for a long period, you can preliminarily determine that the system is consistently paging. In such a case, the high CPU usage is caused by insufficient memory.
- Run the vmstat command to check the virtual memory usage of the system.
If the si and so values are large, the system is frequently paging and the physical memory of the system is insufficient.
- si: Volume of data written from the swap partition to the memory per second, which is transferred from the disk to the memory.
- so: Volume of data written from the memory to the swap partition per second, which is transferred from the memory to the disk.
- Further identify the causes of high memory usage. Run commands, such as free and ps to check the memory usage of the system and processes in the system.
- Restart the application or release the memory when traffic is light.
To handle this issue, expand the ECS memory. If memory expansion is not allowed, optimize the application and enable hugepage memory.
Handling High Bandwidth Usage
If the high bandwidth usage is caused by normal service access of non-malicious processes, enlarge the bandwidth to handle this issue. If the high bandwidth usage is caused by abnormal service access, for example, malicious access from certain IP addresses, CC attacks on the ECS, or malicious processes, use the traffic monitoring tool nethogs to monitor the bandwidth usage of each process in real time and identify faulty processes.
- Using nethogs for troubleshooting
- Run the following command to install nethogs:
yum install nethogs -y
After the installation, run the netgos command to check bandwidth usage.
Parameters in the nethogs command are as follows:- -d: Set the update interval in the unit of second. The default value is 1s.
- -t: Enable tracing.
- -c: Set the number of updates.
- device: Set the NIC to be monitored. The default value is eth0.
The following parameters are involved in command execution:- q: Exit nethogs.
- s: Sort processes in the process list by TX traffic in ascending or descending order.
- r: Sort processes in the process list by RX traffic in ascending or descending order.
- m: Switch the display unit in the sequence of KB/s, KB, B, and MB.
- Run the following command to check the bandwidth usage of each process on the specified NIC:
The parameters in the command output are as follows:
- PID: ID of the process.
- USER: user who runs the process.
- PROGRAM: IP addresses and port numbers of the process and connection, respectively. The former is for the server and the latter is for the client.
- DEV: Network port to which the traffic is destined.
- SENT: Volume of data sent by the process per second.
- RECEIVED: Volume of data received by the process per second.
- Stop malicious programs or blacklist malicious IP addresses.
To stop a malicious process, run the kill PID command.
To blacklist a malicious IP address or limit its rate, use iptables.
- Run the following command to install nethogs:
- Using Web Application Firewall (WAF) to protect the ECS against CC attacks
If your ECS has encountered a CC attack, enable CC security protection on the WAF console. For instructions about how to use WAF, see Configuring a CC Attack Protection Rule.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.