Physical topology configuration.
SW1#
vlan database
vlan 17
vlan 12
vlan 23
vlan 34
vlan 45
vlan 56
vlan 68
exit
conf t
int range f1/1 - 8
switchport mode trunk
end
!
R1#
conf t
int lo0
ip add 1.1.1.1 255.255.255.255
int f0/0
no shut
int f0/0.17
encap dot1q 17
ip add 1.1.17.1 255.255.255.0
int f0/0.12
encap dot1q 12
ip add 1.1.12.1 255.255.255.0
exit
!
R2#
conf t
int lo0
ip add 1.1.2.2 255.255.255.255
int f0/0
no shut
int f0/0.12
encap dot1q 12
ip add 1.1.12.2 255.255.255.0
int f0/0.23
encap dot1q 23
ip add 1.1.23.2 255.255.255.0
exit
!
R3#
conf t
int lo0
ip add 1.1.3.3 255.255.255.255
int f0/0
no shut
int f0/0.23
encap dot1q 23
ip add 1.1.23.3 255.255.255.0
int f0/0.34
encap dot1q 34
ip add 1.1.34.3 255.255.255.0
exit
!
R4#
conf t
int lo0
ip add 1.1.4.4 255.255.255.255
int f0/0
no shut
int f0/0.34
encap dot1q 34
ip add 1.1.34.4 255.255.255.0
int f0/0.45
encap dot1q 45
ip add 1.1.45.4 255.255.255.0
exit
!
R5#
conf t
int lo0
ip add 1.1.5.5 255.255.255.255
int f0/0
no shut
int f0/0.45
encap dot1q 45
ip add 1.1.45.5 255.255.255.0
int f0/0.56
encap dot1q 56
ip add 1.1.56.5 255.255.255.0
exit
!
R6#
conf t
int lo0
ip add 1.1.6.6 255.255.255.255
int f0/0
no shut
int f0/0.56
encap dot1q 56
ip add 1.1.56.6 255.255.255.0
int f0/0.68
encap dot1q 68
ip add 1.1.68.6 255.255.255.0
exit
!
R7#
conf t
int lo0
ip add 1.1.7.7 255.255.255.255
int f0/0
no shut
int f0/0.17
encap dot1q 17
ip add 1.1.17.7 255.255.255.0
exit
!
R8#
conf t
int lo0
ip add 1.1.8.8 255.255.255.255
int f0/0
no shut
int f0/0.68
encap dot1q 68
ip add 1.1.68.8 255.255.255.0
exit
!
Configure IGP for AS1 MPLS
R1#
router ospf 1
network 1.1.1.1 0.0.0.0 area 0
network 1.1.12.1 0.0.0.0 area 0
exit
!
R2#
router ospf 1
network 1.1.2.2 0.0.0.0 area 0
network 1.1.12.2 0.0.0.0 area 0
network 1.1.23.2 0.0.0.0 area 0
exit
!
R3#
router ospf 1
network 1.1.3.3 0.0.0.0 area 0
network 1.1.23.3 0.0.0.0 area 0
exit
!
Configure AS2 LDP
R1#
mpls label range 100 199
mpls ldp router-id lo0
int f0/0.12
mpls label protocol ldp
mpls ip
exit
!
R2#
mpls label range 200 299
mpls ldp router-id lo0
mpls label protocol ldp
int f0/0.12
mpls ip
int f0/0.23
mpls ip
exit
!
R3#
mpls label range 300 399
mpls ldp router-id lo0
int f0/0.23
mpls label protocol ldp
mpls ip
exit
!
Configure AS1 MBGP
R1#
router bgp 1
bgp router-id 1.1.1.1
neighbor 1.1.2.2 remote-as 1
neighbor 1.1.2.2 update-source lo0
address-family vpnv4
neighbor 1.1.2.2 activate
neighbor 1.1.2.2 send-community extended
exit
exit
!
R2#
router bgp 1
bgp router-id 1.1.2.2
neighbor 1.1.1.1 remote-as 1
neighbor 1.1.1.1 update-source lo0
neighbor 1.1.1.1 route-reflector-client
neighbor 1.1.3.3 remote-as 1
neighbor 1.1.3.3 update-source lo0
neighbor 1.1.3.3 route-reflector-client
address-family vpnv4
neighbor 1.1.1.1 activate
neighbor 1.1.1.1 route-reflector-client
neighbor 1.1.1.1 send-community extended
neighbor 1.1.3.3 activate
neighbor 1.1.3.3 route-reflector-client
neighbor 1.1.3.3 send-community extended
exit
!
R3#
int f0/0.34
mpls bgp forwarding
exit
router bgp 1
bgp router-id 1.1.3.3
no bgp default route-target filter
neighbor 1.1.2.2 remote-as 1
neighbor 1.1.2.2 update-source lo0
neighbor 1.1.34.4 remote-as 2
address-family vpnv4
neighbor 1.1.2.2 activate
neighbor 1.1.2.2 send-community extended
neighbor 1.1.2.2 next-hop-self
neighbor 1.1.34.4 activate
neighbor 1.1.34.4 send-community extended
exit
!
Configure VRF for client
R1#
ip vrf as1-customer1
rd 1:100
route-target export 1:100
route-target import 2:100
exit
int f0/0.17
ip vrf forwarding as1-customer1
ip address 1.1.17.1 255.255.255.0
exit
!
Configure CE-PE routing
R7#
router bgp 65007
bgp router-id 1.1.7.7
network 1.1.7.0 mask 255.255.255.0
neighbor 1.1.17.1 remote-as 1
exit!
R1#
router bgp 1
address-family ipv4 vrf as1-customer1
neighbor 1.1.17.7 remote-as 65007
exit
exit
!
Configure IGP for AS2 MPLS
R4#
router eigrp 1
network 1.1.4.4 0.0.0.0
network 1.1.45.4 0.0.0.0
exit
!
R5#
router eigrp 1
network 1.1.5.5 0.0.0.0
network 1.1.45.5 0.0.0.0
network 1.1.56.5 0.0.0.0
exit
!
R6#
router eigrp 1
network 1.1.6.6 0.0.0.0
network 1.1.56.6 0.0.0.0
exit
!
Configure AS2 LDP
R4#
mpls label range 400 499
mpls ldp router-id lo0
int f0/0.45
mpls label protocol ldp
mpls ip
exit
!
R5#
mpls label range 500 599
mpls ldp router-id lo0
mpls label protocol ldp
int f0/0.45
mpls ip
int f0/0.56
mpls ip
exit
!
R6#
mpls label range 600 699
mpls ldp router-id lo0
int f0/0.56
mpls label protocol ldp
mpls ip
exit
!
Configure AS2 MBGP
R4#
int f0/0.34
mpls bgp forwarding
exit
router bgp 2
bgp router-id 1.1.4.4
no bgp default route-target filter
neighbor 1.1.34.3 remote-as 1
neighbor 1.1.5.5 remote-as 2
neighbor 1.1.5.5 update-source lo0
address-family vpnv4
neighbor 1.1.34.3 activate
neighbor 1.1.34.3 send-community extended
neighbor 1.1.5.5 activate
neighbor 1.1.5.5 send-community extended
neighbor 1.1.5.5 next-hop-self
exit
exit
!
R5#
router bgp 2
bgp router-id 1.1.5.5
neighbor 1.1.4.4 remote-as 2
neighbor 1.1.4.4 update-source lo0
neighbor 1.1.4.4 route-reflector-client
neighbor 1.1.6.6 remote-as 2
neighbor 1.1.6.6 update-source lo0
neighbor 1.1.6.6 route-reflector-client
address-family vpnv4
neighbor 1.1.4.4 activate
neighbor 1.1.4.4 route-reflector-client
neighbor 1.1.4.4 send-community extended
neighbor 1.1.6.6 activate
neighbor 1.1.6.6 route-reflector-client
neighbor 1.1.6.6 send-community extended
exit
exit
!
R6#
router bgp 2
bgp router-id 1.1.6.6
neighbor 1.1.5.5 remote-as 2
neighbor 1.1.5.5 update-source lo0
address-family vpnv4
neighbor 1.1.5.5 activate
neighbor 1.1.5.5 send-community extended
exit
!
Configure VRF for client of AS2
R6#
ip vrf as2-customer1
rd 2:100
route-target export 2:100
route-target import 1:100
exit
int f0/0.68
ip vrf forwarding as2-customer1
ip address 1.1.68.6 255.255.255.0
exit
!
Configure CE-PE routing
R8#
router bgp 65008
bgp router-id 1.1.8.8
network 1.1.8.0 mask 255.255.255.0
neighbor 1.1.68.6 remote-as 2
exit
!
R6#
router bgp 2
address-family ipv4 vrf as2-customer1
neighbor 1.1.68.8 remote-as 65008
exit
!
No comments:
Post a Comment