取消
显示结果 
搜索替代 
您的意思是: 
cancel
公告

December 2020

December 2020

258
查看次数
5
有帮助
2
回复
yxbnet
Beginner

CISCO2921/K9 路由器双wan怎么指定某vlan通过特定的wan口上网

route-map user626 permit 11
match ip address 11
set ip next-hop 126.86.178.118

 

access-list 11 permit 192.168.11.0 0.0.0.255

 

ip policy route-map user626(应用在wan口上)

 

这样配置以后192.168.11.0网段为什么不通过指定的wan口上网,哪里配置有问题?

2 条回复2
Rps-Cheers
Rising star

建议将ip policy route-map user626配置放在LAN口一侧。例如如下的E0/0口

图像_2021-07-27_222438.png

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Rps-Cheers | If it solves your problem, please mark as answer. Thanks !
ilay
Rising star

使用PBR调整流量时需要将PBR应用到设备的入向接口,PBR优先级高于本地的路由表。你将route-map 应用到WAN接口,流量已经按照地址查完路由表决定路由走向了,直接转发出去,根本不会匹配你配置的route-map        //关于PBR可以看下英文的定义(Policy-based routing (PBR) is a process whereby the device puts packets through a route map before routing them. The route map determines which packets are routed to which device next. You might enable policy-based routing if you want certain packets to be routed some way other than the obvious shortest path

 

另外,需要注意将源地址NAT成相应wan接口的有效公网IP地址