华为路由器:配置策略路由引流到旁挂设备问题(重定向)
华为路由器:配置策略路由引流到旁挂设备问题(重定向)
(1)拓扑图
(2)基本配置
R1:
interface GigabitEthernet0/0/1
ip address 192.168.22.254 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 192.168.11.254 255.255.255.0
#
ip route-static 0.0.0.0 0.0.0.0 192.168.22.1
ip route-static 172.16.1.0 255.255.255.0 192.168.22.1
ip route-static 192.168.1.0 255.255.255.0 192.168.11.1
R2:
interface GigabitEthernet0/0/0
ip address 192.168.22.1 255.255.255.0
interface GigabitEthernet0/0/2
ip address 192.168.11.1 255.255.255.0
#
interface GigabitEthernet4/0/0
ip address 172.16.1.1 255.255.255.0
#
interface GigabitEthernet4/0/1
ip address 1.1.1.1 255.255.255.0
#
interface GigabitEthernet4/0/2
ip address 192.168.1.1 255.255.255.0
traffic-policy p1 inbound
#
ip route-static 0.0.0.0 0.0.0.0 1.1.1.254
sw1:
vlan batch 6
interface Vlanif6
ip address 1.1.1.254 255.255.255.0
#
interface GigabitEthernet0/0/1
port link-type access
port default vlan 6
#
interface LoopBack1
ip address 2.2.2.2 255.255.255.255
#
interface LoopBack2
ip address 3.3.3.3 255.255.255.255
#
ip route-static 0.0.0.0 0.0.0.0 1.1.1.1
(3)配置pbr
R2:
acl number 3000
rule 10 permit ip source 192.168.1.0 0.0.0.255
#
traffic classifier c1 operator and
if-match acl 3000
#
traffic behavior b1
redirect ip-nexthop 192.168.11.254
#
traffic policy p1
classifier c1 behavior b1
#
interface GigabitEthernet4/0/2
traffic-policy p1 inbound
PC1 ping网关192.168.1.1的流量还是会转发到R1的g0/0/2接口
(4)修改下ACL
R2:
acl number 3000
rule 5 deny ip destination 2.2.2.2 0
rule 10 permit ip source 192.168.1.0 0.0.0.255
#
interface GigabitEthernet4/0/2
traffic-policy p1 inbound
PBR策略路由(列表、list、全)策略路由list、pbrlist
http://www.zh-cjh.com/wenzhangguilei/975.html
QoS服务质量(列表、list、全)qoslist
http://www.zh-cjh.com/wenzhangguilei/2180.html
文章归类、所有文章列表、LISTLIST
http://www.zh-cjh.com/wangzhangonggao/2195.html
2、本资源基本为原创,部分来源其他付费资源平台或互联网收集,如有侵权请联系及时处理。
3、本站大部分文章的截图来源实验测试环境,请不要在生产环境中随意模仿,以免带来灾难性后果。
转载请保留出处: www.zh-cjh.com珠海陈坚浩博客 » 华为路由器:配置策略路由引流到旁挂设备问题(重定向)
作者: cjh
手机扫一扫,手机上查看此文章: |
一切源于价值!
其他 模板文件不存在: ./template/plugins/comment/pc/index.htm