You can monitor the status of your ECS instances to ensure that your users can always access your websites and applications, process data, and render videos. Alibaba Cloud provides data monitoring, visualization of monitoring data, and real-time alerts to make sure that your ECS instances are running without interruption.

Background information

You can monitor your ECS instances by using the ECS monitoring service or CloudMonitor. ECS provides vCPU utilization, network traffic, and disk I/O monitoring for a specified instance. In CloudMonitor, you can monitor a wider range of instance metrics with finer granularity. For more information about CloudMonitor, see Metrics. The following section describes some of the metrics provided by the ECS monitoring service:
  • vCPU utilization: the percentage of allocated ECS compute units that are currently in use on the instance. A higher percentage indicates a higher vCPU load on an instance. You can view the vCPU utilization in the ECS console or in the CloudMonitor console. You can also obtain the monitoring data by calling the ECS API operations or after the specified instance is connected. You can use the following methods to view the vCPU utilization of ECS instances after you connect to the instances.
    • Windows instance: View the vCPU utilization in Task Manager. You can sort the tasks by vCPU utilization to find the process that is consuming the vCPU of the specified ECS instance.
    • Linux instance: Run the top command to view the vCPU utilization. To find the process that is consuming the vCPU of the specified ECS instance, press Shift+P to sort the tasks by vCPU utilization.
  • Network traffic: the bandwidth usage for the inbound and outbound traffic of the ECS instance in Kbit/s. ECS provides data connection monitoring, while CloudMonitor can monitor Internet and internal network traffic. If the outbound traffic reaches 1,024 Kbit/s and the outbound bandwidth limit is 1 Mbit/s, the outbound bandwidth for the specified ECS instance is fully utilized.

ECS monitoring service

To view the monitoring data in the ECS console, follow these steps.

  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Instances & Images > Instances.
  3. In the top navigation bar, select a region.
  4. Find the target ECS instance and click the instance ID.
  5. On the Instance Details page, view the Monitoring Information including vCPU utilization and network traffic.
    1. Click the Icon icon to specify the Start Time and End Time. The sampling interval can be up to 15 days.
      Note The specified Start Time and End Time affects the granularity of the data display. Smaller sampling intervals result in finer granularity of data displayed. For example, the average values for monitoring data within one hour and six hours are different.
    2. Optional:Click Set Alert Rule and you will be directed to the CloudMonitor console. Then you can specify the vCPU utilization and network traffic alert rules. For more information, see Alarm service overview.
    3. Optional:Click More Metrics and you can view more monitoring data in the CloudMonitor console. It takes a few minutes for the monitoring data to update.
    Latest status

You can also use the ECS API operations such as DescribeInstanceMonitorData, DescribeDiskMonitorData, and DescribeEniMonitorData to query monitoring data.

The following table describes the monitoring metrics in ECS. The sampling interval for each metric is one minute.
Metric Description
Instance The ID of the instance.
vCPU The percentage of allocated ECS compute units that are currently in use on the instance.
Internal network inbound traffic The internal network traffic to your instance. Unit: Kbit/s.
Internet outbound traffic The internal network traffic from your instance. Unit: Kbit/s.
Internal network bandwidth The internal network traffic of the instance per unit time. Unit: Kbit/s.
Internet inbound traffic The Internet traffic to the instance. Unit: Kbit/s.
Internet outbound traffic The Internet traffic from the instance. Unit: Kbit/s.
Public bandwidth Internet traffic of the instance per unit time. Unit: Kbit/s.
Disk read IOPS The number of disk read operations per second.
Disk write IOPS The number of disk write operations per second.
Disk read BPS The number of bytes read from disk per second. Unit: byte/s.
Disk write BPS The number of bytes written to disk per second. Unit: byte/s.
Note
  • The differences between Kb and KB are as follows:
    • 1 byte = 8 bits (1B = 8b).
    • If K or k indicates kilo, one Kb equals one thousand bits, while a kilobyte (KB) equals 1,024 bytes.
    • In the ECS monitoring service, network traffic is measured in Kbit/s, which is kilobit per second. Kbit/s indicates network speed, which is the number of kilobits transmitted per second. The unit bit/s is usually omitted when bandwidth is described. For example, the full form of 4 M in the bandwidth scenario is 4 Mbit/s.
  • In theory, if a network bandwidth is 1 Mbit/s, the download speed can reach 125 KB/s. Download unit conversions are as follows: 1 KB = 8 Kb, 1 Mbit/s = 125 KB/s, 1 kbit/s= 1,000 bit/s. However, some applications running on the instance consume a small amount of bandwidth, such as remote desktop programs. Therefore, the actual download speed is usually between 100 KB/s to 110 KB/s.

CloudMonitor

CloudMonitor provides one-stop and out-of-the-box monitoring solutions for enterprises in the cloud. It offers host monitoring service for your ECS instances. For more information about CloudMonitor, see Host monitoring overview. You can perform the following steps to view the monitoring data of your ECS instance in the CloudMonitor console.

  1. Log on to the CloudMonitor console.
  2. In the left-side navigation pane, click Host Monitoring.
  3. Find the target instance.
  4. Optional:If the instance has not been installed with the CloudMonitor agent, click Click to install.
  5. To obtain the monitoring data, click Monitoring Charts in the Actions column.
    Note The maximum number of days that monitoring data can be retained is 30.
  6. To set alert rules, click Alarm Rules in the Actions column.
Configure an alert rule