Thursday, August 5, 2010

INE Vol 1 - Lab 14 - Inter-AS MPLS VPNs with Back to Back VRF

Notes:
As the title suggests, or rather blatantly states, 2 BGP ASes that are MPLS enabled with an interconnect between R2 and R4, a VPN that spans both ASes.

So how is this accomplished? R2 and R4 have dot1q trunk between them and each subinterface belongs to a separate VRF. IPV4 eBGP between them. For the purpose of trying to keep it straight and simple. R2 and R4 both seem to act as PEs and CEs at the same time. The connections between them belong to VRFs and no label distribution protocol is deployed.

For example, R2 sends all it's routes in the VRFs via ebgp (the CE-PE routing protocol) R4 then sends them to the other PE via VPNv4 routes. And vice versa, R4 sends all it's routes in the VRFs via the same eBGP (CE-PE routing protocol) connections to R2 and then R2 sends them as VPNv4 routes to the other PE in it's AS.

Config:
R2
router bgp 1
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 150.1.3.3 remote-as 1
neighbor 150.1.3.3 update-source Loopback0
neighbor 150.1.100.4 remote-as 2
neighbor 150.1.200.4 remote-as 2
!
address-family vpnv4
neighbor 150.1.3.3 activate
neighbor 150.1.3.3 send-community extended
neighbor 150.1.3.3 next-hop-self
exit-address-family
!
address-family ipv4 vrf SW2-BB2
neighbor 150.1.200.4 remote-as 2
neighbor 150.1.200.4 activate
no synchronization
exit-address-family
!
address-family ipv4 vrf SW1-BB1
neighbor 150.1.100.4 remote-as 2
neighbor 150.1.100.4 activate
no synchronization
exit-address-family

R2#sh run int f2/0.100
Building configuration...

Current configuration : 127 bytes
!
interface FastEthernet2/0.100
encapsulation dot1Q 100
ip vrf forwarding SW1-BB1
ip address 150.1.100.2 255.255.255.0
end

R2#sh run int f2/0.200
Building configuration...

Current configuration : 127 bytes
!
interface FastEthernet2/0.200
encapsulation dot1Q 200
ip vrf forwarding SW2-BB2
ip address 150.1.200.2 255.255.255.0
end

R4
router bgp 2
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 150.1.6.6 remote-as 2
neighbor 150.1.6.6 update-source Loopback0
!
address-family vpnv4
neighbor 150.1.6.6 activate
neighbor 150.1.6.6 send-community extended
neighbor 150.1.6.6 next-hop-self
exit-address-family
!
address-family ipv4 vrf SW2-BB2
neighbor 150.1.200.2 remote-as 1
neighbor 150.1.200.2 activate
no synchronization
exit-address-family
!
address-family ipv4 vrf SW1-BB1
neighbor 150.1.100.2 remote-as 1
neighbor 150.1.100.2 activate
no synchronization
exit-address-family
!
!
interface FastEthernet2/0.100
encapsulation dot1Q 100
ip vrf forwarding SW1-BB1
ip address 150.1.100.4 255.255.255.0
!
interface FastEthernet2/0.200
encapsulation dot1Q 200
ip vrf forwarding SW2-BB2
ip address 150.1.200.4 255.255.255.0
!