Tuesday, June 1, 2010

MPLS Scenario 1




The above diagram is the MPLS network I setup today and I thought I would blog about it since it took so much time to configure. As you can see above the BGP AS 65001 is the SP environment P1 is the provider router, with PE1, and PE2 being the provider edges. I am running OSPF inside the SP environment. Pe1 peers to P1 which peers to Pe2 via BGP. I have two customer scenario's setup. First CE-A1/A2 are examples of what a typical customer would be to an SP. CE-B1/B2 are the second sets of customers. I am going to explain the configuration scenario but first I will just add that the vlans are already setup, as well as the physical links between the devices. That being said this is how the configurations went.

1) Create each VRF,RD, and RT, and associate the customer-facing PE interfaces with the correct VRF.

2) Configured the IGP between PE and CE

3) Configured the mutual redistribution between the IGP and BGP.

4) Configured the MP-BGP between the PE's.




Here is the breakdown of the configurations:


PE1:

!
hostname PE1
ip cef
!
!
no ip domain lookup
ip vrf CUST-A
rd 65001:100
route-target export 65001:100
route-target import 65001:100
!
ip vrf CUST-B
rd 65001:222
route-target export 65001:200
route-target import 65001:200
!
no ipv6 cef
!
multilink bundle-name authenticated
!
interface Loopback0
ip address 1.1.1.1 255.255.255.255
ip ospf 1 area 0
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.12
encapsulation dot1Q 12
ip address 192.168.12.1 255.255.255.0
ip ospf 1 area 0
mpls ip
!
interface FastEthernet0/0.15
encapsulation dot1Q 15
ip vrf forwarding CUST-A
ip address 192.168.15.1 255.255.255.0
!
interface FastEthernet0/0.16
encapsulation dot1Q 16
ip vrf forwarding CUST-B
ip address 192.168.16.1 255.255.255.0
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0/0
no ip address
encapsulation frame-relay IETF
shutdown
frame-relay lmi-type cisco
!
interface Serial0/1/0
no ip address
shutdown
clock rate 2000000
!
router eigrp 65001
no auto-summary
!
address-family ipv4 vrf CUST-B
redistribute bgp 65001 metric 1 1 1 1 1
network 100.100.100.100 0.0.0.0
network 192.168.16.1 0.0.0.0
no auto-summary
autonomous-system 2
exit-address-family
!
address-family ipv4 vrf CUST-A
redistribute bgp 65001 metric 1 1 1 1 1
network 192.168.15.1 0.0.0.0
no auto-summary
autonomous-system 1
exit-address-family
!
router ospf 1
log-adjacency-changes
!
router bgp 65001
no synchronization
bgp log-neighbor-changes
neighbor 3.3.3.3 remote-as 65001
neighbor 3.3.3.3 update-source Loopback0
no auto-summary
!
address-family vpnv4
neighbor 3.3.3.3 activate
neighbor 3.3.3.3 send-community extended
exit-address-family
!
address-family ipv4 vrf CUST-B
redistribute connected
redistribute eigrp 2
no synchronization
exit-address-family
!
address-family ipv4 vrf CUST-A
redistribute connected
redistribute eigrp 1
no synchronization
exit-address-family
!
ip forward-protocol nd
no ip http server
no ip http secure-server
!
control-plane
!
mgcp fax t38 ecm
!



PE2

hostname PE2
!
ip cef
!
no ip domain lookup
ip vrf CUST-A
rd 65001:100
route-target export 65001:100
route-target import 65001:100
!
ip vrf CUST-B
rd 65001:222
route-target export 65001:200
route-target import 65001:200
!
no ipv6 cef
!
multilink bundle-name authenticated
!
interface Loopback0
ip address 3.3.3.3 255.255.255.255
ip ospf 1 area 0
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.23
encapsulation dot1Q 23
ip address 192.168.23.3 255.255.255.0
ip ospf 1 area 0
mpls ip
!
interface FastEthernet0/0.37
encapsulation dot1Q 37
ip vrf forwarding CUST-A
ip address 192.168.37.3 255.255.255.0
!
interface FastEthernet0/0.38
encapsulation dot1Q 38
ip vrf forwarding CUST-B
ip address 192.168.38.3 255.255.255.0
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0/0
ip address 54.42.1.6 255.255.255.0
encapsulation frame-relay
shutdown
frame-relay map ip 54.42.1.254 101 broadcast
no frame-relay inverse-arp
frame-relay lmi-type cisco
!
router eigrp 65001
auto-summary
!
address-family ipv4 vrf CUST-B
redistribute bgp 65001 metric 1 1 1 1 1
network 0.0.0.0
no auto-summary
autonomous-system 2
exit-address-family
!
address-family ipv4 vrf CUST-A
redistribute bgp 65001 metric 1 1 1 1 1
network 0.0.0.0
no auto-summary
autonomous-system 1
exit-address-family
!
router ospf 1
log-adjacency-changes
!
router bgp 65001
no synchronization
bgp log-neighbor-changes
neighbor 1.1.1.1 remote-as 65001
neighbor 1.1.1.1 update-source Loopback0
no auto-summary
!
address-family vpnv4
neighbor 1.1.1.1 activate
neighbor 1.1.1.1 send-community extended
exit-address-family
!
address-family ipv4 vrf CUST-B
redistribute connected
redistribute eigrp 2
no synchronization
exit-address-family
!
address-family ipv4 vrf CUST-A
redistribute connected
redistribute eigrp 1
no synchronization
exit-address-family
!
ip forward-protocol nd
no ip http server
no ip http secure-server
!
control-plane
!
mgcp fax t38 ecm
!

Provider:


hostname P
!
dot11 syslog
ip source-route
ip cef
!
no ip domain lookup
no ipv6 cef
!
multilink bundle-name authenticated
!
interface Loopback0
ip address 2.2.2.2 255.255.255.255
ip ospf 1 area 0
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.12
encapsulation dot1Q 12
ip address 192.168.12.2 255.255.255.0
ip ospf 1 area 0
mpls ip
!
interface FastEthernet0/0.23
encapsulation dot1Q 23
ip address 192.168.23.2 255.255.255.0
ip ospf 1 area 0
mpls ip
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0/0
no ip address
encapsulation frame-relay IETF
shutdown
frame-relay lmi-type cisco
!
interface Serial0/1/0
no ip address
shutdown
!
router ospf 1
log-adjacency-changes
!
ip forward-protocol nd
no ip http server
no ip http secure-server
!


CE-A1:

no aaa new-model
system mtu routing 1500
vtp mode transparent
ip subnet-zero
ip routing
no ip domain-lookup
!
spanning-tree mode pvst
spanning-tree extend system-id
spanning-tree vlan 1-4094 priority 24576
!
vlan internal allocation policy ascending
!
vlan 2-100
!
interface Loopback1
ip address 10.1.1.1 255.255.255.0
!
interface Loopback2
ip address 10.1.2.1 255.255.255.0
!
interface Loopback3
ip address 10.1.3.1 255.255.255.0
!
interface Loopback4
ip address 10.1.4.1 255.255.255.0
!
interface Loopback5
ip address 10.1.5.1 255.255.255.0
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/5
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/6
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/13
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface FastEthernet0/14
shutdown
!
interface FastEthernet0/15
shutdown
!
interface FastEthernet0/16
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface FastEthernet0/17
shutdown
!
interface FastEthernet0/18
shutdown
!
interface FastEthernet0/19
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface Vlan1
no ip address
shutdown
!
interface Vlan15
ip address 192.168.15.5 255.255.255.0
!
!
router eigrp 1
no auto-summary
network 0.0.0.0
!
ip classless
ip http server
ip http secure-server
!


CE-A2:

!
hostname CE-A2
!
enable password cisco
!
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
vlan 2-100
!
interface Loopback6
ip address 10.1.6.1 255.255.255.0
!
interface Loopback7
ip address 10.1.7.1 255.255.255.0
!
interface Loopback8
ip address 10.1.8.1 255.255.255.0
!
interface Loopback9
ip address 10.1.9.1 255.255.255.0
!
interface Loopback10
ip address 10.1.10.1 255.255.255.0
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/5
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/6
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
!
interface FastEthernet0/24
switchport access vlan 3
switchport mode access
!
!
interface Vlan1
no ip address
shutdown
!
interface Vlan37
ip address 192.168.37.7 255.255.255.0
!
!
router eigrp 1
no auto-summary
network 0.0.0.0
!
ip classless
ip http server
ip http secure-server
!


CE-B1:

!
hostname CE-B1
!
boot-start-marker
boot-end-marker
!
enable password cisco
!
!
vlan 2-100
!
interface Loopback1
ip address 10.2.1.1 255.255.255.0
!
interface Loopback2
ip address 10.2.2.1 255.255.255.0
!
interface Loopback3
ip address 10.2.3.1 255.255.255.0
!
interface Loopback4
ip address 10.2.4.1 255.255.255.0
!
interface Loopback5
ip address 10.2.5.1 255.255.255.0
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/5
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/6
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
!
interface FastEthernet0/13
switchport trunk encapsulation dot1q
switchport mode trunk
!
!
interface FastEthernet0/24
switchport access vlan 2
switchport mode access
!
!
interface Vlan1
no ip address
shutdown
!
interface Vlan16
ip address 192.168.16.6 255.255.255.0
!
!
router eigrp 2
no auto-summary
network 10.2.1.1 0.0.0.0
network 192.168.16.6 0.0.0.0
network 0.0.0.0
!



CE-B2:

!
hostname CE-B2
!
enable password cisco
!
!
vlan internal allocation policy ascending
!
vlan 2-100
!
!
interface Loopback6
ip address 10.2.6.1 255.255.255.0
!
interface Loopback7
ip address 10.2.7.1 255.255.255.0
!
interface Loopback8
ip address 10.2.8.1 255.255.255.0
!
interface Loopback9
ip address 10.2.9.1 255.255.255.0
!
interface Loopback10
ip address 10.2.10.1 255.255.255.0
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/5
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
interface FastEthernet0/6
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!
!
interface Vlan1
no ip address
shutdown
!
interface Vlan38
ip address 192.168.38.8 255.255.255.0
!
!
router eigrp 2
no auto-summary
network 0.0.0.0
!