<Huawei>u t m
Info: Current terminal monitor is off.
<Huawei>sys
Enter system view, return user view with Ctrl+Z.
[Huawei]sys R1
[R1]int g 0/0/0
[R1-GigabitEthernet0/0/0]ip add 192.168.100.254 24
[R1-GigabitEthernet0/0/0]int g0/0/1
[R1-GigabitEthernet0/0/1]ip add 192.168.1.254 24
[R1-GigabitEthernet0/0/1]int g 0/0/2
[R1-GigabitEthernet0/0/2]ip add 192.168.2.254 24
[R1-GigabitEthernet0/0/2]q
如此一来,全网互通
3.配置ACL
R1上配置:
[R1]acl 2000
[R1-acl-basic-2000]rule ?
INTEGER<0-4294967294> ID of ACL rule
deny Specify matched packet deny
permit Specify matched packet permit
[R1-acl-basic-2000]rule 10 ?
deny Specify matched packet deny
description Specify rule description
permit Specify matched packet permit
[R1-acl-basic-2000]rule 10 deny source 192.168.1.1 0.0.0.255
[R1-acl-basic-2000]q
[R1]int g 0/0/0
[R1-GigabitEthernet0/0/0]traffic-filter ?
inbound Apply ACL to the inbound direction of the interface
outbound Apply ACL to the outbound direction of the interface
[R1-GigabitEthernet0/0/0]traffic-filter outbound ?
acl Specify ACL to match
ipv6 Specify IPv6
[R1-GigabitEthernet0/0/0]traffic-filter outbound acl 2000