access-list 100 permit ip 192.168.1.0 0.0.0.255 192.168.2.0 0.0.0.255
access-list 101 permit ip 192.168.2.0 0.0.0.255 192.168.1.0 0.0.0.255
access-list 102 deny any any
int vlan 1
ip access-group 100 out
int vlan 2
ip access-group 101 out
其他VLAN
ip access-group 102 out
用port acl实现 具体的可以看攻城狮论坛 我刚考完ccna
访问控制列表acl