更新时间:2025-09-12 GMT+08:00
分享

获取节点指标

功能介绍

获取指定实例下某个节点的指标信息,包括CPU使用率、内存使用率、磁盘使用情况等。

调用方法

请参见如何调用API

URI

GET /v1/{project_id}/instances/{instance_id}/nodes/{node_id}/metrics

表1 路径参数

参数

是否必选

参数类型

描述

instance_id

String

实例ID

node_id

String

节点ID

project_id

String

项目ID

表2 Query参数

参数

是否必选

参数类型

描述

from

String

查询指标的起始时间

period

Integer

查询指标的时间间隔

to

String

查询指标的结束时间

limit

Integer

返回结果的最大数量

offset

Integer

返回结果的偏移量

请求参数

响应参数

状态码:200

表3 响应Body参数

参数

参数类型

描述

[数组元素]

Array of InstanceMetricVo objects

实例指标信息

表4 InstanceMetricVo

参数

参数类型

描述

cpu_usage

String

CPU使用率

data_disk_free

String

数据盘空闲空间

data_disk_total

String

数据盘总空间

disk_free

String

磁盘空闲空间

disk_total

String

磁盘总空间

mem_usage

String

内存使用率

timestamp

Long

时间戳

请求示例

响应示例

状态码

状态码

描述

200

OK

401

未授权

403

禁止访问

404

未找到

错误码

请参见错误码

相关文档