LDP and loopbacks

(Raul D) #1

Hi Rene,

I would like to ask you a question. I was doing a LAB between 2 PE. Both PEs had a MPBGP configuration to transport the two VRFs via iBGP. My BGP configuration, the neighbor, was the physical interface, not the loopbacks between them, and didn’t work at all, I mean, I saw how the networks were learning by BGP but the ping didn’t respond.

I realized that transport LABEL in one PE didn’t create in the LFIB and when I did the command show ip cef vrf 1 x.x.x.x I didn’t see the transport Label, I saw only the VPN label.

At the end, I changed in the BGP neighbor: instead physical interface, the loopbacks, and configured updated-interface loopback0, and started work. I saw the transport label and the ping worked fine.

Why this? If I am not wrong, the Transport LABEL depends on the next-hop address of the BGP right? but the issue is that I didn’t see the next-hop address in the LFIB (show mpls forwarding). Everything started work once I changed the neighbor to the loopbacks and I configured neighbor x1.x1.x1.x1 update-interface loopback.

Thanks for your help!

Best Regards

0 Likes

(Rene Molenaar) #2

Hi Raul,

The problem is that your P router will drop the traffic between the PE routers. Let me give you an example, I’ll use the topology from this lesson:

Here is the LFIB of the PE1, PE2 and P router when we use loopbacks on the PE routers:

PE1#show mpls forwarding-table 
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface              
16         Pop Label  3.3.3.3/32       0             Gi0/2      192.168.23.3
17         Pop Label  192.168.34.0/24  0             Gi0/2      192.168.23.3
P#show mpls for
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface              
16         Pop Label  2.2.2.2/32       1259          Gi0/1      192.168.23.2
17         Pop Label  4.4.4.4/32       1259          Gi0/2      192.168.34.4
PE2#show mpls for
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface              
16         16         2.2.2.2/32       0             Gi0/2      192.168.34.3
17         Pop Label  3.3.3.3/32       0             Gi0/2      192.168.34.3
18         Pop Label  192.168.23.0/24  0             Gi0/2      192.168.34.3
19         No Label   5.5.5.5/32[V]    570           Gi0/1      192.168.45.5

The iBGP neighbor adjacency has been established between 2.2.2.2 (PE1) and 4.4.4.4 (PE1) and you can see we have a LSP. The PE routers add a label, the P router receives it, pops it and forwards it.

Here’s what the LFIB looks like if you use the physical interfaces, 192.168.12.1 (PE1) and 192.168.34.4 (PE2):

PE1#show mpls forwarding-table 
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface              
16         Pop Label  3.3.3.3/32       0             Gi0/2      192.168.23.3
17         Pop Label  192.168.34.0/24  0             Gi0/2      192.168.23.3
P#show mpls forwarding-table 
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface
PE2#show mpls forwarding-table 
Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
Label      Label      or Tunnel Id     Switched      interface              
17         Pop Label  3.3.3.3/32       0             Gi0/2      192.168.34.3
18         Pop Label  192.168.23.0/24  0             Gi0/2      192.168.34.3
20         No Label   5.5.5.5/32[V]    0             Gi0/1      192.168.45.5

As you can see above, there’s no LSP. The PE routers don’t add a label when they want to reach each other. When the P router receives something from the PE routers, it won’t know how to forward it and drop it.

Rene

0 Likes

(Raul D) #3

Hi Rene,

Thanks for the good explanation. Do you know why the PE doesn’t add the label when the iBGP is stablished with the physical interface? I would like to know if there is some rule which explain that you must to configure iBGP with loopbacks between neighbors, to works.

Thanks again,

Best Regards!

0 Likes

(Rene Molenaar) #4

Hi Raul,

This is because of PHP (Penultimate Hop Popping).

When we use PHP, the label is removed one “hop” before the last router in the LSP.

Here’s an example why this could be useful:

Let’s say we send traffic from PE1 > P > PE2. When PE2 receives something, it will have to do a label lookup and an IP lookup before it can forward the packet to the customer router. Doing two lookups takes more resources than just one lookup.

To save some resources, the P router will already remove the label before it forwards something to PE2. In this case, PE2 only has to do an IP lookup before it can forward something to the customer router. This saves some resources on the PE routers.

So what about the directly connected interfaces? When you want to reach a device that is directly connected, there is no next hop address. We need to check the ARP table, figure out the destination MAC address of the destination device and create a new L2 frame. Because we have to do this lookup, there’s no point adding another label on top. LDP will advertise a null label to other LDP neighbors, telling them they don’t have to add a label for directly connected networks.

Hope this helps.

Rene

0 Likes

(Raul D) #5

Hi Rene,

Awesome! I understand the concept now.

Thanks a lot!!

Raul

0 Likes