阿里云文件存储 CPFS
采集阿里云文件存储 CPFS 监控数据
配置¶
安装 Func¶
推荐开通 观测云集成 - 扩展 - 托管版 Func
如果自行部署 Func 参考自行部署 Func
开通脚本¶
提示:请提前准备好符合要求的阿里云 AK(简单起见,可直接授予全局只读权限
ReadOnlyAccess)
托管版开通脚本¶
- 登陆观测云控制台
- 点击【集成】菜单,选择【云帐号管理】
- 点击【添加云帐号】,选择【阿里云】,填写界面所需的信息,如之前已配置过云帐号信息,则忽略此步骤
- 点击【测试】,测试成功后点击【保存】,如果测试失败,请检查相关配置信息是否正确,并重新测试
- 点击【云帐号管理】列表上可以看到已添加的云账号,点击相应的云帐号,进入详情页
- 点击云帐号详情页的【集成】按钮,在
未安装列表下,找到阿里云 CPFS,点击【安装】按钮,弹出安装界面安装即可。
手动开通脚本¶
-
登陆Func 控制台,点击【脚本市场】,进入观测云脚本市场,搜索:
integration_alibabacloud_cpfs -
点击【安装】后,输入相应的参数:阿里云 AK ID 、AK Secret 及账户名。
-
点击【部署启动脚本】,系统会自动创建
Startup脚本集,并自动配置相应的启动脚本。 -
开启后可以在「管理 / 自动触发配置」里看到对应的自动触发配置。点击【执行】,即可立即执行一次,无需等待定期时间。稍等片刻,可以查看执行任务记录以及对应日志。
验证¶
- 在「管理 / 自动触发配置」确认对应的任务是否已存在对应的自动触发配置,同时可以查看对应任务记录及日志检查是否有异常
- 在观测云,「基础设施 / 自定义」中查看是否存在资产信息
- 在观测云,「指标」查看是否有对应监控数据
指标¶
文件存储 CPFS 指标在 aliyun_acs_nas 指标集下,以下是指标详情
| MetricName | 指标类型 | MetricDescribe | Dimensions | Statistics | Unit |
|---|---|---|---|---|---|
| CPFSCapacity | capacity | 总存储空间 | userId,fileSystemId | Value | B |
| CPFSCapacityUsed | capacity | 数据量 | userId,fileSystemId | Value | B |
| CPFSInodeAlloc | capacity | 已分配文件数 | userId,fileSystemId | Value | count |
| CPFSInodeLimit | capacity | 最大文件数 | userId,fileSystemId | Value | count |
| CPFSInodeUsed | capacity | 已使用文件数 | userId,fileSystemId | Value | count |
| CPFSIopsRead | performance | 读IOPS | userId,fileSystemId | Value | IOPS |
| CPFSIopsWrite | performance | 写IOPS | userId,fileSystemId | Value | IOPS |
| CPFSThruputRead | performance | 读吞吐 | userId,fileSystemId | Value | bytes/s |
| CPFSThruputWrite | performance | 写吞吐 | userId,fileSystemId | Value | bytes/s |
| ClientReadIops | performance | 客户端读 IOPS | userId,fileSystemId,hostname | Average,Minimum,Maximum | IOPS |
| ClientReadLatency | capacity | 客户端读平均延迟 | userId,fileSystemId,hostname | Average,Minimum,Maximum | B |
| ClientReadThroughput | performance | 客户端读吞吐 | userId,fileSystemId,hostname | Average,Minimum,Maximum | B/s |
| ClientWriteIops | performance | 客户端写 IOPS | userId,fileSystemId,hostname | Average,Minimum,Maximum | IOPS |
| ClientWriteLatency | performance | 客户端写平均延迟 | userId,fileSystemId,hostname | Average,Minimum,Maximum | us |
| ClientWriteThroughput | performance | 客户端写吞吐 | userId,fileSystemId,hostname | Average,Minimum,Maximum | B/s |
| FsetInodeAlloc | capacity | Fileset 已分配文件数 | userId,fileSystemId,hostname | Value | count |
| FsetInodeUsed | capacity | Fileset 已使用文件数 | userId,fileSystemId,hostname | Value | count |
| IOPSExport | performance | 数据流动导出IOPS | userId,fileSystemId | Value | IOPS |
| IOPSImport | performance | 数据流动导入IOPS | userId,fileSystemId | userId,fileSystemId | IOPS |
| LatencyExport | performance | 数据流动导出延迟 | userId,fileSystemId | Value | us |
| LatencyImport | performance | 数据流动导入延迟 | userId,fileSystemId | Value | us |
| NFSReadIOPS | performance | NFS读IOPS | userId,fileSystemId | Value | IOPS |
| NFSReadThroughput | volume | NFS读吞吐 | userId,fileSystemId | Value | bytes/s |
| NFSWriteIOPS | performance | NFS写IOPS | userId,fileSystemId | Value | IOPS |
| NFSWriteThroughput | volume | NFS写吞吐 | userId,fileSystemId | Value | bytes/s |
| QPSExportMeta | performance | 数据流动导出读取meta的QPS | userId,fileSystemId | Value | count/s |
| QPSImportMeta | performance | 数据流动导入读取meta的QPS | userId,fileSystemId | Value | count/s |
| ThroughputExport | performance | 数据流动导出吞吐 | userId,fileSystemId | Value | B/s |
| ThroughputImport | performance | 数据流动导入吞吐 | userId,fileSystemId | Value | B/s |
对象¶
采集到的阿里云文件系统 CPFS 对象数据结构, 可以从「基础设施-自定义」里看到对象数据
{
"measurement": "aliyun_cpfs",
"tags": {
"RegionId" : "i-0ec6548xxx",
"ResourceGroupId" : "cn-hangzhou",
"FileSystemId" : "cpfs-0093329e0e4xxxx",
"FileSystemType" : "cpfs",
"ZoneId" : "cn-hangzhou-j",
"Description" : "test-zp"
},
"fields": {
"VpcId" : "vpc-bp10raupoot1mkzxxxxxx",
"Status" : "Running",
"Version" : "2.3.4",
"ChargeType" : "PayAsYouGo",
"StorageType" : "advance_100",
"ProtocolType" : "standard",
"MeteredIASize" : "436207616",
"Capacity" : "3600",
"CreateTime" : "2025-10-29 14:55:03",
"Tags" : "{ Tag []}",
"MeteredSize" : "436207616",
"Bandwidth" : "360",
"SupportedFeatures" : "{ SupportedFeature[Fileset]}",
"MountTargets" : "{ MountTarget []}",
"EncryptType" : "0",
"Ldap" : "{}",
"ExpiredTime" : "1761729434674",
"Packages" : "{ Package []}",
"AccessPointCount" : "0"
}
}