编程

huawei-cloud-evs-detail

试用

查询华为云 EVS 磁盘列表及监控指标(IOPS/吞吐量/延迟)的只读 Skill,基于 Huawei Cloud KooCLI

它能做什么

查询华为云 EVS 磁盘列表及监控指标(IOPS/吞吐量/延迟)的只读 Skill,基于 Huawei Cloud KooCLI

技能文档

huawei-cloud-evs-detail

华为云 EVS(弹性卷服务)详情查询 Skill,支持查询当前账号 cn-north-4 下所有云硬盘列表及监控指标(IOPS/吞吐量/延迟)。

安全硬约束

  1. 凭据管理:AK/SK 通过 hcloud CLI 的 configure 命令管理,或通过环境变量动态加载,禁止硬编码在任何脚本或配置文件中。
  2. 只读操作:本 Skill 仅执行只读查询(ListVolumes / ShowMetricData),不执行任何创建、修改、删除操作。
  3. 超时控制:所有 CLI 调用均设 30 秒超时。
  4. 错误处理:CLI 调用失败时需输出明确错误信息(含错误码和错误消息),不静默崩溃。
  5. 日志安全:凭据信息不得写入日志或输出。

概述

本 Skill 封装了华为云 EVS 和 CES(Cloud Eye)服务的只读 CLI 命令,提供两组核心功能:

  • 磁盘列表查询:列出当前账号 cn-north-4 下所有 EVS 云硬盘,包含 ID、名称、状态、容量、挂载信息
  • 监控指标查询:查询指定 EVS 磁盘的 IOPS(读写)、吞吐量(读写)、延迟(I/O服务时间)等监控指标

前置条件

1. hcloud CLI 安装与配置

需要安装华为云 KooCLI(hcloud)并配置 AK/SK 凭证。详细安装指南见 references/cli-installation-guide.md。

2. Python 环境

Python 3.6+(用于包装脚本)

3. IAM 权限

需要以下 IAM 权限策略:

  • evs:volumes:list
  • ces:metrics:list
  • ces:metricData:list

详见 references/iam-policies.md。

工作流

  1. 解析用户输入 -> 识别意图(list 或 metrics)
  2. 执行 CLI 命令
  3. 格式化输出
  4. 错误处理

核心命令

列出所有 EVS 磁盘

python3 scripts/huawei_cloud_evs_detail.py list

查询监控指标

python3 scripts/huawei_cloud_evs_detail.py metrics

查看能力列表

python3 scripts/huawei_cloud_evs_detail.py capability-list

Koo CLI Command Format

操作命令
列出 EVS 磁盘hcloud EVS ListVolumes --cli-region=cn-north-4 [--limit=N]
查监控指标hcloud CES ShowMetricData --cli-region=cn-north-4 --namespace=SYS.EVS --metric_name=X --dim.0=instance_id, --filter=average --period=3600 --from=T --to=T

EVS 监控指标映射

指标名说明单位
disk_device_read_requests_rate读 IOPScount/s
disk_device_write_requests_rate写 IOPScount/s
disk_device_read_bytes_rate读吞吐量bytes/s
disk_device_write_bytes_rate写吞吐量bytes/s
disk_device_service_timeI/O 服务时间(延迟)ms

KooCLI Command Format Standard

本 Skill 使用 CLI 模式,通过 hcloud 命令直接调用华为云 API:

操作命令
列出 EVS 磁盘hcloud EVS ListVolumes --cli-region=cn-north-4 [--limit=N]
查监控指标hcloud CES ShowMetricData --cli-region=cn-north-4 --namespace=SYS.EVS --metric_name=X --dim.0=instance_id, --filter=average --period=3600 --from=T --to=T

参数确认

参数说明默认值是否可配置
region华为云区域cn-north-4是(通过 --region 覆写)
--timeoutCLI 调用超时秒数30
--period监控数据粒度(秒)3600

参考文档

  • references/iam-policies.md
  • references/cli-installation-guide.md
  • references/verification-method.md
  • references/acceptance-criteria.md
  • references/dataflow-diagram.md

相关技能

Query the list of Huawei Cloud EVS (Elastic Volume Service) disks under the current tenant / project, focused on the EVS disk NAME list. Returns each disk's name, id, status and size; can also output a pure EVS name-only list. Supports filtering by status, name and pagination (limit/offset). Uses the KooCLI command `hcloud EVS ListVolumes --cli-region={region}` (primary) against the v2 API, or the huaweicloudsdkevs Python SDK (fallback). Read-only — never creates, modifies or deletes any disk. Use this skill whenever the user wants to list/inspect the EVS disks of the tenant or query the EVS disk name list, e.g. for disk inventory, daily inspection, or cost review. Triggers include: "list EVS", "EVS list", "query EVS names", "EVS name list", "云硬盘列表", "查询云硬盘", "EVS磁盘名称", "云硬盘名称", "list volumes", "list elastic volumes", "how many EVS disks".

Queries Huawei Cloud ECS (Elastic Cloud Server) resources in read-only mode. Covers ECS instances, flavors, keypairs, quotas, server groups, block devices, NICs, VNC console, launch templates, recycle bin, scheduled events, and tags. No write operations. Use this skill when the user needs to query ECS instance details, list flavors, check server status, view block devices, or inspect ECS resource attributes. Triggers include: 查询ECS, ECS实例查询, 云服务器查询, 弹性云服务器, ECS规格, ECS配额, 云服务器列表, ECS详情, query ECS, list ECS servers, show server details, ECS flavors, ECS quotas, ECS keypairs, server groups, block devices, ECS inventory, cloud server list, ecs list, ecs query, ecs show.

查询华为云 RDS 实例列表、实例详情及监控指标(CPU/内存/磁盘)的只读 Skill,基于 Huawei Cloud SDK

Queries Huawei Cloud storage resources (EVS/OBS/SFS/CBR). Covers cloud disks (volumes/snapshots/types/quotas/recycle bin), OBS buckets (ACL/metadata/notifica...

作者 huaweicloud-skills-team1 次安装

通过华为云命令行工具 hcloud 调用云监控服务 CES,查询 ECS 实例的 CPU、内存、磁盘与网络指标。

作者 huaweicloud-skills-team6 次安装

Queries the EIP (Elastic IP, 弹性公网IP) bound to a single Huawei Cloud ECS instance — given an ECS ID or ECS name, returns the associated public IP address, EIP ID, status, bandwidth and binding details, using the KooCLI `hcloud EIP ListPublicips` command (primary, filtered by `vnic.device_id`) or the huaweicloudsdkeip Python SDK (fallback). Provides a read-only per-instance EIP lookup for network troubleshooting, cost review and resource discovery. Use this skill whenever the user wants the EIP of a specific ECS. Triggers include: ECS EIP query, EIP of ECS, find ECS public IP, ECS 的EIP, 查询ECS的弹性公网IP, ECS公网IP, ECS绑定的EIP, 单个ECS的eip, 查询ECS的eip, 查看ECS的弹性IP, ECS外网IP, 获取ECS公网地址.