In our last post we took a look at Option A where we had back to back VRF exchange.
In this post we will take a look at Option B or VPN-IPv4 Address exchange. In human terms, instead of VRF to VRF connectivity, we will form an EBGP VPNv4 peering between R1 and XR1. We will eliminate the VRFs on the PE to PE connection. At this point we have a working solution that I will show verification of toward the end. I won't be rebuilding the IGP/LDP/VPNv4 iBGP connectivity but just modifying the PE to PE connectivity.
Check this link to see the previous post and the link to the configuration.
MPLS L3 VPN Option A
So first things first, the PE to PE connectivity:
We need to remove the VRFs from the interfaces, the VRF aware IGP processes.
R1
conf t
no ip vrf A
no ip vrf B
no ip vrf C
!
int g2.100
encap dot1q 100
ip add 20.100.0.1 255.255.255.0
XR1
conf t
int g0/0/0/0.100
no ip add
int g0/0/0/0.200
no ip add
int g0/0/0/0.300
no ip add
commit
!
int g0/0/0/0.100
encap dot1q 100
ip add 20.100.0.19/24
no int g0/0/0/0.200
no int g0/0/0/0.300
commit
router ospf 1
no vrf A
no router eigrp 1
no router rip
commit
router bgp 2
no vrf A
no vrf B
no vrf C
commit
This should remove all of the VRF aware configuration.
Now to setup the BGP VPNv4 EBGP peerings
R1
router bgp 1
neighbor 20.100.0.19 remote-as 2
address-family vpnv4
neighbor 20.100.0.19 activate
XR1
conf t
route-policy PASS
pass
end-policy
!
router bgp 2
address-family ipv4 unicast
!
address-family vpnv4 unicast
!
neighbor 20.100.0.1
remote-as 1
address-family vpnv4 unicast
route-policy PASS in
route-policy PASS out
Because this is VPNv4 over BGP we need to make sure that the LSP are maintained end to end
There are a couple things that need to be done. First the PEs don't have VRFs configured any more so by default we won't be receiving VPNv4 updates. We need to tell IOS and IOS XR to accept updates.
IOS
R1
router bgp 1
no bgp default route-target filter
IOS XR
router bgp 2
address-family vpnv4 unicast
retain route-target all
This enables the extended communities to be received and maintained even if there are route target import values configured since there aren't VRFs on the R1 or XR1.
The second thing that needs to be done is R1 needs to advertise BGP labels to XR1. XR1 needs to have a way to send BGP Labels to R1. By default R1 will issue the mpls bgp forwarding command to enable label advertisement on the G2.100 interface. To enable MPLS forwarding on directly connected loopback interfaces. XR1 by default doesn't inject a /32 host route to the next hop of R1 and doesn't generate a label for that. So XR1 needs to configure a static host route to R1
R1
interface GigabitEthernet2.100
mpls bgp forwarding
show mpls forwarding-table
24 Pop Label 20.100.0.19/32 0 Gi2.100 20.100.0.19
XR1
router static
address-family ipv4 unicast
20.100.0.1/32 GigabitEthernet0/0/0/0.100
sh route
S 20.100.0.1/32 is directly connected, 02:44:15, GigabitEthernet0/0/0/0.100
show mpls forwarding-table
24018 Pop 20.100.0.1/32 Gi0/0/0/0.100 20.100.0.1
The next step in the process is to look at the Route reflectors, R2 and XR2 respectively. By default, they will receive BGP VPNv4 updates from R1 and XR1 respectively and have the next hop set to the address used to form the BGP peering. R2 will have a next hop of XR1 20.100.0.19 and XR2 will have a next of R1 20.100.0.1. From R2 and XR2s perspective, these next hop values are unreachable. We need to change the next hop value for both R2 and XR2, R2 will see R1 and XR2 will see XR1.
R1
router bgp 1
address-family vpnv4
neighbor 2.2.2.2 next-hop-self
XR1
router bgp 2
neighbor 20.20.20.20
remote-as 2
update-source Loopback0
address-family vpnv4 unicast
next-hop-self
At this point we should be in pretty good shape. All the work has been on the PEs of R1 and XR1. So let's test connectivity.
R9 to R12
R9#traceroute 12.12.12.12 source 9.9.9.9 num
Type escape sequence to abort.
Tracing the route to 12.12.12.12
VRF info: (vrf in name/id, vrf out name/id)
1 30.4.9.4 16 msec 9 msec 6 msec
2 20.3.4.3 [MPLS: Labels 16/30 Exp 0] 221 msec 114 msec 110 msec
3 20.1.3.1 [MPLS: Label 30 Exp 0] 103 msec 113 msec 86 msec
4 20.100.0.19 [MPLS: Label 24009 Exp 0] 78 msec 72 msec 62 msec
5 20.6.19.6 [MPLS: Labels 18/24 Exp 0] 85 msec 71 msec 70 msec
6 30.5.12.5 [MPLS: Label 24 Exp 0] 77 msec 88 msec 47 msec
7 30.5.12.12 99 msec * 72 msec
As you can see, in Option A, Hop 4 would have been native IP since it was VRF to VRF. Now that we are allocating a label to that peering we have an LSP that is end to end. We actually have 3 different LSPs, R4-R3-R1; R1-XR1; XR1-R6-XR2.
The configs:
Option B PE Configs for R1 and XR1
No comments:
Post a Comment