MPLS – Understand MPLS Basics

MPLS CHAPTER 1

MPLS CHAP 1

QUESTIONS CHAP 1
1. What are the commands to enable MPLS and where  are the commands used ?
2. How do you verify the local label a router has chosen for a given network ?
3. How do you verify which label a router will impose

SOLUTIONS :
1. What are the commands to enable MPLS and where  are the commands used ?
if we enable mpls ip at global config mode it will enable mpls on all the interfaces.
so enable mpls ip on per interface basis.

in this diagram enable mpls ip  on the interface within the square box , R1 fa0/0
R2 f0/0-f0/1 & R3 f0/1.
2. How do you verify the local label a router has chosen for a given network ?
For LIB table:
R2#sh mpls ldp bindings 1.1.1.1 32
  tib entry: 1.1.1.1/32, rev 2
        local binding:  tag: 16
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 16
R2#sh mpls ldp bindings 3.3.3.3 32
  tib entry: 3.3.3.3/32, rev 6
        local binding:  tag: 17
        remote binding: tsr: 1.1.1.1:0, tag: 501
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
for LFIB table:
R2#sh mpls forwarding-table 1.1.1.1
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
16     Pop tag     1.1.1.1/32        0          Fa0/0      10.1.12.1
R2#sh mpls forw
R2#sh mpls forwarding-table 3.3.3.3
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
17     Pop tag     3.3.3.3/32        0          Fa0/1      10.1.23.3
3. How do you verify which label a router will impose
R1#sh ip cef 3.3.3.3
3.3.3.3/32, version 13, epoch 0, cached adjacency 10.1.12.2
0 packets, 0 bytes
  tag information set
    local tag: 501
    fast tag rewrite with Fa0/0, 10.1.12.2, tags imposed: {17}
  via 10.1.12.2, FastEthernet0/0, 0 dependencies
    next hop 10.1.12.2, FastEthernet0/0
    valid cached adjacency
    tag rewrite with Fa0/0, 10.1.12.2, tags imposed: {17}

MPLS CHAPTER 2

MPLS CHAPTER 2
QUESTIONS:

4. What protocol(s)/Port(s) are used for LDP Hellos & Sessions ?
5. How does R3 know what R2’s local label is for a specific network ?
6. When MPLS is enabled, what would prevent an LDP neighborship ?
7. Why would you use an ACL in combination with an MPLS debug ?

SOLUTIONS :
4. What protocol(s)/Port(s) are used for LDP Hellos & Sessions ?
5. How does R3 know what R2’s local label is for a specific network ?
7. Why would you use an ACL in combination with an MPLS debug ?

1. first they send hello pkts to discover the lsp routers with udp multicast 646 224.0.0.2
2. then the establish tcp relationship with tcp 646 224.0.0.2 , higher rid will act like
active router lower rid will act like passive router.
3. then they send & recieve ldp lables

DIAGRAM :

in the diagram given from the last lab , disable & enable mpls & find the neighbor relationship .
configure on R2 for the relationship with R3

conf)# access-list 1 permit 3.3.3.3
exit
# debug mpls ldp bindings prefix-list 1

R2(config)#access-list 1 permit 3.3.3.3
R2(config)#end
R2#debug mpls ldp bindings prefix-acl 1
LDP Label Information Base (LIB) changes debugging is on for prefix ACL 1
R2#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R2(config)#no mpls ip
*Mar  1 00:06:42.475: tagcon: tibent(3.3.3.3/32): deleted
R2(config)#mpls ip
R2(config)#
—–output cut ———–
*Mar  1 00:06:44.827: tib: find route tags: 3.3.3.3/32, Fa0/1, nh 10.1.23.3, res nh 10.1.23.3
*Mar  1 00:06:44.827: tagcon: announce labels for: 3.3.3.3/32; nh 10.1.23.3, Fa0/1, inlabel 19, outlabel unknown (from 0.0.0.0:0), find route tags
R2(config)#
*Mar  1 00:06:49.907: tagcon: (Default-IP-Routing-Table) Assign peer id; 3.3.3.3:0: id 0
*Mar  1 00:06:49.911: %LDP-5-NBRCHG: LDP Neighbor 3.3.3.3:0 (1) is UP
*Mar  1 00:06:49.927: tagcon: 3.3.3.3:0: 10.1.23.3 added to addr<->ldp ident map
*Mar  1 00:06:49.931: tagcon: 3.3.3.3:0: 3.3.3.3 added to addr<->ldp ident map
*Mar  1 00:06:49.931: tagcon: tibent(3.3.3.3/32): label imp-null from 3.3.3.3:0  added
*Mar  1 00:06:49.935: tagcon: announce labels for: 3.3.3.3/32; nh 10.1.23.3, Fa0/1, inlabel 19, outlabel imp-null (from 3.3.3.3:0), add rem binding
*Mar  1 00:06:50.367: tagcon: (Default-IP-Routing-Table) Assign peer id; 1.1.1.1:0: id 1
*Mar  1 00:06:50.371: %LDP-5-NBRCHG: LDP Neighbor 1.1.1.1:0 (2) is UP
R2(config)#
*Mar  1 00:06:50.479: tagcon: 1.1.1.1:0: 10.1.12.1 added to addr<->ldp ident map
*Mar  1 00:06:50.483: tagcon: 1.1.1.1:0: 1.1.1.1 added to addr<->ldp ident map
*Mar  1 00:06:50.491: tagcon: tibent(3.3.3.3/32): label 502 from 1.1.1.1:0 added
*Mar  1 00:06:50.491: tib: Not OK to announce label; nh 10.1.23.3 not bound to 1.1.1.1:0
*Mar  1 00:06:50.495: tagcon: omit announce labels for: 3.3.3.3/32; nh 10.1.23.3, Fa0/1, from 1.1.1.1:0: add rem binding: next hop = 10.1.23.3

R2#undebug  all

6. When MPLS is enabled, what would prevent an LDP neighborship ?

# sh mpls ldp neighbour
if transport address in not reachable they will not form ldp relationships

R2#sh mpls ldp neighbor
    Peer LDP Ident: 1.1.1.1:0; Local LDP Ident 2.2.2.2:0
        TCP connection: 1.1.1.1.646 – 2.2.2.2.38184
        State: Oper; Msgs sent/rcvd: 19/19; Downstream
        Up time: 00:10:11
        LDP discovery sources:
          FastEthernet0/0, Src IP addr: 10.1.12.1
        Addresses bound to peer LDP Ident:
          10.1.12.1       1.1.1.1
    Peer LDP Ident: 3.3.3.3:0; Local LDP Ident 2.2.2.2:0
        TCP connection: 3.3.3.3.43683 – 2.2.2.2.646
        State: Oper; Msgs sent/rcvd: 13/13; Downstream
        Up time: 00:04:38
        LDP discovery sources:
          FastEthernet0/1, Src IP addr: 10.1.23.3
        Addresses bound to peer LDP Ident:
          10.1.23.3       3.3.3.3

R2#sh mpls ldp bindings local
  tib entry: 1.1.1.1/32, rev 2
        local binding:  tag: 18
  tib entry: 2.2.2.2/32, rev 4
        local binding:  tag: imp-null
  tib entry: 3.3.3.3/32, rev 6
        local binding:  tag: 19
  tib entry: 10.1.12.0/24, rev 8
        local binding:  tag: imp-null
  tib entry: 10.1.23.0/24, rev 10
        local binding:  tag: imp-null
R2#sh ip cef 3.3.3.3
3.3.3.3/32, version 21, epoch 0, cached adjacency 10.1.23.3
0 packets, 0 bytes
  tag information set
    local tag: 19
  via 10.1.23.3, FastEthernet0/1, 0 dependencies
    next hop 10.1.23.3, FastEthernet0/1
    valid cached adjacency
    tag rewrite with Fa0/1, 10.1.23.3, tags imposed: {}
R2#sh ip route 3.3.3.3
Routing entry for 3.3.3.3/32
  Known via “ospf 1”, distance 110, metric 11, type intra area
  Last update from 10.1.23.3 on FastEthernet0/1, 00:17:24 ago
  Routing Descriptor Blocks:
  * 10.1.23.3, from 3.3.3.3, 00:17:24 ago, via FastEthernet0/1
      Route metric is 11, traffic share count is 1

++++>> let us change the next hop of R2 for loopback address 3.3.3.3

R2(config)#ip route 3.3.3.3 255.255.255.255 10.1.12.1
R2(config)#end
R2# ship
*Mar  1 00:20:15.535: %SYS-5-CONFIG_I: Configured from console by consol
R2# sh ip route
Codes: 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

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/11] via 10.1.12.1, 00:19:09, FastEthernet0/0
     2.0.0.0/32 is subnetted, 1 subnets
C       2.2.2.2 is directly connected, Loopback1
     3.0.0.0/32 is subnetted, 1 subnets
S       3.3.3.3 [1/0] via 10.1.12.1
     10.0.0.0/24 is subnetted, 2 subnets
C       10.1.12.0 is directly connected, FastEthernet0/0
C       10.1.23.0 is directly connected, FastEthernet0/1
R2#traceroute 3.3.3.3 source 2.2.2.2

Type escape sequence to abort.
Tracing the route to 3.3.3.3

  1  *  *  *
  2  *  *  *
  3  *  *  *
  4  *  *  *
  5  *  *  *

  you can see it is unreachable plus the bytes tag switched is very high 846612 ???
  means packet is looping in the network.

R2#sh mpls forwarding-table 3.3.3.3
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
19     502         3.3.3.3/32        846612     Fa0/0      10.1.12.1
but reachable next hop is 10.1.23.3
so it will not form neighbour:

redo the static route and it will work:
on R2 : no ip route 3.3.3.3 255.255.255.255 10.1.12.1

it will form neighbour

R2(config)#no ip route 3.3.3.3 255.255.255.255 10.1.12.1
R2(config)#end
R2#ping
*Mar  1 00:23:25.963: %SYS-5-CONFIG_I: Configured from console by console
R2#ping 3.3.3.3 so 2.2.2.2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 3.3.3.3, timeout is 2 seconds:
Packet sent with a source address of 2.2.2.2
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 20/29/48 ms
R2#
*Mar  1 00:23:35.419: %LDP-5-NBRCHG: LDP Neighbor 3.3.3.3:0 (1) is UP

MPLS CHAPTER 3

MPLS CHAPTER 3
QUESTIONS :
8. How does the IGP next hop affect the LSP?
9. Why does LDP advertiese all local IPv4 address to a neighbor ?
10. By default , does the LSP path match the IPv4 path to a network ?
11. What is Liberal Label Retention ?

Solutions:
8. How does the IGP next hop affect the LSP?
9. Why does LDP advertiese all local IPv4 address to a neighbor ?

Follow the same diagram with same address scheme >

—>> IPv4 contorl plan build ospf RIB that is used by MPLS control plan
protocol LDP to build their Lable table (LIB) but data plan is quit different.

let us check RIB and binding tabel (LIB) of R2

R2#sh ip route ospf
     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/11] via 10.1.12.1, 00:29:55, FastEthernet0/0
     3.0.0.0/32 is subnetted, 1 subnets
O       3.3.3.3 [110/11] via 10.1.23.3, 00:07:39, FastEthernet0/1
R2#sh mpls ldp bin
R2#sh mpls ldp bindings 3.3.3.3
% Incomplete command.

R2#sh mpls ldp bindings 3.3.3.3 32
  tib entry: 3.3.3.3/32, rev 6
        local binding:  tag: 19
        remote binding: tsr: 1.1.1.1:0, tag: 502
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
R2#

you can see the RIB & LIB of route 3.3.3.3 of R2.

10. By default , does the LSP path match the IPv4 path to a network ?
11. What is Liberal Label Retention ?

LSP is driven by the IGP , We can manupulate with the MPLS-TE.
For a given router the upsteame and downstream labeling is liberal label
retention.

R2#sh mpls ldp neighbor
    Peer LDP Ident: 1.1.1.1:0; Local LDP Ident 2.2.2.2:0
        TCP connection: 1.1.1.1.646 – 2.2.2.2.38184
        State: Oper; Msgs sent/rcvd: 40/40; Downstream
        Up time: 00:28:33
        LDP discovery sources:
          FastEthernet0/0, Src IP addr: 10.1.12.1
        Addresses bound to peer LDP Ident:
          10.1.12.1       1.1.1.1
    Peer LDP Ident: 3.3.3.3:0; Local LDP Ident 2.2.2.2:0
        TCP connection: 3.3.3.3.25942 – 2.2.2.2.646
        State: Oper; Msgs sent/rcvd: 21/21; Downstream
        Up time: 00:11:48
        LDP discovery sources:
          FastEthernet0/1, Src IP addr: 10.1.23.3
        Addresses bound to peer LDP Ident:
          10.1.23.3       3.3.3.3

R2#sh mpls ldp bindings 1.1.1.1 32
  tib entry: 1.1.1.1/32, rev 2
        local binding:  tag: 18
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 22
R2#sh mpls ldp bindings 3.3.3.3 32
  tib entry: 3.3.3.3/32, rev 6
        local binding:  tag: 19
        remote binding: tsr: 1.1.1.1:0, tag: 502
        remote binding: tsr: 3.3.3.3:0, tag: imp-null

R2#sh mpls forwarding-table 1.1.1.1
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
18     Pop tag     1.1.1.1/32        0          Fa0/0      10.1.12.1
R2#sh mpls forwarding-table 3.3.3.3
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
19     Pop tag     3.3.3.3/32        0          Fa0/1      10.1.23.3

MPLS CHAPTER 4

MPLS CHAPTER 4
QUESTIONS:
12a. LSRs that get a packet with an unknown label what it will do ?
12b. What is PHP ?
13. What is relationsip between RIB/FIB , LIB/LFIB CEF ?
14. Which is preferred by CEF: MPLS or IPv4 forwarding ?
15. What are different type of labels used in MPLS ?
ANSWERS:

——->(LSR_ROUTER)——>
12a. LSRs that get a packet with an unknown label what it will do ?
12b. What is PHP ?
14. Which is preferred by CEF: MPLS or IPv4 forwarding ?
When pkt arrieves to router according to its label it forward pkt to next-hop
if it don’t have label information it will process according to IGP reachability.

incoming_pkt      outgoing_decision(data plan)
IPv4                 IPv4 (FIB)
IPv4                 MPLS (LFIB)
MPLS              MPLS (LFIB)
MPLS              IPv4  (FIB)

Penultimate Hop popping (PHP)
. Penultimate means netxt to last
. Normally last hop must ….
– Lookup MPLS Label
– Pop MPLS Label
– Lookup IPv4 destination
. PHP avoids extra lookup on last hop
. Accomplished through implicit NULL label
advertisement for connected prefixes.

13. What is relationsip between RIB/FIB , LIB/LFIB CEF ?

Check the diagram for : RIB/FIB & LIB/LFIB

either it is label/unlabelled pkt forwarding decision taken place with cef entry.
diagram:

let us check some output on R2 on the given diagram:
for RIB:
sh ip ospf 1 rib
for FIB
R2#sh ip route ospf 1
     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/11] via 10.1.12.1, 00:45:34, FastEthernet0/0
     3.0.0.0/32 is subnetted, 1 subnets
O       3.3.3.3 [110/11] via 10.1.23.3, 00:23:18, FastEthernet0/1
for LIB
R2#sh mpls ldp bindings
  tib entry: 1.1.1.1/32, rev 2
        local binding:  tag: 18
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 22
  tib entry: 2.2.2.2/32, rev 4
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 500
        remote binding: tsr: 3.3.3.3:0, tag: 23
  tib entry: 3.3.3.3/32, rev 6
        local binding:  tag: 19
        remote binding: tsr: 1.1.1.1:0, tag: 502
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
  tib entry: 10.1.12.0/24, rev 8
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 24
  tib entry: 10.1.23.0/24, rev 10
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 501
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
for LFIB 

R2#sh mpls forwarding-table
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
18     Pop tag     1.1.1.1/32        0          Fa0/0      10.1.12.1
19     Pop tag     3.3.3.3/32        0          Fa0/1      10.1.23.3

for particular CEF entry:
R2#sh ip cef 1.1.1.1 de
R2#sh ip cef 1.1.1.1 detail
1.1.1.1/32, version 20, epoch 0, cached adjacency 10.1.12.1
0 packets, 0 bytes
  tag information set
    local tag: 18
  via 10.1.12.1, FastEthernet0/0, 0 dependencies
    next hop 10.1.12.1, FastEthernet0/0
    valid cached adjacency
    tag rewrite with Fa0/0, 10.1.12.1, tags imposed: {}

15. What are different type of labels used in MPLS ?

Pop—The top label is removed. The packet is forwarded with the remaining label stack or as an unlabeled packet.
Swap—The top label is removed and replaced with a new label.
Push—The top label is replaced with a new label (swapped), and one or more labels are added (pushed) on top of the swapped label.
Untagged/No Label—The stack is removed, and the packet is forwarded unlabeled.
Aggregate—The label stack is removed, and an IP lookup is done on the IP packet.

MPLS CHAPTER 5

MPLS CHAPTER 5
QUESIONS :
16. How do you view the advertised transport address ?
17. What command changes the LDP router-id ?
18. When & how would you change the advertised transport address ?
19. What is MPLS label format ?

SOLUTIONS :
16. How do you view the advertised transport address ?
17. What command changes the LDP router-id ?
18. When & how would you change the advertised transport address ?

follow our diagram:

FOR ROUTER -ID
1. configured
2. highest loopback interface
3. highest physical interface

R2#sh mpls ldp discovery detail
 Local LDP Identifier:
    2.2.2.2:0
    Discovery Sources:
    Interfaces:
        FastEthernet0/0 (ldp): xmit/recv
            Enabled: Interface config
            Hello interval: 5000 ms; Transport IP addr: 2.2.2.2
            LDP Id: 1.1.1.1:0
              Src IP addr: 10.1.12.1; Transport IP addr: 1.1.1.1
              Hold time: 15 sec; Proposed local/peer: 15/15 sec
              Reachable via 1.1.1.1/32
        FastEthernet0/1 (ldp): xmit/recv
            Enabled: Interface config
            Hello interval: 5000 ms; Transport IP addr: 2.2.2.2
            LDP Id: 3.3.3.3:0
              Src IP addr: 10.1.23.3; Transport IP addr: 3.3.3.3
              Hold time: 15 sec; Proposed local/peer: 15/15 sec
              Reachable via 3.3.3.3/32
R2#sh ip route ospf
     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/11] via 10.1.12.1, 00:07:49, FastEthernet0/0
     3.0.0.0/32 is subnetted, 1 subnets
O       3.3.3.3 [110/11] via 10.1.23.3, 00:07:49, FastEthernet0/1

For R2 local label is 2.2.2.2 remot labels are 1.1.1.1 & 2.2.2.2 which has IGP routes.
for f0/0 transport address 1.1.1.1
for f0/1 transport address 2.2.2.2

Let us traceroute from R1 to R3 loopback :
R1#traceroute 3.3.3.3 source 1.1.1.1

Type escape sequence to abort.
Tracing the route to 3.3.3.3

  1 10.1.12.2 [MPLS: Label 17 Exp 0] 44 msec 60 msec 36 msec
  2 10.1.23.3 40 msec *  64 msec

if follow the LSP path : 

  now create new loopback on R2 make this router-id for MPLS path, and do not advertise
  into the IGP domain.

  Enter configuration commands, one per line.  End with CNTL/Z.
R2(config)#int l2
R2(config-if)#ip add 22.2.2.2 255.255.255.255
R2(config-if)#exit
R2(config)#mpls ldp router-id loopback 2 force
and then check the transport-address :
R2#sh mpls ldp discovery detail
 Local LDP Identifier:
    22.2.2.2:0
    Discovery Sources:
    Interfaces:
        FastEthernet0/0 (ldp): xmit/recv
            Enabled: Interface config
            Hello interval: 5000 ms; Transport IP addr: 22.2.2.2
            LDP Id: 1.1.1.1:0
              Src IP addr: 10.1.12.1; Transport IP addr: 1.1.1.1
              Hold time: 15 sec; Proposed local/peer: 15/15 sec
              Reachable via 1.1.1.1/32
        FastEthernet0/1 (ldp): xmit/recv
            Enabled: Interface config
            Hello interval: 5000 ms; Transport IP addr: 22.2.2.2
            LDP Id: 3.3.3.3:0
              Src IP addr: 10.1.23.3; Transport IP addr: 3.3.3.3
              Hold time: 15 sec; Proposed local/peer: 15/15 sec
              Reachable via 3.3.3.3/32

So R-ID and transport address has been changed do the tracerout from the R1-R3 loopback
now you can see it does not follow the LSP(mpls) path. ?????

now advertise loopback into ospf on R2
R2(config)#router ospf 1
R2(config-router)#net 22.2.2.2 0.0.0.0 ar 0
R2(config-router)#
*Mar  1 01:13:55.683: %LDP-5-NBRCHG: LDP Neighbor 3.3.3.3:0 (1) is UP
R2(config-router)#
*Mar  1 01:13:56.951: %LDP-5-NBRCHG: LDP Neighbor 1.1.1.1:0 (2) is UP

R1#
*Mar  1 01:13:47.903: %LDP-5-NBRCHG: LDP Neighbor 22.2.2.2:0 (1) is UP
R1#traceroute 3.3.3.3 source 1.1.1.1

Type escape sequence to abort.
Tracing the route to 3.3.3.3

  1 10.1.12.2 [MPLS: Label 17 Exp 0] 60 msec 40 msec 44 msec
  2 10.1.23.3 56 msec *  48 msec

  now it follow the LSP(mpls path) WoW !!!!


19. What is MPLS label format ?

mpls label format:
20 bit label : locally significant to router
3 bit Exp = class of service
S bit = defines last label in the label stack
8 bit TTL

MPLS CHAPTER 6

MPLS CHAPTER 6
QUUESTIONS :

20. In MPLS L3VPN how do the customer & provider share routes ?
21. Why does a PE have a VRF for each customer ? What is VRF ?
22. Which protocol is used between PE’s to advertise VPNv4 routes ?

Solutions :
20. In MPLS L3VPN how do the customer & provider share routes ?
21. Why does a PE have a VRF for each customer ? What is VRF ?

HOW MPLS L3VPNs Work
. MPLS L3VPNs have two basic components
. Separation of Customer routing information
-Virtual Routing & Forwarding VRF instance
– Customers have different “virtual” routing tables
. Exchange of customer routing information
– MP-BGP over the MPLS network
– Traffic is label switched towards BGP next-hops

VRF
. each VRF has its own routing table
– show ip route vrf [name | * ]
. Interfaes not in a VRF are in the global table
– show ip route
. VRF and global routes are separate
– implies addressing can overlap in different VRFs
– implies VRFs cant talk to each other because they have no
   routes to each other
. VRFs without MPLS is considered “VRF Lite”

PE routers stores routing table of all the customers:
as shown in diagram:

22. Which protocol is used between PE’s to advertise VPNv4 routes ?

Multiprotocol BGP
 . RFC 4364 “BGP/MPLS IP Virtual Private Networks (VPNs) “
 – MP-BGP define AFI & SAFI 128 as VPN-iPv4 or VPNv4

MPLS CHAPTER 7


QUESTIONS :
23. What command is used to enter the “VPNv4 Section” of BGP ?
24. What is use of Extended Community ?
25. Why would you activate VPNv4 capability with an iBGP peer ?
26. What are to commands to activate VPNv4 feature ?
Solution:
23. What command is used to enter the “VPNv4 Section” of BGP ?
24. What is use of Extended Community ?

– VPNv4 Route
. RD + Prefix makes VPN routes globally unique
– MPLS VPN label
. PE routers exchange label for each customer route via VPNv4
– Transport Label
. Label towards PE’s BGP next-hop

VPNv4 bgp has two jobs to get the label information , remote label
information.

payload information:

|transport lable|vpn label|IP | TCP | WWW |
(which PE)       (which cust)

Route distinguiser (RD)

– ASN:nn or IP-addres:nn
  vrf rd are locally significant to give them globally significance
  we are using route-targets.

  VPNv4 Route Target:
. 8 byte field per RFC 4360 “BGP Extended Communities Attribute”
. Format Similar to route distinguisher
– ASN:nn or IP-addres:nn
. VPNv4 speakers only accept VPNv4 routes with a route-target matching
  a local VRF
  – Route reflection exception
  – no bgp default route-target filter

  Controlling VPNv4 Routes:
. Route distinguisher used solely to make route unique
. New BGP extended Community “route-target” used to control
  what enters/exits VRF table
. “export” route-target  vrf —-> bgp
. “import” vrf <—– bgp
. Allows granular control over what sites have what routes
– import map & export map allow control on a per prefix basis

26. What are to commands to activate VPNv4 feature ?

In diagram let us enable VPNv4 on both PE’s

dia:

on PE-R1
PE0R1#sh run | se bgp
router bgp 100
 no synchronization
 bgp log-neighbor-changes
 neighbor 3.3.3.3 remote-as 100
 neighbor 3.3.3.3 update-source Loopback1
 no auto-summary
 !
 address-family vpnv4
  neighbor 3.3.3.3 activate
  neighbor 3.3.3.3 send-community extended
 exit-address-family

 on PE-R3
 PE0R3#sh run | se bgp
router bgp 100
 no synchronization
 bgp log-neighbor-changes
 neighbor 1.1.1.1 remote-as 100
 neighbor 1.1.1.1 update-source Loopback1
 no auto-summary
 !
 address-family vpnv4
  neighbor 1.1.1.1 activate
  neighbor 1.1.1.1 send-community extended
 exit-address-family

some more verification commands:

PE0R1#sh ip bgp neighbors | se capabilities
  Neighbor capabilities:
    Route refresh: advertised and received(old & new)
    Address family IPv4 Unicast: advertised and received
    Address family VPNv4 Unicast: advertised and received

# sh control-plan host open-ports

MPLS CHAPTER 8

MPLS CHAPTER 8:
Questions:
27. What keeps your customers routes unique from each other in mBGP ?
28. How do you assign a PE interface to a VRF ?

Solution:
VRF Name        R1-PE           R3-PE
Cust_site1    101:Cust_site1   101:Cust_site1
Cust_site2    102:Cust_site2   102:Cust_site2

Route Distinguisher
Cust_site1    1.1.1.1:1         3.3.3.3:1
Cust_site2    1.1.1.1:2         3.3.3.3:2

Route Targets
Cust_site1 export 1.1.1.1:101   3.3.3.3:101
Cust_site1 import 3.3.3.3:101   1.1.1.1:101
Cust_site2 export 1.1.1.1:102   3.3.3.3:102
Cust_site2 import 3.3.3.3:102   1.1.1.1:102

Attached interface :

Attached interfaces:
Cust_site1  fa0/1          s0/0
Cust_site2  s0/0           f0/0

Flow of traffic: CE-CE

CE Advertised route -> ipv4 route sent from CE to PE ->Recieved on VRF->
-> Exported to BGP as VPNv4 route with RD/RT -> send PE to PE ->
Imported into VRF based on RT -> IPv4 Route sent from PE to CE -> CE learnd route

Let us start the Lab:
How to enable vrf & assign to particular interface:
With our Diagram:

PE0R1(config)#ip vrf Cust_site1
PE0R1(config-vrf)#rd 1.1.1.1:1
PE0R1(config-vrf)#route-target export 1.1.1.1:101
PE0R1(config-vrf)#route-target import 3.3.3.3:101
PE0R1(config)#ip vrf Cust_site2
PE0R1(config-vrf)#rd 1.1.1.1:2
PE0R1(config-vrf)#route-target export 1.1.1.1:102
PE0R1(config-vrf)#route-target import 3.3.3.3:102

PE0R1#sh ip vrf
  Name                             Default RD          Interfaces
  Cust_site1                       1.1.1.1:1
  Cust_site2                       1.1.1.1:2
PE0R1#sh run  | se ip vrf
ip vrf Cust_site1
 rd 1.1.1.1:1
 route-target export 1.1.1.1:101
 route-target import 3.3.3.3:101
ip vrf Cust_site2
 rd 1.1.1.1:2
 route-target export 1.1.1.1:102
 route-target import 3.3.3.3:102
PE0R1#! Assign to particular interface
PE0R1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
PE0R1(config)#int fa0/1
PE0R1(config-if)#ip vrf forwarding Cust_site1
% Interface FastEthernet0/1 IP address 10.1.14.1 removed due to enabling VRF Cust_site1
PE0R1(config-if)#ip add 10.1.14.1 255.255.255.0
PE0R1(config-if)#int s0/0
PE0R1(config-if)#ip vrf forwarding Cust_site2
% Interface Serial0/0 IP address 10.1.15.1 removed due to enabling VRF Cust_site2
PE0R1(config-if)#ip add 10.1.15.1 255.255.255.0
PE0R1(config-if)#do sh ip vrf
  Name                             Default RD          Interfaces
  Cust_site1                       1.1.1.1:1           Fa0/1
  Cust_site2                       1.1.1.1:2           Se0/0

PE0R3(config)#ip vrf Cust_site1
PE0R3(config-vrf)#rd 3.3.3.3:1
PE0R3(config-vrf)#route-target import 1.1.1.1:101
PE0R3(config-vrf)#route-target export 3.3.3.3:101
PE0R3(config-vrf)#ip vrf Cust_site2
PE0R3(config-vrf)#rd 3.3.3.3:2
PE0R3(config-vrf)#route-target import 1.1.1.1:102
PE0R3(config-vrf)#route-target export 3.3.3.3:102
PE0R3(config-vrf)#int s0/0
PE0R3(config-if)#ip vrf forwarding Cust_site1
% Interface Serial0/0 IP address 10.1.36.3 removed due to enabling VRF Cust_site1
PE0R3(config-if)#ip add 10.1.36.3 255.255.255.0
PE0R3(config-if)#int fa0/0
PE0R3(config-if)#ip vrf forwarding Cust_site2
% Interface FastEthernet0/0 IP address 10.1.37.3 removed due to enabling VRF Cust_site2
PE0R3(config-if)#ip add 10.1.37.3 255.255.255.0
PE0R3(config-if)#no sh
PE0R3(config-if)#do sh ip vrf
  Name                             Default RD          Interfaces
  Cust_site1                       3.3.3.3:1           Se0/0
  Cust_site2                       3.3.3.3:2           Fa0/0

PE0R3#sh ip vrf detail
VRF Cust_site1; default RD 3.3.3.3:1; default VPNID <not set>
  Interfaces:
    Se0/0
  Connected addresses are not in global routing table
  Export VPN route-target communities
    RT:3.3.3.3:101
  Import VPN route-target communities
    RT:1.1.1.1:101
  No import route-map
  No export route-map
  VRF label distribution protocol: not configured
VRF Cust_site2; default RD 3.3.3.3:2; default VPNID <not set>
  Interfaces:
    Fa0/0
  Connected addresses are not in global routing table
  Export VPN route-target communities
    RT:3.3.3.3:102
  Import VPN route-target communities
    RT:1.1.1.1:102
  No import route-map
  No export route-map
  VRF label distribution protocol: not configured

MPLS CHAPTER 9

MPLS CHAPTER 9
QUESTIONS :
29. Which command shows you the routes inside the VRF ?
30. What does ‘address-family ipv4’ mean within EIGRP & RIP ?
31. How do you link an OSPF process to a specific VRF ?

Solutions:

Refer the diagram below:

29. Which command shows you the routes inside the VRF ?
PE0R1#sh ip route vrf Cust_site1

Routing Table: Cust_site1
Codes: 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

Gateway of last resort is not set

     4.0.0.0/32 is subnetted, 1 subnets
O       4.4.4.1 [110/11] via 10.1.14.4, 00:13:56, FastEthernet0/1
     10.0.0.0/24 is subnetted, 1 subnets
C       10.1.14.0 is directly connected, FastEthernet0/1
PE0R1#sh ip route vrf Cust_site2

Routing Table: Cust_site2
Codes: 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

Gateway of last resort is not set

     5.0.0.0/32 is subnetted, 1 subnets
D       5.5.5.1 [90/2297856] via 10.1.15.5, 00:07:50, Serial0/0
     7.0.0.0/32 is subnetted, 1 subnets
B       7.7.7.1 [200/0] via 3.3.3.3, 00:04:47
     10.0.0.0/24 is subnetted, 2 subnets
C       10.1.15.0 is directly connected, Serial0/0
B       10.1.37.0 [200/0] via 3.3.3.3, 00:04:47

30. What does ‘address-family ipv4’ mean within EIGRP & RIP ?

PE0R1#sh run | se eigrp
router eigrp 1
 auto-summary
 !
 address-family ipv4 vrf Cust_site2
  network 10.0.0.0
  no auto-summary
  autonomous-system 15
 exit-address-family

 PE0R3#sh run | se rip
router rip
 version 2
 !
 address-family ipv4 vrf Cust_site1
  network 10.0.0.0
  no auto-summary
 exit-address-family

 31. How do you link an OSPF process to a specific VRF ?
 32. How to enable BGP within address-family ?

router ospf 101 vrf Cust_site1
 log-adjacency-changes
 network 10.1.14.0 0.0.0.255 area 0
 32. How to enable BGP within address-family ?

 PE0R3#sh run | se bgp
router bgp 100
 no synchronization
 bgp log-neighbor-changes
 neighbor 1.1.1.1 remote-as 100
 neighbor 1.1.1.1 update-source Loopback1
 no auto-summary
 !
 address-family vpnv4
  neighbor 1.1.1.1 activate
  neighbor 1.1.1.1 send-community extended
  neighbor 1.1.1.1 next-hop-self
 exit-address-family
 !
 address-family ipv4 vrf Cust_site2
  neighbor 10.1.37.7 remote-as 200
  neighbor 10.1.37.7 activate
  no synchronization
 exit-address-family
 !

MPLS CHAPTER 10

MPLS CHAPTER 10
 QUESTIONS:
33. Why is redistribution needed in MPLS L3VPN ?
 34. When is a RD, RT and VPN label added to a route ?
 35. In BGP configuration are you causing an Import or Export ?

 Solution :
 33. Why is redistribution needed in MPLS L3VPN ?
 –> For the Communication of VRF aware routes of PE to global routes of
      CE we are doing redistribution.

34. When is a RD, RT and VPN label added to a route ?

CE Advertised route -> ipv4 route sent from CE to PE ->Recieved on VRF->
-> Exported to BGP as VPNv4 route with RD/RT -> send PE to PE ->
Imported into VRF based on RT -> IPv4 Route sent from PE to CE -> CE learnd route

–> when routes Reaches from CE to PE , PE export routes to MPBGP with
Local RD , RT(export) and send to other PE router.

35. In BGP configuration are you causing an Import or Export ?

–> It depends upon which MPLS topology we are using :

VPNv4 routes can have more than one route target
  . allows for complex VPN topologies
  full mesh
  import and export same everywhere
  hub and spoke
  spokes import only hubs routes
  Central services
  Multiple VPNs can import from a central site or from a central serv
  Managment VPNs
  Management Loopback on CE routers can be exported into special
  management VPN.

 Let us do it with our example:

 diag :

PE0R1 CONFIG :

PE0R1#sh run | se ospf
router ospf 101 vrf Cust_site1
 log-adjacency-changes
 redistribute bgp 100 metric 555 subnets
 network 10.1.14.0 0.0.0.255 area 0
router ospf 1
 log-adjacency-changes
 network 0.0.0.0 255.255.255.255 area 0
  redistribute ospf 101 vrf Cust_site1
PE0R1#sh run | se eigrp
router eigrp 1
 auto-summary
 !
 address-family ipv4 vrf Cust_site2
  redistribute bgp 100 metric 1 1 1 1 1
  network 10.0.0.0
  no auto-summary
  autonomous-system 15
 exit-address-family
router eigrp 15
 auto-summary
  redistribute eigrp 15
PE0R1#sh run | se bgp
  redistribute bgp 100 metric 1 1 1 1 1
 redistribute bgp 100 metric 555 subnets
router bgp 100
 no synchronization
 bgp log-neighbor-changes
 neighbor 3.3.3.3 remote-as 100
 neighbor 3.3.3.3 update-source Loopback1
 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_site2
  redistribute eigrp 15
  no synchronization
 exit-address-family
 !
 address-family ipv4 vrf Cust_site1
  redistribute ospf 101 vrf Cust_site1
  no synchronization
 exit-address-family

 PE0R1#sh bgp vpnv4 unicast vrf Cust_site1
BGP table version is 17, local router ID is 1.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i – internal,
              r RIB-failure, S Stale
Origin codes: i – IGP, e – EGP, ? – incomplete

   Network          Next Hop            Metric LocPrf Weight Path
Route Distinguisher: 1.1.1.1:1 (default for vrf Cust_site1)
*> 4.4.4.1/32       10.1.14.4               11         32768 ?
*>i6.6.6.1/32       3.3.3.3                  1    100      0 ?
*> 10.1.14.0/24     0.0.0.0                  0         32768 ?
*>i10.1.36.0/24     3.3.3.3                  0    100      0 ?
PE0R1#sh bgp vpnv4 unicast vrf Cust_site1 4.4.4.1/32
BGP routing table entry for 1.1.1.1:1:4.4.4.1/32, version 8
Paths: (1 available, best #1, table Cust_site1)
  Advertised to update-groups:
     1
  Local
    10.1.14.4 from 0.0.0.0 (1.1.1.1)
      Origin incomplete, metric 11, localpref 100, weight 32768, valid, sourced, best
      Extended Community: OSPF DOMAIN ID:0x0005:0x000000650200 RT:1.1.1.1:101
        OSPF RT:0.0.0.0:2:0 OSPF ROUTER ID:10.1.14.1:0
      mpls labels in/out 503/nolabel
PE0R1#sh bgp vpnv4 unicast vrf Cust_site1 6.6.6.1/32
BGP routing table entry for 1.1.1.1:1:6.6.6.1/32, version 16
Paths: (1 available, best #1, table Cust_site1)
  Not advertised to any peer
  Local, imported path from 3.3.3.3:1:6.6.6.1/32
    3.3.3.3 (metric 21) from 3.3.3.3 (3.3.3.3)
      Origin incomplete, metric 1, localpref 100, valid, internal, best
      Extended Community: RT:3.3.3.3:101
      mpls labels in/out nolabel/21

FOR ROUTER PE0R3:

PE0R3#sh run | se rip
router rip
 version 2
 !
 address-family ipv4 vrf Cust_site1
  redistribute bgp 100 metric 3
  network 10.0.0.0
  no auto-summary
 exit-address-family
  redistribute rip
PE0R3#sh run | se bgp
  redistribute bgp 100 metric 3
router bgp 100
 no synchronization
 bgp log-neighbor-changes
 neighbor 1.1.1.1 remote-as 100
 neighbor 1.1.1.1 update-source Loopback1
 no auto-summary
 !
 address-family vpnv4
  neighbor 1.1.1.1 activate
  neighbor 1.1.1.1 send-community extended
  neighbor 1.1.1.1 next-hop-self
 exit-address-family
 !
 address-family ipv4 vrf Cust_site2
  neighbor 10.1.37.7 remote-as 200
  neighbor 10.1.37.7 activate
  no synchronization
 exit-address-family
 !
 address-family ipv4 vrf Cust_site1
  redistribute rip
  no synchronization
 exit-address-family

PE0R3#sh bgp vpnv4 unicast vrf Cust_site1
BGP table version is 16, local router ID is 3.3.3.3
Status codes: s suppressed, d damped, h history, * valid, > best, i – internal,
              r RIB-failure, S Stale
Origin codes: i – IGP, e – EGP, ? – incomplete

   Network          Next Hop            Metric LocPrf Weight Path
Route Distinguisher: 3.3.3.3:1 (default for vrf Cust_site1)
*>i4.4.4.1/32       1.1.1.1                 11    100      0 ?
*> 6.6.6.1/32       10.1.36.6                1         32768 ?
*>i10.1.14.0/24     1.1.1.1                  0    100      0 ?
*> 10.1.36.0/24     0.0.0.0                  0         32768 ?
PE0R3#sh bgp vpnv4 unicast vrf Cust_site2
BGP table version is 16, local router ID is 3.3.3.3
Status codes: s suppressed, d damped, h history, * valid, > best, i – internal,
              r RIB-failure, S Stale
Origin codes: i – IGP, e – EGP, ? – incomplete

   Network          Next Hop            Metric LocPrf Weight Path
Route Distinguisher: 3.3.3.3:2 (default for vrf Cust_site2)
*>i5.5.5.1/32       1.1.1.1            2297856    100      0 ?
*> 7.7.7.1/32       10.1.37.7                0             0 200 ?
*>i10.1.15.0/24     1.1.1.1                  0    100      0 ?
r> 10.1.37.0/24     10.1.37.7                0             0 200 ?
PE0R3#sh bgp vpnv4 unicast vrf Cust_site2 5.5.5.1/32
BGP routing table entry for 3.3.3.3:2:5.5.5.1/32, version 11
Paths: (1 available, best #1, table Cust_site2)
  Advertised to update-groups:
     1
  Local, imported path from 1.1.1.1:2:5.5.5.1/32
    1.1.1.1 (metric 21) from 1.1.1.1 (1.1.1.1)
      Origin incomplete, metric 2297856, localpref 100, valid, internal, best
      Extended Community: RT:1.1.1.1:102
        Cost:pre-bestpath:128:2297856 (default-2145185791) 0x8800:32768:0
        0x8801:15:640000 0x8802:65281:1657856 0x8803:65281:1500
      mpls labels in/out nolabel/505
PE0R3#sh bgp vpnv4 unicast vrf Cust_site2 7.7.7.1/32
BGP routing table entry for 3.3.3.3:2:7.7.7.1/32, version 2
Paths: (1 available, best #1, table Cust_site2)
  Advertised to update-groups:
     2
  200
    10.1.37.7 from 10.1.37.7 (7.7.7.1)
      Origin incomplete, metric 0, localpref 100, valid, external, best
      Extended Community: RT:3.3.3.3:102
      mpls labels in/out 19/nolabel

MPLS CHAPTER 11 (TROUBLESHOOTING & FULL CONFIG )

MPLS CHAPTER 11 (TROUBLESHOOTING & FULL CONFIG )

In this blog you will get full config & troubleshooting steps:
Points:
1. VRF ( RD , RT import — RT export )
2. Assign VRF
3. Enable VRF aware Routing Process
4. VPNv4 Peers ( PE routers redistibuted routes)
5. Redistribution

Troubleshooting of mpls vpn

we check the control plan & data plan
sh ip vrf
sh ip vrf detail
– we can check the import and export
sh ip route vrf Cust_site1
– checking routes are coming or not
sh bgp vpnv4 unicast vrf Cust_site2
– it is redistributed on bgp or not
sh bgp vpnv4 unicast vrf Cust_site1 4.4.4.1/32
attributes of vrf
debug mpls packates

sh bgp vpnv4 unicast all
sh bgp vpnv4 unicast all 4.4.4.1/32
sh mpls interfaces

To check the mpls labels :

trasport label| vpnv4 label| payload
which PE       which Customer
26|25|icmp
25 is vpnv4 label not changed . it will changed at PE router.

  sh ip bgp vpnv4 rd 1.1.1.1:1 labels
  sh ip bgp vpnv4 rd 1.1.1.1:2 labels
  sh bgp vpnv4 unicast vrf Cust_site1 labels
  sh bgp vpnv4 unicast vrf Cust_site2 labels
  sh ip cef vrf Cust_site1 4.4.4.1
  sh ip cef vrf Cust_site1 6.6.6.1

PE0R1#sh ip cef vrf Cust_site1 6.6.6.1
6.6.6.1/32, version 22, epoch 0, cached adjacency 10.1.12.2
0 packets, 0 bytes
  tag information set
    local tag: VPN-route-head
    fast tag rewrite with Fa0/0, 10.1.12.2, tags imposed: {16 21}
  via 3.3.3.3, 0 dependencies, recursive
    next hop 10.1.12.2, FastEthernet0/0 via 3.3.3.3/32
    valid cached adjacency
    tag rewrite with Fa0/0, 10.1.12.2, tags imposed: {16 21}

{16 21}  here : 16 is top label and 21 is vpn label .

===============================================================
config file of this lab:
diag :

—– Config—
!
!
hostname PE0R1
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
!
!
ip vrf Cust_site1
rd 1.1.1.1:1
route-target export 1.1.1.1:101
route-target import 3.3.3.3:101
!
ip vrf Cust_site2
rd 1.1.1.1:2
route-target export 1.1.1.1:102
route-target import 3.3.3.3:102
!
no ip domain lookup
ip auth-proxy max-nodata-conns 3
ip admission max-nodata-conns 3
!
mpls label range 500 599
!
!
interface Loopback1
ip address 1.1.1.1 255.255.255.255
!
interface FastEthernet0/0
ip address 10.1.12.1 255.255.255.0
duplex auto
speed auto
mpls ip
!
interface Serial0/0
ip vrf forwarding Cust_site2
ip address 10.1.15.1 255.255.255.0
clock rate 2000000
!
interface FastEthernet0/1
ip vrf forwarding Cust_site1
ip address 10.1.14.1 255.255.255.0
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
clock rate 2000000
!
router eigrp 1
auto-summary
!
address-family ipv4 vrf Cust_site2
redistribute bgp 100 metric 1 1 1 1 1
network 10.0.0.0
no auto-summary
autonomous-system 15
exit-address-family
!
router eigrp 15
auto-summary
!
router ospf 101 vrf Cust_site1
log-adjacency-changes
redistribute bgp 100 metric 555 subnets
network 10.1.14.0 0.0.0.255 area 0
!
router ospf 1
log-adjacency-changes
network 0.0.0.0 255.255.255.255 area 0
!
router bgp 100
no synchronization
bgp log-neighbor-changes
neighbor 3.3.3.3 remote-as 100
neighbor 3.3.3.3 update-source Loopback1
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_site2
redistribute eigrp 15
no synchronization
exit-address-family
!
address-family ipv4 vrf Cust_site1
redistribute ospf 101 vrf Cust_site1
no synchronization
exit-address-family
!
ip forward-protocol nd
!
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

!
!
hostname P0R2
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
!
!
interface Loopback1
ip address 2.2.2.2 255.255.255.255
!
interface FastEthernet0/0
ip address 10.1.12.2 255.255.255.0
duplex auto
speed auto
mpls ip
!
interface FastEthernet0/1
ip address 10.1.23.2 255.255.255.0
duplex auto
speed auto
mpls ip
!
router ospf 1
log-adjacency-changes
network 0.0.0.0 255.255.255.255 area 0
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end


!
hostname PE0R3
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
!
!
ip vrf Cust_site1
rd 3.3.3.3:1
route-target export 3.3.3.3:101
route-target import 1.1.1.1:101
!
ip vrf Cust_site2
rd 3.3.3.3:2
route-target export 3.3.3.3:102
route-target import 1.1.1.1:102
!
no ip domain lookup
ip auth-proxy max-nodata-conns 3
ip admission max-nodata-conns 3
!
!
interface Loopback1
ip address 3.3.3.3 255.255.255.255
!
interface FastEthernet0/0
ip vrf forwarding Cust_site2
ip address 10.1.37.3 255.255.255.0
duplex auto
speed auto
!
interface Serial0/0
ip vrf forwarding Cust_site1
ip address 10.1.36.3 255.255.255.0
clock rate 2000000
!
interface FastEthernet0/1
ip address 10.1.23.3 255.255.255.0
duplex auto
speed auto
mpls ip
!
interface Serial0/1
no ip address
shutdown
clock rate 2000000
!
router ospf 1
log-adjacency-changes
network 0.0.0.0 255.255.255.255 area 0
!
router rip
version 2
!
address-family ipv4 vrf Cust_site1
redistribute bgp 100 metric 3
network 10.0.0.0
no auto-summary
exit-address-family
!
router bgp 100
no synchronization
bgp log-neighbor-changes
neighbor 1.1.1.1 remote-as 100
neighbor 1.1.1.1 update-source Loopback1
no auto-summary
!
address-family vpnv4
neighbor 1.1.1.1 activate
neighbor 1.1.1.1 send-community extended
neighbor 1.1.1.1 next-hop-self
exit-address-family
!
address-family ipv4 vrf Cust_site2
neighbor 10.1.37.7 remote-as 200
neighbor 10.1.37.7 activate
no synchronization
exit-address-family
!
address-family ipv4 vrf Cust_site1
redistribute rip
no synchronization
exit-address-family
!
ip forward-protocol nd
!
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

!
!
hostname R4
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
interface Loopback1
ip address 4.4.4.1 255.255.255.255
!
interface FastEthernet0/0
no ip address
shutdown
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 10.1.14.4 255.255.255.0
duplex auto
speed auto
!
router ospf 1
log-adjacency-changes
network 4.4.4.1 0.0.0.0 area 0
network 10.1.14.0 0.0.0.255 area 0
!
ip forward-protocol nd
!
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

!
!
hostname R5
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
interface Loopback1
ip address 5.5.5.1 255.255.255.255
!
interface FastEthernet0/0
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0
ip address 10.1.15.5 255.255.255.0
clock rate 2000000
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
clock rate 2000000
!
router eigrp 15
network 5.0.0.0
network 10.0.0.0
no auto-summary
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

!
!
hostname R6
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
interface Loopback1
ip address 6.6.6.1 255.255.255.255
!
interface FastEthernet0/0
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0
ip address 10.1.36.6 255.255.255.0
clock rate 2000000
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
clock rate 2000000
!
router rip
version 2
network 6.0.0.0
network 10.0.0.0
no auto-summary
!
ip forward-protocol nd
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

!
!
hostname R7
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
ip cef
!
!
interface Loopback1
ip address 7.7.7.1 255.255.255.255
!
interface FastEthernet0/0
ip address 10.1.37.7 255.255.255.0
duplex auto
speed auto
!
interface Serial0/0
no ip address
shutdown
clock rate 2000000
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
clock rate 2000000
!
router bgp 200
no synchronization
bgp log-neighbor-changes
redistribute connected
neighbor 10.1.37.3 remote-as 100
no auto-summary
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
login
!
!

end

2 thoughts on “MPLS – Understand MPLS Basics

  1. Shawnee says:

    Pretty! This has been an incredibly wonderful article.
    Many thanks for supplying this information.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *