Published 6月 08, 2018 by with 0 comment

CCIE-SP Lab 05: MPLS VPN Basic Configuration


In this Lab, I am using GNS3 to redroduce the book "MPLS Configuration on Cisco IOS Software" p95 Figure 3-11 Lab.

Scenario:
This lab outlines the generic confgurations required on the routers in the service provider domain to implement MPLS VPN.

Configuration steps
1. Confguration of CE Routers
2. Confguring MPLS Forwarding and VRF Defnition on PE Routers
3. Confguration of BGP PE-PE Routing on PE Routers
4. Confguration of P Router


1. Confguration of CE Routers
CEA-1:
CEA-1(config)#interface loopback 0
CEA-1(config-if)#ip address 172.16.10.1 255.255.255.0
!
CEA-1(config)#interface serial 1/0
CEA-1(config-if)#description TO PE1-AS1 S1/1
CEA-1(config-if)#ip address 172.16.1.2 255.255.255.0
CEA-1(config-if)#no shutdown
!
CEA-1(config)#ip route 0.0.0.0 0.0.0.0 172.16.1.1

CEA-2:
CEA-2(config)#interface loopback 0
CEA-2(config-if)#ip address 172.16.20.1 255.255.255.0
!
CEA-2(config)#interface serial 1/0
CEA-2(config-if)#description TO PE2-AS1 S1/1
CEA-2(config-if)#ip address 172.16.2.2 255.255.255.0
CEA-2(config-if)#no shutdown
!
CEA-2(config)#ip route 0.0.0.0 0.0.0.0 172.16.2.1


2. Confguring MPLS Forwarding and VRF Defnition on PE Routers
PE1-AS1:
PE1-AS1(config)#interface loopback 0
PE1-AS1(config-if)#ip address 10.10.10.101 255.255.255.255
!
PE1-AS1(config)#interface serial 1/0
PE1-AS1(config-if)#description TO P1-AS1 S1/0
PE1-AS1(config-if)#ip address 10.10.10.1 255.255.255.252
PE1-AS1(config-if)#no shutdown
!
PE1-AS1(config)#interface serial 1/1
PE1-AS1(config-if)#ip address 172.16.1.1 255.255.255.0
PE1-AS1(config-if)#description TO CEA-1 S1/0
PE1-AS1(config-if)#no shutdown
!
PE1-AS1(config)#ip cef
!
PE1-AS1(config)#router ospf 1
PE1-AS1(config-router)#router-id 10.10.10.101
PE1-AS1(config-router)#network 10.10.10.101 0.0.0.0 area 0
PE1-AS1(config-router)#network 10.10.10.1 0.0.0.0 area 0
!
PE1-AS1(config)#mpls label protocol ldp
PE1-AS1(config)#mpls label range 100 199
PE1-AS1(config)#mpls ldp router-id loopback 0 force
!
PE1-AS1(config)#interface serial 1/0
PE1-AS1(config-if)#mpls ip
!
PE1-AS1(config)#ip vrf CustomerA
PE1-AS1(config-vrf)#rd 1:100
PE1-AS1(config-vrf)#route-target both 1:100
!
PE1-AS1(config)#interface loopback 1
PE1-AS1(config-if)#ip vrf forwarding CustomerA
PE1-AS1(config-if)#ip address 172.16.100.1 255.255.255.255
!
PE1-AS1(config)#interface serial 1/1
PE1-AS1(config-if)#ip vrf forwarding CustomerA
% Interface Serial1/1 IPv4 disabled and address(es) removed due to disabling VRF CustomerA
PE1-AS1(config-if)#ip address 172.16.1.1 255.255.255.0


PE2-AS1:
PE2-AS1(config)#interface loopback 0

PE2-AS1(config-if)#ip address 10.10.10.102 255.255.255.255
!
PE2-AS1(config)#interface serial 1/0
PE2-AS1(config-if)#description TO P1-AS1 S1/1
PE2-AS1(config-if)#ip address 10.10.10.6 255.255.255.252
PE2-AS1(config-if)#no shutdown
!
PE2-AS1(config)#interface serial 1/1
PE2-AS1(config-if)#description TO CEA-2 S1/0
PE2-AS1(config-if)#ip address 172.16.2.1 255.255.255.0
PE2-AS1(config-if)#no shutdown
!
PE2-AS1(config)#ip cef
!
PE2-AS1(config)#router ospf 1
PE2-AS1(config-router)#router-id 10.10.10.102
PE2-AS1(config-router)#network 10.10.10.102 0.0.0.0 area 0
PE2-AS1(config-router)#network 10.10.10.6 0.0.0.0 area 0
!
PE2-AS1(config)#mpls label protocol ldp
PE2-AS1(config)#mpls label range 200 299
PE2-AS1(config)#mpls ldp router-id loopback 0 force
!
PE2-AS1(config)#interface serial 1/0
PE2-AS1(config-if)#mpls ip
!
PE2-AS1(config)#ip vrf CustomerA
PE2-AS1(config-vrf)#rd 1:100
PE2-AS1(config-vrf)#route-target both 1:100
!
PE2-AS1(config)#interface loopback 1
PE2-AS1(config-if)#ip vrf forwarding CustomerA
PE2-AS1(config-if)#ip address 172.16.200.1 255.255.255.255
!
PE2-AS1(config)#interface serial 1/1
PE2-AS1(config-if)#ip vrf forwarding CustomerA
% Interface Serial1/1 IPv4 disabled and address(es) removed due to disabling VRF CustomerA
PE2-AS1(config-if)#ip address 172.16.2.1 255.255.255.0


3. Confguration of BGP PE-PE Routing on PE Routers
PE1-AS1:
PE1-AS1(config)#router bgp 1
PE1-AS1(config-router)#bgp router-id 10.10.10.101
PE1-AS1(config-router)#no bgp default ipv4-unicast
PE1-AS1(config-router)#neighbor 10.10.10.102 remote-as 1
PE1-AS1(config-router)#neighbor 10.10.10.102 update-source loopback 0
PE1-AS1(config-router)#address-family vpnv4 unicast
PE1-AS1(config-router-af)#neighbor 10.10.10.102 activate
PE1-AS1(config-router-af)#neighbor 10.10.10.102 send-community extended
PE1-AS1(config-router-af)#exit
PE1-AS1(config-router)#address-family ipv4 vrf CustomerA
PE1-AS1(config-router-af)#redistribute connected


PE2-AS1:
PE2-AS1(config)#router bgp 1
PE2-AS1(config-router)#bgp router-id 10.10.10.102
PE2-AS1(config-router)#no bgp default ipv4-unicast
PE2-AS1(config-router)#neighbor 10.10.10.101 remote-as 1
PE2-AS1(config-router)#neighbor 10.10.10.101 update-source loopback 0
PE2-AS1(config-router)#address-family vpnv4 unicast
PE2-AS1(config-router-af)#neighbor 10.10.10.101 activate
PE2-AS1(config-router-af)#neighbor 10.10.10.101 send-community extended
PE2-AS1(config-router-af)#exit
PE2-AS1(config-router)#address-family ipv4 vrf CustomerA
PE2-AS1(config-router-af)#redistribute connected


4. Confguration of P Router
P1-AS1:
P1-AS1(config)#ip cef
!
P1-AS1(config)#interface loopback 0
P1-AS1(config-if)#ip address 10.10.10.200 255.255.255.255
!
P1-AS1(config)#interface serial 1/0
P1-AS1(config-if)#description TO PE1-AS1 S1/0
P1-AS1(config-if)#ip address 10.10.10.2 255.255.255.252
P1-AS1(config-if)#no shutdown
!
P1-AS1(config)#interface serial 1/1
P1-AS1(config-if)#description TO PE2-AS1 S1/0
P1-AS1(config-if)#ip address 10.10.10.5 255.255.255.252
!
P1-AS1(config)#router ospf 1
P1-AS1(config-router)#router-id 10.10.10.200
P1-AS1(config-router)#network 10.10.10.200 0.0.0.0 area 0
P1-AS1(config-router)#network 10.10.10.2 0.0.0.0 area 0
P1-AS1(config-router)#network 10.10.10.5 0.0.0.0 area 0
!
P1-AS1(config)#mpls label protocol ldp
P1-AS1(config)#mpls label range 500 599
P1-AS1(config)#mpls ldp router-id loopback 0 force
!
P1-AS1(config)#interface serial 1/0
P1-AS1(config-if)#mpls ip
!
P1-AS1(config)#interface serial 1/1
P1-AS1(config-if)#mpls ip


Check:
PE1-AS1
PE1-AS1#show mpls forwarding-table vrf CustomerA
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop
Label      Label      or Tunnel Id     Switched      interface
100        No Label   172.16.1.0/24[V] 0             aggregate/CustomerA
101        Pop Label  172.16.100.1/32[V] 
                                       0             aggregate/CustomerA
PE1-AS1#


PE1-AS1#show ip bgp vpnv4 all
BGP table version is 7, local router ID is 10.10.10.101
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
              r RIB-failure, S Stale, m multipath, b backup-path, x best-external, f RT-Filter
Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric LocPrf Weight Path
Route Distinguisher: 1:100 (default for vrf CustomerA)
*> 172.16.1.0/24    0.0.0.0                  0         32768 ?
*>i172.16.2.0/24    10.10.10.102             0    100      0 ?
*> 172.16.100.1/32  0.0.0.0                  0         32768 ?
*>i172.16.200.1/32  10.10.10.102             0    100      0 ?
PE1-AS1#


PE1-AS1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 6 subnets, 2 masks
C        10.10.10.0/30 is directly connected, Serial1/0
L        10.10.10.1/32 is directly connected, Serial1/0
O        10.10.10.4/30 [110/128] via 10.10.10.2, 00:06:15, Serial1/0
C        10.10.10.101/32 is directly connected, Loopback0
O        10.10.10.102/32 [110/129] via 10.10.10.2, 00:06:15, Serial1/0
O        10.10.10.200/32 [110/65] via 10.10.10.2, 00:06:25, Serial1/0
PE1-AS1#


PE1-AS1#show ip route vrf CustomerA

Routing Table: CustomerA
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      172.16.0.0/16 is variably subnetted, 5 subnets, 2 masks
C        172.16.1.0/24 is directly connected, Serial1/1
L        172.16.1.1/32 is directly connected, Serial1/1
B        172.16.2.0/24 [200/0] via 10.10.10.102, 00:06:31
C        172.16.100.1/32 is directly connected, Loopback1
B        172.16.200.1/32 [200/0] via 10.10.10.102, 00:06:31
PE1-AS1#


PE1-AS1#ping vrf CustomerA 172.16.200.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.200.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 204/247/308 ms
PE1-AS1#


PE1-AS1#traceroute vrf CustomerA 172.16.200.1
Type escape sequence to abort.
Tracing the route to 172.16.200.1
VRF info: (vrf in name/id, vrf out name/id)
  1 10.10.10.2 [MPLS: Labels 501/201 Exp 0] 212 msec 248 msec 180 msec
  2 172.16.200.1 240 msec 252 msec 216 msec
PE1-AS1#


PE2-AS1:
PE2-AS1#show mpls forwarding-table vrf CustomerA
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop
Label      Label      or Tunnel Id     Switched      interface
200        No Label   172.16.2.0/24[V] 0             aggregate/CustomerA
201        Pop Label  172.16.200.1/32[V] 
                                       1136          aggregate/CustomerA
PE2-AS1#


PE2-AS1#show ip bgp vpnv4 all
BGP table version is 7, local router ID is 10.10.10.102
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
              r RIB-failure, S Stale, m multipath, b backup-path, x best-external, f RT-Filter
Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric LocPrf Weight Path
Route Distinguisher: 1:100 (default for vrf CustomerA)
*>i172.16.1.0/24    10.10.10.101             0    100      0 ?
*> 172.16.2.0/24    0.0.0.0                  0         32768 ?
*>i172.16.100.1/32  10.10.10.101             0    100      0 ?
*> 172.16.200.1/32  0.0.0.0                  0         32768 ?
PE2-AS1#


PE2-AS1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 6 subnets, 2 masks
O        10.10.10.0/30 [110/128] via 10.10.10.5, 00:12:03, Serial1/0
C        10.10.10.4/30 is directly connected, Serial1/0
L        10.10.10.6/32 is directly connected, Serial1/0
O        10.10.10.101/32 [110/129] via 10.10.10.5, 00:12:03, Serial1/0
C        10.10.10.102/32 is directly connected, Loopback0
O        10.10.10.200/32 [110/65] via 10.10.10.5, 00:12:03, Serial1/0
PE2-AS1#


PE2-AS1#show ip route vrf CustomerA

Routing Table: CustomerA
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      172.16.0.0/16 is variably subnetted, 5 subnets, 2 masks
B        172.16.1.0/24 [200/0] via 10.10.10.101, 00:12:05
C        172.16.2.0/24 is directly connected, Serial1/1
L        172.16.2.1/32 is directly connected, Serial1/1
B        172.16.100.1/32 [200/0] via 10.10.10.101, 00:12:05
C        172.16.200.1/32 is directly connected, Loopback1
PE2-AS1#


PE2-AS1#ping vrf CustomerA 172.16.100.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.100.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 224/245/264 ms
PE2-AS1#


PE2-AS1#traceroute vrf CustomerA 172.16.100.1
Type escape sequence to abort.
Tracing the route to 172.16.100.1
VRF info: (vrf in name/id, vrf out name/id)
  1 10.10.10.5 [MPLS: Labels 500/101 Exp 0] 212 msec 268 msec 196 msec
  2 172.16.100.1 252 msec 260 msec 260 msec
PE2-AS1#


P1-AS1#show mpls forwarding-table
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop
Label      Label      or Tunnel Id     Switched      interface
500        Pop Label  10.10.10.101/32  3525          Se1/0      point2point
501        Pop Label  10.10.10.102/32  3525          Se1/1      point2point
P1-AS1#


P1-AS1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 7 subnets, 2 masks
C        10.10.10.0/30 is directly connected, Serial1/0
L        10.10.10.2/32 is directly connected, Serial1/0
C        10.10.10.4/30 is directly connected, Serial1/1
L        10.10.10.5/32 is directly connected, Serial1/1
O        10.10.10.101/32 [110/65] via 10.10.10.1, 00:13:59, Serial1/0
O        10.10.10.102/32 [110/65] via 10.10.10.6, 00:13:59, Serial1/1
C        10.10.10.200/32 is directly connected, Loopback0
P1-AS1#


CEA-1:
CEA-1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is 172.16.1.1 to network 0.0.0.0

S*    0.0.0.0/0 [1/0] via 172.16.1.1
      172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
C        172.16.1.0/24 is directly connected, Serial1/0
L        172.16.1.2/32 is directly connected, Serial1/0
C        172.16.10.0/24 is directly connected, Loopback0
L        172.16.10.1/32 is directly connected, Loopback0
CEA-1#


CEA-1#ping 172.16.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 392/450/492 ms
CEA-1#


CEA-2:
CEA-2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is 172.16.2.1 to network 0.0.0.0

S*    0.0.0.0/0 [1/0] via 172.16.2.1
      172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
C        172.16.2.0/24 is directly connected, Serial1/0
L        172.16.2.2/32 is directly connected, Serial1/0
C        172.16.20.0/24 is directly connected, Loopback0
L        172.16.20.1/32 is directly connected, Loopback0
CEA-2#


CEA-2#ping 172.16.1.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.1.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 372/457/532 ms
CEA-2#


Final Configurations:
PE1-AS1:
hostname PE1-AS1
!
ip cef
!
ip vrf CustomerA
 rd 1:100
 route-target export 1:100
 route-target import 1:100
!
no ip domain lookup
!
mpls label range 100 199
mpls label protocol ldp
!
interface Loopback0
 ip address 10.10.10.101 255.255.255.255
!
interface Loopback1
 ip vrf forwarding CustomerA
 ip address 172.16.100.1 255.255.255.255
!
interface Serial1/0
 description TO P1-AS1 S1/0
 ip address 10.10.10.1 255.255.255.252
 mpls ip
 no shutdown
!
interface Serial1/1
 description TO CEA-1 S1/0
 ip vrf forwarding CustomerA
 ip address 172.16.1.1 255.255.255.0
 no shutdown
!
router ospf 1
 router-id 10.10.10.101
 network 10.10.10.1 0.0.0.0 area 0
 network 10.10.10.101 0.0.0.0 area 0
!
router bgp 1
 bgp router-id 10.10.10.101
 bgp log-neighbor-changes
 no bgp default ipv4-unicast
 neighbor 10.10.10.102 remote-as 1
 neighbor 10.10.10.102 update-source Loopback0
 !
 address-family ipv4
 exit-address-family
 !
 address-family vpnv4
  neighbor 10.10.10.102 activate
  neighbor 10.10.10.102 send-community extended
 exit-address-family
 !
 address-family ipv4 vrf CustomerA
  redistribute connected
 exit-address-family
!
mpls ldp router-id Loopback0 force
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
 stopbits 1
!
end


PE2-AS1:
hostname PE2-AS1
!
ip cef
!
ip vrf CustomerA
 rd 1:100
 route-target export 1:100
 route-target import 1:100
!
no ip domain lookup
!
mpls label range 200 299
mpls label protocol ldp
!
interface Loopback0
 ip address 10.10.10.102 255.255.255.255
!
interface Loopback1
 ip vrf forwarding CustomerA
 ip address 172.16.200.1 255.255.255.255
!
interface Serial1/0
 description TO P1-AS1 S1/1
 ip address 10.10.10.6 255.255.255.252
 mpls ip
 no shutdown
!
interface Serial1/1
 description TO CEA-2 S1/0
 ip vrf forwarding CustomerA
 ip address 172.16.2.1 255.255.255.0
 no shutdown
!
router ospf 1
 router-id 10.10.10.102
 network 10.10.10.6 0.0.0.0 area 0
 network 10.10.10.102 0.0.0.0 area 0
!
router bgp 1
 bgp router-id 10.10.10.102
 bgp log-neighbor-changes
 no bgp default ipv4-unicast
 neighbor 10.10.10.101 remote-as 1
 neighbor 10.10.10.101 update-source Loopback0
 !
 address-family ipv4
 exit-address-family
 !
 address-family vpnv4
  neighbor 10.10.10.101 activate
  neighbor 10.10.10.101 send-community extended
 exit-address-family
 !
 address-family ipv4 vrf CustomerA
  redistribute connected
 exit-address-family
!
mpls ldp router-id Loopback0 force
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
 stopbits 1
!
end


P1-AS1:
hostname P1-AS1
!
ip cef
!
no ip domain lookup
!
mpls label range 500 599
mpls label protocol ldp
!
interface Loopback0
 ip address 10.10.10.200 255.255.255.255
!
interface Serial1/0
 description TO PE1-AS1 S1/0
 ip address 10.10.10.2 255.255.255.252
 mpls ip
 no shutdown
!
interface Serial1/1
 description TO PE2-AS1 S1/0
 ip address 10.10.10.5 255.255.255.252
 mpls ip
 no shutdown
!
router ospf 1
 router-id 10.10.10.200
 network 10.10.10.2 0.0.0.0 area 0
 network 10.10.10.5 0.0.0.0 area 0
 network 10.10.10.200 0.0.0.0 area 0
!
mpls ldp router-id Loopback0 force
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
 stopbits 1

!
end


CEA-1:
hostname CEA-1
!
ip cef
!
no ip domain lookup
!
interface Loopback0
 ip address 172.16.10.1 255.255.255.0
!
interface Serial1/0
 description TO PE1-AS1 S1/1
 ip address 172.16.1.2 255.255.255.0
 no shutdown
!
ip route 0.0.0.0 0.0.0.0 172.16.1.1
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
 stopbits 1
!
end


CEA-2:
hostname CEA-2
!
ip cef
!
no ip domain lookup
!
interface Loopback0
 ip address 172.16.20.1 255.255.255.0
!
interface Serial1/0
 description TO PE2-AS1 S1/1
 ip address 172.16.2.2 255.255.255.0
 no shutdown
!
ip route 0.0.0.0 0.0.0.0 172.16.2.1
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
 stopbits 1
!
end


Reference:
1. MPLS Configuration on Cisco IOS Software
http://www.ciscopress.com/store/mpls-configuration-on-cisco-ios-software-paperback-9781587142505
ISBN-10: 1-58714-250-3
ISBN-13: 978-1-58714-250-5

2. Download GNS3 Lab file
http://sync.hamicloud.net/_oops/juilin77/h9t


最初發表 / 最後更新: 2014.01.12 / 2018.06.08

0 comments:

張貼留言