Administrator Guide
4 Congure the export target in the source VRF with route-map export_ospfbgp_protocol.
ip route-export 1:1 export_ospfbgp_protocol
5 Congure VRF-blue.
ip vrf vrf-blue
interface-type slot/port
ip vrf forwarding VRF-blue
ip address ip—address mask
A non-default VRF named VRF-blue is created and the interface 1/22 is assigned to it.
6 Dene the route-map import_ospf_protocol.
Dell(config)route-map import_ospf_protocol permit 10
7 Dene the matching criteria for importing routes into VRF-blue.
Dell(config-route-map)match source-protocol ospf
This action species that the route-map contains OSPF as the matching criteria for importing routes into vrf-blue.
8 Congure the import target in VRF-blue with route-map import_ospf_protociol.
ip route-import 1:1 import_ospf_protocol
When you import routes into VRF-blue using the route-map import_ospf_protocol, only OSPF routes are imported into VRF-blue. Even
though VRF-red has leaked both OSPF as well as BGP routes to be shared with other VRFs, this command imports only OSPF routes
into VRF-blue.
9 Congure the import target in the source VRF for reverse communnication with the destination VRF.
ip route-import 2:2
The show run output for the above conguration is as follows:
ip vrf vrf-Red
ip route-export 1:1 export_ospfbgp_protocol
ip route-import 2:2
! this action exports only the OSPF and BGP routes to other VRFs
!
ip vrf vrf-Blue
ip route-export 2:2
ip route-import 1:1 import_ospf_protocol
!this action accepts only OSPF routes from VRF-red even though both OSPF as well as BGP routes
are shared
The show VRF commands displays the following output:
Important Points to Remember
• Only Active routes are eligible for leaking. For example, if VRF-A has two routes from BGP and OSPF, in which the BGP route is not
active. In this scenario, the OSPF route takes precedence over BGP. Even though the Target VRF-B has specied ltering options to
match BGP, the BGP route is not leaked as that route is not active in the Source VRF.
• The export-target and import-target support only the match protocol and match prex-list options. Other options that are congured in
the route-maps are ignored.
• You can expose a unique set of routes from the Source VRF for Leaking to other VRFs. For example, in VRF-red there is no option for
exporting one set of routes (for example, OSPF) to VRF- blue and another set of routes (for example, BGP routes) to some other VRF.
Similarly, when two VRFs leak or export routes, there is no option to discretely lter leaked routes from each source VRF. Meaning, you
cannot import one set of routes from VRF-red and another set of routes from VRF-blue.
Conguring Route Leaking without Filtering Criteria
You can use the ip route-export tag command to export all the IPv4 routes corresponding to a source VRF. For leaking IPv6 routes,
use the
ipv6 route-export tag command. This action exposes source VRF's routes (IPv4 or IPv6 depending on the command that
1042
Virtual Routing and Forwarding (VRF)