Description

CPU usage time(CPU Time ⇒ nsec)
The output will be nano second digits, and be calculated using formula as follows: Total hours of use for one core in a second × Number of cores

For one core : 1,000,000,000 nsec at most
For two core : 2,000,000,000 nsec at most

Request URL

Compute API v2.0

GET /v2/{tenant_id}/servers/{server_id}/rrd/cpu

Request Paramters

Parameter Value Style Description
X-Auth-Token User Token header
tenant_id URI
server_id Server ID URI
start_date_raw (Optional) Starting time (UNIX Time) query Default: 1 day ago
end_date_raw (Optional) Ending Time (UNIX Time) query Default: Current Time
mode (Optional) {average,max,min} Default: average query Mode of Data Handling

Request Json

This operation does not accept a request body.

Normal response codes

200

Example

curl -i -X GET \
-H "Accept: application/json" \
-H "X-Auth-Token: 35941e7df872405d84e5b026dba8323c" \
https://compute.tyo1.cloud.z.com/v2/1864e71d2deb46f6b47526b69c65a45d/servers/e25b3611-96df-4514-a54b-7729aec48dc1/rrd/cpu?start_date_raw=1426529435\&end_date_raw=1426532835\&mode=average
HTTP/1.1 200 OK
Date: Thu, 19 Mar 2015 01:31:26 GMT
Server: Apache
Content-Length: 1337
Content-Type: application/json

{
  "cpu": {
    "schema": [
      "unixtime",
      "value"
    ],
    "data": [
      [
        1426529500,
        1468000
      ],
      [
        1426530000,
        1424000
      ],
(snip)
      [
        1426532500,
        1492000
      ],
      [
        1426533000,
        1424000
      ]
    ]
  }
}