API Guide

OS10(config)# interface ethernet 1/1/4-1/1/6
OS10(conf-if-eth1/1/4-1/1/6)# ip policy route-map Map1
Identifier GUID-2D95611C-F137-4377-8386-2D862BBEF1CF
Version 1
Status Translation approved
配置示例
请考虑通过属于 VRF RED VLAN40 来自源 IP 地址 1.1.1.1 入口的流量情况。此流量的出口接口也位于与 IP 地址 4.4.4.4 相同的 VRF
RED 如下所示
通过使用以下 PBR 配置您可以通过 VRF BLUE 中的下一跳 IP 地址 2.2.2.2将流量入口重新定向到可访问的目标 VRF RED
1. 创建路由映射。
OS10(config)# route-map test
2. 输入与指定访问列表匹配的 IP 地址。
OS10(config-route-map)# match ip 4.4.4.4 acl1
3. 将下一跳地址设置为 2.2.2.2通过 VRF BLUE 可以访问该地址。
OS10(config-route-map)#
OS10(config-route-map)# set ip vrf BLUE next-hop 2.2.2.2
OS10(config-route-map)# exit
4. 将此规则应用于流量入口所在的接口在此情况下是 VLAN40
OS10(config)# interface vlan 40
OS10(conf-if-vl-40)#
OS10(conf-if-vl-40)# ip policy route-map test
5. 可选查看接口上的 PBR 配置。
OS10(conf-if-vl-40)# show configuration
!
interface vlan40
no shutdown
ip policy route-map test
!
704 3