Queries the monitoring data of multiple elastic container instances at a time.

Description

  • Only the latest entry of monitoring data of each elastic container instance is returned.
  • You can query only the monitoring data of elastic container instances that are created after April 3, 2019 15:00:00 UTC+8.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeMultiContainerGroupMetric

The operation that you want to perform. Set the value to DescribeMultiContainerGroupMetric.

RegionId String Yes cn-hangzhou

The region ID of the elastic container instances.

ContainerGroupIds String Yes ["eci-2zegym1qhbmdfr1s****","eci-2ze39w5svzj5ic34****"]

A JSON array that consists of the IDs of the elastic container instances. A maximum of 20 IDs are supported. Separate the IDs with commas (,).

ResourceGroupId String No rg-acfmzw2jz2z****

The ID of the resource group to which the instances belong.

MetricType String No summary

The type of the monitoring data. Set the value to summary, which indicates that records are returned.

Response parameters

Parameter Type Example Description
RequestId String B8756BA0-6452-419C-9727-37A6209C85E0

The ID of the request.

MonitorDatas Array of Record

The collection of monitoring data of the elastic container instances.

Records Array of PodStat

The details about monitoring data.

Network Object

The monitoring data of the network.

Interfaces Array of Interface

The monitoring data of network interface controllers (NICs).

RxErrors Long 0

The number of receipt errors.

TxDrops Long 0

The number of packets that fail to arrive at their destination.

TxBytes Long 1381805699

The total number of bytes sent.

RxPackets Long 4800583

The total number of packets received.

TxPackets Long 5158427

The total number of packets sent.

Name String eth0

The name of the NIC.

TxErrors Long 0

The total number of sending errors.

RxBytes Long 505001954

The total number of bytes received.

RxDrops Long 0

The number of packets that fail to be received.

CPU Object

The monitoring data of vCPUs.

UsageNanoCores Long 0

The vCPU usage in the sampling window. Unit for the sampling window: nanoseconds.

Limit Long 2000

The upper limit of vCPU usage. The calculation formula for this parameter: The number of vCPUs × 1000.

UsageCoreNanoSeconds Long 70769883

The cumulative usage of vCPUs.

Load Long 0

The average load in the last 10 seconds.

Disk Array of DiskStats

The monitoring data of disks.

WriteBytes Long 1375109120

The amount of data that was written to the disk. Unit: bytes.

Device String /dev/vda

The name of the disk.

WriteIo Long 123

This parameter is unavailable.

ReadBytes Long 210714112

The amount of data that was read from the disk. Unit: bytes.

ReadIo Long 123

This parameter is unavailable.

Timestamp String 2019-12-19T02:31:54Z

The time when the entry of monitoring data was collected. The time follows the RFC 3339 format.

Memory Object

The monitoring data of the memory.

Rss Long 1593344

The size of the resident memory set, which indicates the size of the physical memory that is actually used. Unit: bytes.

UsageBytes Long 11153408

The size of the used memory. Unit: bytes.

WorkingSet Long 5521408

The usage of the working set. Unit: bytes.

AvailableBytes Long 4289445888

The size of the available memory. Unit: bytes.

Cache Long 7028736

The size of the cache. Unit: bytes.

Containers Array of Container

The monitoring data of containers.

CPU Object

The vCPU monitoring data of the container.

UsageNanoCores Long 0

The vCPU usage in the sampling window. Unit for the sampling window: nanoseconds.

Limit Long 321234

The upper limit of vCPU usage. The calculation formula for this parameter: The number of vCPUs × 1000.

UsageCoreNanoSeconds Long 40876694

The cumulative usage of vCPUs.

Load Long 12341

The average load in the last 10 seconds.

Memory Object

The memory monitoring data of the container.

Rss Long 9289728

The size of the resident memory set, which indicates the size of the physical memory that is actually used. Unit: bytes.

UsageBytes Long 9289728

The size of the used memory. Unit: bytes.

WorkingSet Long 9289728

The usage of the working set. Unit: bytes.

AvailableBytes Long 4285091840

The size of the available memory. Unit: bytes.

Cache Long 9289728

The size of the cache. Unit: bytes.

Name String test1

The name of the container.

Filesystem Array of FsStats

The monitoring data of file system partitions.

Capacity Long 41610981376

The total size of space.

Available Long 35319836672

The size of the available space.

FsName String /dev/root

The name of the partition.

Usage Long 4368744448

The size of used space.

ContainerGroupId String eci-bp15oolgorelvhfb****

The ID of the elastic container instance.

Examples

Sample requests

https://eci.aliyuncs.com/?Action=DescribeMultiContainerGroupMetric
&ContainerGroupIds=["eci-bp17gw49eu09yiwm****","eci-bp15oolgorelvhfb****"]
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeMultiContainerGroupMetricResponse>
    <RequestId>3BB0E196-5882-4038-BE05-D0765CA13236</RequestId>
    <MonitorDatas>
        <ContainerGroupId>eci-2zegym1qhbmdfr1s****</ContainerGroupId>
        <Records>
            <Memory>
                <UsageBytes>4005888</UsageBytes>
                <Rss>1413120</Rss>
                <AvailableBytes>4291596288</AvailableBytes>
                <WorkingSet>3371008</WorkingSet>
                <Cache>0</Cache>
            </Memory>
            <Network>
                <Interfaces>
                    <RxPackets>1822804</RxPackets>
                    <TxDrops>0</TxDrops>
                    <RxDrops>0</RxDrops>
                    <TxErrors>0</TxErrors>
                    <RxErrors>0</RxErrors>
                    <TxPackets>1694857</TxPackets>
                    <RxBytes>660431995</RxBytes>
                    <TxBytes>410762742</TxBytes>
                    <Name>eth0</Name>
                </Interfaces>
            </Network>
            <Containers>
                <Memory>
                    <UsageBytes>2854912</UsageBytes>
                    <Rss>1355776</Rss>
                    <AvailableBytes>0</AvailableBytes>
                    <WorkingSet>2842624</WorkingSet>
                    <Cache>0</Cache>
                </Memory>
                <CPU>
                    <UsageCoreNanoSeconds>37824896</UsageCoreNanoSeconds>
                    <Load>0</Load>
                    <Limit>0</Limit>
                    <UsageNanoCores>0</UsageNanoCores>
                </CPU>
                <Name>nginx</Name>
            </Containers>
            <CPU>
                <UsageCoreNanoSeconds>72555191</UsageCoreNanoSeconds>
                <Load>0</Load>
                <Limit>2000</Limit>
                <UsageNanoCores>0</UsageNanoCores>
            </CPU>
            <Filesystem>
                <Usage>37130240</Usage>
                <FsName>/dev/vda2</FsName>
                <Capacity>511647744</Capacity>
                <Available>436940800</Available>
            </Filesystem>
            <Disk>
                <WriteIo>0</WriteIo>
                <Device>/dev/vda</Device>
                <ReadIo>0</ReadIo>
                <ReadBytes>273759744</ReadBytes>
                <WriteBytes>2066857984</WriteBytes>
            </Disk>
            <Timestamp/>
        </Records>
    </MonitorDatas>
    <MonitorDatas>
        <ContainerGroupId>eci-2ze39w5svzj5ic34****</ContainerGroupId>
        <Records>
            <Memory>
                <UsageBytes>6463488</UsageBytes>
                <Rss>3149824</Rss>
                <AvailableBytes>4289142784</AvailableBytes>
                <WorkingSet>5824512</WorkingSet>
                <Cache>0</Cache>
            </Memory>
            <Network>
                <Interfaces>
                    <RxPackets>1764600</RxPackets>
                    <TxDrops>0</TxDrops>
                    <RxDrops>0</RxDrops>
                    <TxErrors>0</TxErrors>
                    <RxErrors>0</RxErrors>
                    <TxPackets>1641017</TxPackets>
                    <RxBytes>596649892</RxBytes>
                    <TxBytes>406628708</TxBytes>
                    <Name>eth0</Name>
                </Interfaces>
            </Network>
            <Containers>
                <Memory>
                    <UsageBytes>5242880</UsageBytes>
                    <Rss>3149824</Rss>
                    <AvailableBytes>0</AvailableBytes>
                    <WorkingSet>5230592</WorkingSet>
                    <Cache>0</Cache>
                </Memory>
                <CPU>
                    <UsageCoreNanoSeconds>119544335</UsageCoreNanoSeconds>
                    <Load>0</Load>
                    <Limit>0</Limit>
                    <UsageNanoCores>0</UsageNanoCores>
                </CPU>
                <Name>nginx</Name>
            </Containers>
            <CPU>
                <UsageCoreNanoSeconds>162459172</UsageCoreNanoSeconds>
                <Load>0</Load>
                <Limit>2000</Limit>
                <UsageNanoCores>0</UsageNanoCores>
            </CPU>
            <Filesystem>
                <Usage>37130240</Usage>
                <FsName>/dev/vda2</FsName>
                <Capacity>511647744</Capacity>
                <Available>436940800</Available>
            </Filesystem>
            <Disk>
                <WriteIo>0</WriteIo>
                <Device>/dev/vda</Device>
                <ReadIo>0</ReadIo>
                <ReadBytes>279165440</ReadBytes>
                <WriteBytes>2090905600</WriteBytes>
            </Disk>
            <Timestamp/>
        </Records>
    </MonitorDatas>
</DescribeMultiContainerGroupMetricResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "3BB0E196-5882-4038-BE05-D0765CA13236",
  "MonitorDatas" : [ {
    "ContainerGroupId" : "eci-2zegym1qhbmdfr1s****",
    "Records" : [ {
      "Memory" : {
        "UsageBytes" : 4005888,
        "Rss" : 1413120,
        "AvailableBytes" : 4291596288,
        "WorkingSet" : 3371008,
        "Cache" : 0
      },
      "Network" : {
        "Interfaces" : [ {
          "RxPackets" : 1822804,
          "TxDrops" : 0,
          "RxDrops" : 0,
          "TxErrors" : 0,
          "RxErrors" : 0,
          "TxPackets" : 1694857,
          "RxBytes" : 660431995,
          "TxBytes" : 410762742,
          "Name" : "eth0"
        } ]
      },
      "Containers" : [ {
        "Memory" : {
          "UsageBytes" : 2854912,
          "Rss" : 1355776,
          "AvailableBytes" : 0,
          "WorkingSet" : 2842624,
          "Cache" : 0
        },
        "CPU" : {
          "UsageCoreNanoSeconds" : 37824896,
          "Load" : 0,
          "Limit" : 0,
          "UsageNanoCores" : 0
        },
        "Name" : "nginx"
      } ],
      "CPU" : {
        "UsageCoreNanoSeconds" : 72555191,
        "Load" : 0,
        "Limit" : 2000,
        "UsageNanoCores" : 0
      },
      "Filesystem" : [ {
        "Usage" : 37130240,
        "FsName" : "/dev/vda2",
        "Capacity" : 511647744,
        "Available" : 436940800
      } ],
      "Disk" : [ {
        "WriteIo" : 0,
        "Device" : "/dev/vda",
        "ReadIo" : 0,
        "ReadBytes" : 273759744,
        "WriteBytes" : 2066857984
      } ],
      "Timestamp" : ""
    } ]
  }, {
    "ContainerGroupId" : "eci-2ze39w5svzj5ic34****",
    "Records" : [ {
      "Memory" : {
        "UsageBytes" : 6463488,
        "Rss" : 3149824,
        "AvailableBytes" : 4289142784,
        "WorkingSet" : 5824512,
        "Cache" : 0
      },
      "Network" : {
        "Interfaces" : [ {
          "RxPackets" : 1764600,
          "TxDrops" : 0,
          "RxDrops" : 0,
          "TxErrors" : 0,
          "RxErrors" : 0,
          "TxPackets" : 1641017,
          "RxBytes" : 596649892,
          "TxBytes" : 406628708,
          "Name" : "eth0"
        } ]
      },
      "Containers" : [ {
        "Memory" : {
          "UsageBytes" : 5242880,
          "Rss" : 3149824,
          "AvailableBytes" : 0,
          "WorkingSet" : 5230592,
          "Cache" : 0
        },
        "CPU" : {
          "UsageCoreNanoSeconds" : 119544335,
          "Load" : 0,
          "Limit" : 0,
          "UsageNanoCores" : 0
        },
        "Name" : "nginx"
      } ],
      "CPU" : {
        "UsageCoreNanoSeconds" : 162459172,
        "Load" : 0,
        "Limit" : 2000,
        "UsageNanoCores" : 0
      },
      "Filesystem" : [ {
        "Usage" : 37130240,
        "FsName" : "/dev/vda2",
        "Capacity" : 511647744,
        "Available" : 436940800
      } ],
      "Disk" : [ {
        "WriteIo" : 0,
        "Device" : "/dev/vda",
        "ReadIo" : 0,
        "ReadBytes" : 279165440,
        "WriteBytes" : 2090905600
      } ],
      "Timestamp" : ""
    } ]
  } ]
}

Error codes

For a list of error codes, visit the API Error Center.