del
netq del check-filter
从 netq check
命令中删除过滤器以重新启用事件通知。
语法
netq del check-filter
check_filter_id <text-check-filter-id>
必需参数
参数 | 值 | 描述 |
---|---|---|
check_filter_id | <text-check-filter-id> | 删除指定的验证过滤器 |
选项
无
相关命令
netq add check-filter
netq show check-filter
netq del events-config
删除事件抑制配置。当您不再希望抑制指定的事件时非常有用。考虑修改配置以禁用或暂时暂停配置。
语法
netq del events-config
events_config_id <text-events-config-id-anchor>
必需参数
参数 | 值 | 描述 |
---|---|---|
events_config_id | <text-events-config-id-anchor> | 删除具有此标识符的事件抑制配置 |
选项
无
用法示例
获取配置标识符,然后将其删除。
cumulus@switch:~$ netq show events-config events_config_id eventsconfig_1
Matching config_events records:
Events Config ID Events Config Name Message Type Scope Active Suppress Until
-------------------- -------------------- -------------------- ------------------------------------------------------------ ------ --------------------
eventsconfig_1 job_cl_upgrade_2d89c agent {"db_state":"*","hostname":"spine02","severity":"*"} True Tue Jul 7 16:16:20
21b3effd79796e585c35 2020
096d5fc6cef32b463e37
cca88d8ee862ae104d5_
spine02
eventsconfig_1 job_cl_upgrade_2d89c bgp {"vrf":"*","peer":"*","hostname":"spine04","severity":"*"} True Tue Jul 7 16:16:20
21b3effd79796e585c35 2020
096d5fc6cef32b463e37
cca88d8ee862ae104d5_
spine04
...
cumulus@switch:~$ netq del events-config events_config_id eventsconfig_10
Successfully deleted Events Config eventsconfig_10
相关命令
netq add events-config
netq show events-config
netq del notification
从事件通知配置中删除通道、过滤器、规则或代理组件。这通常在以下情况下完成:
- 您从给定的通知应用程序(Slack、PagerDuty、
syslog
或电子邮件)中停用选定的通道,并且您不再需要在 NetQ 中进行配置 - 过滤器是临时的(例如,在调试时)
- 规则不再适用
- 不再需要代理
语法
此命令有四种形式可用,每种形式对应配置的一个组件
netq del notification channel <text-channel-name-anchor>
netq del notification filter <text-filter-name-anchor>
netq del notification proxy
netq del notification rule <text-rule-name-anchor>
必需参数
参数 | 值 | 描述 |
---|---|---|
通道 | <text-channel-name-anchor> | 从事件通知配置中删除此通道 |
过滤器 | <text-filter-name-anchor> | 从事件通知配置中删除此过滤器 |
代理 | NA | 删除通知代理并将通知消息直接发送到 NetQ 设备或 VM |
规则 | <text-rule-name-anchor> | 从事件通知配置中删除此规则 |
选项
无
用法示例
删除通知通道
cumulus@switch:~$ netq del notification channel slk-netq-events
cumulus@switch:~$ netq show notification channel
Matching config_notify records:
Name Type Severity Channel Info
--------------- ---------------- ---------------- ------------------------
pd-netq-events pagerduty info integration-key: 1234567
890
删除通知规则
cumulus@switch:~$ netq del notification rule swp52
cumulus@switch:~$ netq show notification rule
Matching config_notify records:
Name Rule Key Rule Value
--------------- ---------------- --------------------
bgpHostname hostname spine-01
evpnVni vni 42
overTemp new_s_crit 24
svcStatus new_status down
switchLeaf04 hostname leaf04
sysconf configdiff updated
相关命令
netq add notification
netq show notification
netq del tca
删除基于阈值的事件通知规则。使用 netq show tca
查找事件名称。如果您希望禁用规则而不是删除它,请参阅 netq add tca
。
语法
netq del tca
tca_id <tca-rule-name>
必需参数
参数 | 值 | 描述 |
---|---|---|
tca_id | <tca-rule-name> | 删除具有此事件名称的基于阈值的规则 |
选项
无
用法示例
cumulus@switch:~$ netq del tca tca_id TCA_RXBYTES_UPPER_1
Successfully deleted TCA TCA_RXBYTES_UPPER_1
相关命令
netq add tca
netq show tca
netq del trace
删除计划的跟踪。使用 netq show trace summary
获取相关的跟踪名称。
标准用户和管理角色都可以删除计划的跟踪。删除不会生成通知。在删除计划的跟踪之前,请务必与其他用户沟通,以避免混淆和支持问题。
语法
netq del trace
<text-trace-name>
必需参数
参数 | 值 | 描述 |
---|---|---|
NA | <text-trace-name> | 删除具有此名称的计划跟踪 |
选项
无
用法示例
cumulus@switch:~$ netq show trace summary json
[
{
"job_end_time": 1605300327131,
"job_req_time": 1604424893944,
"job_start_time": 1605300318198,
"jobid": "f8d6a2c5-54db-44a8-9a5d-9d31f4e4701d",
"status": "Complete",
"status_details": "1",
"trace_name": "leaf01toborder01",
"trace_params": {
"alert_on_failure": "0",
"dst": "10.10.10.63",
"src": "10.10.10.1",
"vlan": "-1",
"vrf": ""
}
},
...
cumulus@switch:~$ netq del trace leaf01toborder01
Successfully deleted schedule trace leaf01toborder01
相关命令
netq add trace name
netq show trace summary
netq del validation
删除计划的验证。当您为故障排除创建了计划的验证并且不再需要它,或者如果您已达到最多 15 个计划的验证并且想要优先考虑一个验证而不是另一个验证时,此命令非常有用。使用相关的 netq show validation settings
命令查看现有计划验证的名称。
语法
netq del validation
<text-validation-name>
必需参数
参数 | 值 | 描述 |
---|---|---|
NA | <text-validation-name> | 删除具有此名称的计划验证 |
选项
无
用法示例
cumulus@switch:~$ netq del validation Bgp15m
Successfully deleted validation Bgp15m
相关命令
netq add validation
netq show validation settings