首页/网络/网络设备配置速查/H3C 基本 ACL:acl basic 与规则编号
ACL 与安全65 条

H3C 基本 ACL:acl basic 与规则编号

H3C Comware V7 用 acl basic 2000 创建基本 ACL,规则以 rule ID 从小到大匹配,默认步长为 5,便于后续插入。

网络设备配置速查网络更新于 2026-10-12
场景源地址过滤
适用H3C Comware V7/V5 交换机与路由器
命令族acl basic + rule + packet-filter

H3C Comware

H3C Comware
acl basic 2000
 rule 0 permit source 192.168.10.0 0.0.0.255
 rule 5 deny   source any
interface GigabitEthernet1/0/1
 packet-filter 2000 inbound
display acl 2000

华为 VRP

华为 VRP
acl number 2000
 rule 0 permit source 192.168.10.0 0.0.0.255
 rule 5 deny   source any

思科 IOS

思科 IOS
access-list 10 permit 192.168.10.0 0.0.0.255
! 思科不写 deny any,末尾隐式拒绝其余
差异:H3C 的 rule 必须带动作参数(permit/deny)否则报错;规则 ID 步长可用 step 调整(默认 5),与华为一致,思科编号 ACL 没有 step 概念。

易错点

  • Comware V5 与 V7 的 acl 子视图提示符不同,老教材上的写法在新版本上要重新核对

数据来源与参考

  • H3C Comware V7 ACL 命令参考(acl basic、rule、step)
  • 华为 VRP 基本 ACL 配置
  • Cisco IOS ACL 配置指南

相关工具

​‌‌​​‌​​​‌‌​‌‌‌‌​‌‌​​​‌‌​‌‌‌​​‌‌​​‌​‌‌‌​​‌‌‌​​​‌​‌‌​‌​​‌​‌‌‌​​​‌​‌‌​‌​​‌​‌‌​​​‌‌​‌‌‌​‌​​​‌‌​‌‌‌‌​​‌​‌‌‌​​‌‌​​​‌‌​‌‌​‌‌‌‌​‌‌​‌‌​‌