
# CFW支持的监控指标
#### 功能说明
本节定义了云防火墙上报云监控服务的监控指标的命名空间，监控指标列表和维度定义，用户可以通过云监控服务提供管理控制台或API接口来检索云防火墙产生的监控指标和告警信息。
#### 命名空间
SYS.CFW
![](https://support.huaweicloud.com/usermanual-cfw/public_sys-resources/note_3.0-zh-cn.png)
命名空间是对一组资源和对象的抽象整合。在同一个集群内可创建不同的命名空间，不同命名空间中的数据彼此隔离。使得它们既可以共享同一个集群的服务，也能够互不干扰。
#### 约束与限制
以下指标仅"华北-乌兰察布一"、"中国-香港"、"华东-上海一"支持：
- internet_protection_traffic
- vpc_protection_traffic
- internet_protection_traffic_inbound
- internet_protection_traffic_outbound
- ips_allow_count
 
#### 监控指标
[表1]是旧版指标，建议优先使用[表2]中指标。
 表1云防火墙服务支持的监控指标（不建议使用） 
| 指标ID                       | 指标名称    | 指标含义                                                                           | 取值范围                                        | 单位   | 进制       | 维度             | 监控周期（原始指标） |
|:---|:---|:---|:---|:---|:---|:---|:---|
| used_protection_bandwidth  | 防护带宽使用量 | 该指标用于统计近5分钟内CFW检测到的互联网带宽使用量。                                                   | ≥ 0 值类型：Float  | KB/s | 1000(SI) | fw_instance_id | 5分钟        |
| protection_bandwidth_usage | 防护带宽使用率 | 该指标用于统计5分钟内CFW检测到的互联网带宽使用率。 采集方式：带宽使用量/防火墙带宽配额的占比。 | ≥ 0 值类型：Float | 百分比  | 不涉及      | fw_instance_id | 5分钟        |
   
 表2云防火墙服务支持的监控指标 
| 指标ID                                              | 指标名称        | 指标含义                           | 取值范围                                          | 单位                                                                                                                                                                                                                                                                                                                      | 进制       | 维度             | 监控周期（原始指标） |
|:---|:---|:---|:---|:---|:---|:---|:---|
| internet_protection_bandwidth_usage               | 互联网防护带宽使用量  | 该指标为防火墙互联网防护对象带宽使用量。           | ≥ 0 值类型：Float    | Bit/s                                                                                                                                                                                                                                                                                                                   | 1000(SI) | fw_instance_id | 每分钟        |
| vpc_protection_bandwidth_usage                    | VPC间防护带宽使用量 | 该指标为防火墙VPC间防护对象带宽使用量。          | ≥ 0 值类型：Float   | Bit/s                                                                                                                                                                                                                                                                                                                   | 1000(SI) | fw_instance_id | 每分钟        |
| internet_protection_bandwidth_usage_rate          | 互联网防护带宽使用率  | 该指标为防火墙互联网防护对象带宽使用率。           | ≥ 0 值类型：Float   | %                                                                                                                                                                                                                                                                                                                       | 不涉及      | fw_instance_id | 每分钟        |
| vpc_protection_bandwidth_usage_rate               | VPC间防护带宽使用率 | 该指标为防火墙VPC间防护对象带宽使用率。          | ≥ 0 值类型：Float   | %                                                                                                                                                                                                                                                                                                                       | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_pps                           | 防火墙互联网方向pps | 该指标为防火墙互联网防护对象pps。             | ≥ 0 值类型：Float   | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| vpc_protection_pps                                | 防火墙VPC间pps  | 该指标为防火墙VPC间防护对象pps。            | ≥ 0 值类型：Float   | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| ips_hit_count                                     | IPS规则命中次数   | 该指标为流量命中IPS规则的次数。              | ≥ 0 值类型：Int    | 次                                                                                                                                                                                                                                                                                                                       | 不涉及      | fw_instance_id | 每分钟        |
| ips_deny_count                                    | IPS规则阻断次数   | 该指标为流量被IPS规则阻断的次数。             | ≥ 0 值类型：Int    | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| acl_hit_count                                     | ACL规则命中次数   | 该指标为流量命中ACL规则的次数。              | ≥ 0 值类型：Int     | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| acl_deny_count                                    | ACL规则阻断次数   | 该指标为流量被ACL模块阻断的次数。             | ≥ 0 值类型：Int     | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_bandwidth_usage_inbound       | 入网防护带宽      | 该指标为防火墙互联网防护对象入方向带宽大小。         | ≥ 0 值类型：Float   | Bit/s                                                                                                                                                                                                                                                                                                                   | 1000(SI) | fw_instance_id | 每分钟        |
| internet_protection_bandwidth_usage_outbound      | 出网防护带宽      | 该指标为防火墙互联网防护对象出方向带宽大小。         | ≥ 0 值类型：Float    | Bit/s                                                                                                                                                                                                                                                                                                                   | 1000(SI) | fw_instance_id | 每分钟        |
| internet_protection_bandwidth_usage_rate_inbound  | 入网防护带宽使用率   | 该指标为防火墙互联网防护对象入方向带宽/互联网边界防护带宽。 | ≥ 0 值类型：Float   | %                                                                                                                                                                                                                                                                                                                       | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_bandwidth_usage_rate_outbound | 出网防护带宽使用率   | 该指标为防火墙互联网防护对象带宽出方向使用率。        | ≥ 0 值类型：Float  | %                                                                                                                                                                                                                                                                                                                       | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_pps_inbound                   | 入网pps       | 该指标为访问防火墙互联网防护对象pps。           | ≥ 0 值类型：Float   | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_pps_outbound                  | 出网pps       | 该指标为防火墙互联网防护对象访问外网pps。         | ≥ 0 值类型：Float   | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
| internet_protection_traffic                       | 互联网防护流量     | 该指标为防火墙互联网防护对象流量大小。            | ≥ 0 值类型：Float  | - KB  - MB  - GB  - Byte   | 1000(SI) | fw_instance_id | 每分钟        |
| vpc_protection_traffic                            | VPC间防护流量    | 该指标为防火墙VPC间防护对象流量大小。           | ≥ 0 值类型：Float    | - KB  - MB  - GB  - Byte              | 1000(SI) | fw_instance_id | 每分钟        |
| internet_protection_traffic_inbound               | 互联网入网防护流量   | 该指标为防火墙互联网防护对象的入方向流量大小。        | ≥ 0 值类型：Float     | - KB  - MB  - GB  - Byte       | 1000(SI) | fw_instance_id | 每分钟        |
| internet_protection_traffic_outbound              | 互联网出网防护流量   | 该指标为防火墙互联网防护对象的出方向流量大小。        | ≥ 0 值类型：Float | - KB  - MB  - GB  - Byte            | 1000(SI) | fw_instance_id | 每分钟        |
| ips_allow_count                                   | IPS规则放通次数   | 该指标为流量被IPS规则放通的次数。             | ≥ 0 值类型：int     | count                                                                                                                                                                                                                                                                                                                   | 不涉及      | fw_instance_id | 每分钟        |
   
#### 维度
| Key            | Value                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
|:---|:---|
| fw_instance_id | 防火墙ID，是创建防火墙后用于标志防火墙由系统自动生成的标志ID。 该值可通过云防火墙服务的"[查询防火墙列表](https://support.huaweicloud.com/api-cfw/ListFirewallList.html)"获取。 - 默认情况下，fw_instance_Id为空时，返回账号下第一个墙的信息；fw_instance_Id非空时，返回与fw_instance_Id对应墙的信息。  - 若object_Id非空，默认返回object_Id对应墙的信息；填写时object_Id需要属于fw_instance_Id对应的墙。   |
   
