Skip to content

Alibaba Cloud ECS

The displayed Metrics of Alibaba Cloud ECS include CPU utilization, memory utilization, network bandwidth, and disk IOPS, which reflect the computing, memory, network, and storage performance of ECS instances.

Configuration

Install Func

It is recommended to enable TrueWatch Integration - Extensions - DataFlux Func (Automata)

For self-deployment of Func, refer to Self-deployment of Func

Enable Script

Note: Please prepare the Alibaba Cloud AK with the required permissions in advance (for simplicity, you can directly grant the global read-only permission ReadOnlyAccess)

Enable Script for DataFlux Func (Automata)

  1. Log in to the TrueWatch console
  2. Click the 【Integration】 menu and select 【Cloud Account Management】
  3. Click 【Add Cloud Account】, select 【Alibaba Cloud】, and fill in the required information on the interface. If the cloud account information has been configured before, ignore this step
  4. Click 【Test】, and after the test is successful, click 【Save】. If the test fails, please check if the relevant configuration information is correct and test again
  5. Click 【Cloud Account Management】 to see the added cloud account in the list, and click the corresponding cloud account to enter the details page
  6. Click the 【Integration】 button on the cloud account details page, find Alibaba Cloud ECS under the Not Installed list, and click the 【Install】 button to pop up the installation interface for installation.

Manually Enable Script

  1. Log in to the Func console, click 【Script Market】, enter the TrueWatch script market, and search for: integration_alibabacloud_ecs

  2. After clicking 【Install】, enter the corresponding parameters: Alibaba Cloud AK ID, AK Secret, and account name.

  3. Click 【Deploy Startup Script】, the system will automatically create the Startup script set and automatically configure the corresponding startup scripts.

  4. After enabling, you can see the corresponding automatic trigger configuration in 「Management / Automatic Trigger Configuration」. Click 【Execute】 to execute it immediately without waiting for the scheduled time. After a while, you can check the execution task records and corresponding logs.

Verification

  1. Confirm in 「Management / Automatic Trigger Configuration」 whether the corresponding task has the corresponding automatic trigger configuration, and you can also check the corresponding task records and logs to see if there are any exceptions
  2. In TrueWatch, check if there is asset information in 「Infrastructure / Custom」
  3. In TrueWatch, check if there is corresponding monitoring data in 「Metrics」

Metrics

After configuring Alibaba Cloud CloudMonitor, the default Measurement is as follows. More Metrics can be collected through configuration Alibaba Cloud CloudMonitor Metrics Details

Note: The monitoring plugin needs to be installed in the Aliyun ECS console

Metric Description Type Unit
CPUUtilization CPU utilization float %
memory_usedutilization Memory utilization float %
load_1m load.1m float count
load_15m load.15m float count
load_5m load.5m float count
DiskReadBPS All disk read BPS float bytes/s
DiskWriteBPS All disk write BPS float bytes/s
DiskReadIOPS All disk read operations per second float Count/Second
DiskWriteIOPS All disk write operations per second float Count/Second
disk_readiops Disk read operations per second float Count/Second
disk_writeiops Disk write operations per second float Count/Second
diskusage_utilization Host.diskusage.utilization float %
fs_inodeutilization (Agent)fs.inode.utilization_device float %
GroupVPC_PublicIP_InternetInRate IP dimension public network inbound bandwidth float bits/s
GroupVPC_PublicIP_InternetOutRate IP dimension public network outbound bandwidth float bits/s
IntranetInRate Intranet inbound bandwidth float bits/s
IntranetOutRate Intranet outbound bandwidth float bits/s
concurrentConnections Concurrent connections float count
cpu_wait (Agent)cpu.wait float %
cpu_user (Agent)cpu.user float %
cpu_system (Agent)cpu.total float %
memory_freeutilization (Agent)memory.free.utilization float %
disk_readbytes (Agent)disk.read.bytes_device float bytes/s
disk_writebytes (Agent)disk.write.bytes_device float bytes/s
networkin_rate (Agent)network.in.rate_device float bits/s
networkin_packages (Agent)network.in.packages_device float Count/s
net_tcpconnection (Agent)network.tcp.connection_state float Count
memory_freespace (Agent)memory.free.space float bytes
memory_usedspace (Agent)memory.free.space float bytes
memory_totalspace (Agent)memory.total.space float bytes

Object

The collected Alibaba Cloud ECS object data structure can be seen in 「Infrastructure - Custom」

{
  "measurement": "aliyun_ecs",
  "tags": {
    "name"                     : "i-xxxxx",
    "HostName"                 : "xxxxx",
    "InstanceName"             : "xxxxx",
    "InstanceId"               : "i-xxxxx",
    "RegionId"                 : "cn-hangzhou",
    "ZoneId"                   : "cn-hangzhou-a",
    "InstanceChargeType"       : "PrePaid",
    "InternetChargeType"       : "PayByTraffic",
    "OSType"                   : "linux",
    "PublicIpAddress_IpAddress": "['xxxx',]",
    "InstanceType"             : "ecs.c6.xlarge",
    "InstanceTypeFamily"       : "ecs.c6",
    "Status"                   : "Running"
  },
  "fields": {
    "CreationTime"           : "2022-01-01T00:00Z",
    "StartTime"              : "2022-01-02T00:00Z",
    "ExpiredTime"            : "2023-01-01T00:00Z",
    "disks"                  : "[ {associated disk JSON data}, ... ]",
    "network_interfaces"     : "[ {associated network interface JSON data}, ... ]",
    "instance_renew_attribute": "[ {auto-renew JSON data}, ...]",
    "instances_full_status"  : "[ {full status information JSON data}, ...]",
    "OperationLocks"         : "[ {lock reason JSON data}, ...]",
    "Memory"                 : "8192",
    "Cpu"                    : "4",
    "InternetMaxBandwidthOut": "0",
    "InternetMinBandwidthIn" : "0",
    "AutoReleaseTime"        : "xxxx",
    "message"                : "{instance JSON data}"
  }
}