1 2 Previous Next 21 Replies Latest reply: Jan 4, 2018 1:58 AM by Sergey RSS

    MPLS VPN - BGP Lab

    Mahmoud

      Hello everyone,

       

      I am doing an MPLS VPN lab with BGP as PE-CE routing protocol and the HQ,Branch cant reach each other but they can ping their connected PEs. Below configuration

      also attached GNS3 file for who want to make live check.

       

      Thanks in Advance,

      top.png

       

       

       

       

       

      HQ#

      interface Loopback0

      ip address 1.1.1.1 255.255.255.0

      !

      interface FastEthernet0/0

      ip address 192.168.12.1 255.255.255.0

      duplex auto

      speed auto

      !

      router bgp 100

      no synchronization

      bgp log-neighbor-changes

      network 1.1.1.0 mask 255.255.255.0

      network 192.168.12.0

      neighbor 192.168.12.2 remote-as 1

      neighbor 192.168.12.2 update-source Loopback0

      no auto-summary

      !

      ip http server

      no ip http secure-server

      !

      ========================================================

       

      PE1#sh running-config

      Building configuration...

       

      Current configuration : 1440 bytes

      !

      version 12.4

      service timestamps debug datetime msec

      service timestamps log datetime msec

      no service password-encryption

      !

      hostname PE1

      !

      boot-start-marker

      boot-end-marker

      !

      !

      no aaa new-model

      memory-size iomem 5

      !

      !

      ip cef

      !

      !

      ip vrf BM

      rd 100:1

      route-target export 1:100

      route-target import 1:100

      !

      interface Loopback0

      ip address 2.2.2.2 255.255.255.0

      ip ospf network point-to-point

      !

      interface FastEthernet0/0

      ip address 192.168.23.2 255.255.255.0

      duplex auto

      speed auto

      !

      interface FastEthernet1/0

      ip vrf forwarding BM

      ip address 192.168.12.2 255.255.255.0

      duplex auto

      speed auto

      !

      router ospf 1

      log-adjacency-changes

      network 2.2.2.0 0.0.0.255 area 0

      network 192.168.23.0 0.0.0.255 area 0

      !

      router bgp 1

      no synchronization

      bgp log-neighbor-changes

      neighbor 4.4.4.4 remote-as 1

      neighbor 4.4.4.4 update-source Loopback0

      neighbor 192.168.12.1 remote-as 100

      neighbor 192.168.12.1 update-source Loopback0

      no auto-summary

      !

      address-family vpnv4

        neighbor 4.4.4.4 activate

        neighbor 4.4.4.4 send-community extended

      exit-address-family

      !

      address-family ipv4 vrf BM

        redistribute connected

        neighbor 192.168.12.1 remote-as 100

        neighbor 192.168.12.1 activate

        no synchronization

      exit-address-family

      !

      ip http server

      no ip http secure-server

      !

      ==============================================================

      P#sh running-config

      Building configuration...

       

      Current configuration : 859 bytes

      !

      version 12.4

      service timestamps debug datetime msec

      service timestamps log datetime msec

      no service password-encryption

      !

      hostname P

      !

      boot-start-marker

      boot-end-marker

      !

      !

      no aaa new-model

      memory-size iomem 5

      !

      !

      ip cef

      !

      !

      interface Loopback0

      ip address 3.3.3.3 255.255.255.0

      ip ospf network point-to-point

      !

      interface FastEthernet0/0

      ip address 192.168.23.3 255.255.255.0

      duplex auto

      speed auto

      !

      interface FastEthernet1/0

      ip address 192.168.34.3 255.255.255.0

      duplex auto

      speed auto

      !

      router ospf 1

      log-adjacency-changes

      network 3.3.3.0 0.0.0.255 area 0

      network 192.168.23.0 0.0.0.255 area 0

      network 192.168.34.0 0.0.0.255 area 0

      !

      ip http server

      no ip http secure-server

      !

      ===========================================================================

       

      PE2#sh running-config

      Building configuration...

       

      Current configuration : 1444 bytes

      !

      version 12.4

      service timestamps debug datetime msec

      service timestamps log datetime msec

      no service password-encryption

      !

      hostname PE2

      !

      boot-start-marker

      boot-end-marker

      !

      !

      no aaa new-model

      memory-size iomem 5

      !

      !

      ip cef

      !

      !

      ip vrf BM

      rd 100:1

      route-target export 1:100

      route-target import 1:100

      !

      interface Loopback0

      ip address 4.4.4.4 255.255.255.0

      !

      interface FastEthernet0/0

      ip vrf forwarding BM

      ip address 192.168.45.4 255.255.255.0

      duplex auto

      speed auto

      !

      interface FastEthernet1/0

      ip address 192.168.34.4 255.255.255.0

      duplex auto

      speed auto

      !

      router ospf 1

      log-adjacency-changes

      network 4.4.4.0 0.0.0.255 area 0

      network 192.168.34.0 0.0.0.255 area 0

      !

      router bgp 1

      no synchronization

      bgp log-neighbor-changes

      network 4.4.4.0 mask 255.255.255.0

      neighbor 2.2.2.2 remote-as 1

      neighbor 2.2.2.2 update-source Loopback0

      neighbor 192.168.45.5 remote-as 100

      neighbor 192.168.45.5 update-source Loopback0

      no auto-summary

      !

      address-family vpnv4

        neighbor 2.2.2.2 activate

        neighbor 2.2.2.2 send-community extended

      exit-address-family

      !

      address-family ipv4 vrf BM

        redistribute connected

        neighbor 192.168.45.5 remote-as 100

        neighbor 192.168.45.5 activate

        no synchronization

      exit-address-family

      !

      ip http server

      no ip http secure-server

      =================================================================!

       

       

       

      Branch#sh running-config

      Building configuration...

       

      Current configuration : 770 bytes

      !

      version 12.4

      service timestamps debug datetime msec

      service timestamps log datetime msec

      no service password-encryption

      !

      hostname Branch

      !

      boot-start-marker

      boot-end-marker

      !

      !

      no aaa new-model

      memory-size iomem 5

      !

      !

      ip cef

      !

      interface Loopback0

      ip address 5.5.5.5 255.255.255.0

      !

      interface FastEthernet0/0

      ip address 192.168.45.5 255.255.255.0

      duplex auto

      speed auto

      !

      router bgp 100

      no synchronization

      bgp log-neighbor-changes

      network 5.5.5.0 mask 255.255.255.0

      network 192.168.45.0

      neighbor 4.4.4.4 remote-as 1

      neighbor 4.4.4.4 update-source Loopback0

      no auto-summary

      !

      ip http server

      no ip http secure-server

      !

      ================================================

       

      Best Regards,

      Mahmoud Abdelmoniem

        • 1. Re: MPLS VPN - BGP Lab
          Sergey

          Mahmoud,

           

          First thing that springs into mind is that your MPLS bit is missing You need to configure MPLS on your core interfaces in the SP cloud.

          • 2. Re: MPLS VPN - BGP Lab
            Steven Williams

            Are you sourcing your ICMP requests?

            • 3. Re: MPLS VPN - BGP Lab
              Mark Holm - 3xCCIE #34763/CCDE #2016::20

              In addition to what Setgey and Steven already suggested, you will also hit an issue or two with BGP in the current configuration you have. This is an excellent case to use for troubleshooting, so I won't reveal (yet) what you will encounter, but first you should fix the MPLS SP core.

               

              I'll keep an eye out for this thread.

              • 4. Re: MPLS VPN - BGP Lab
                Dmcneil

                Mahamoud,

                 

                The first thing I noticed is that you have not enabled LDP or designated interfaces that will forward MPLS packets in the SP core. While it is true that MPLS is already enabled in Cisco IOS, it is still required to designate what interfaces will label switch and to enable the LDP using mpls ip on the interfaces.

                 

                Fortunately, you are using OSPF so this can be done relatively easily using the mpls ldp auto-config command in OSPF configuration mode. This command will automatically enable MPLS forwarding on interfaces that are already enabled for OSPF.

                 

                Another issue is your loopback addressing. You should use /32 loopbacks whenever doing MPLS IP. IOS cannot forward the MPLS labels between the PEs whenever the Peering address between the PEs is anything longer than a /32 route. So the next thing I would do is change your loopback interfaces to /32 addresses. Also, I would not advertise these loopbacks into BGP to avoid any recursive routing issues.

                 

                After that, it appears you are attempting to peer over loopback addresses or between PE-CE or the physical interfaces. For example this is your configuration between HQ and PE1.

                 

                !HQ Router!

                router bgp 100

                no synchronization

                bgp log-neighbor-changes

                network 1.1.1.0 mask 255.255.255.0

                network 192.168.12.0

                neighbor 192.168.12.2 remote-as 1

                neighbor 192.168.12.2 update-source Loopback0

                 

                !PE 1 Router!

                router bgp 1

                no synchronization

                bgp log-neighbor-changes

                neighbor 4.4.4.4 remote-as 1

                neighbor 4.4.4.4 update-source Loopback0

                neighbor 192.168.12.1 remote-as 100

                neighbor 192.168.12.1 update-source Loopback0

                no auto-summary

                !

                address-family ipv4 vrf BM

                  redistribute connected

                  neighbor 192.168.12.1 remote-as 100

                  neighbor 192.168.12.1 activate

                  no synchronization

                exit-address-family

                !

                 

                The BGP peers will not come up with this configuration. Simply remove the update-source loopback0 commands from the PE-CE peerings. Then your BGP peers should come up. There is an additional point here as well. If you were going to peer over the loopback interfaces in the PE-CE, you would need to modify the update-source within the address-family ipv4 vrf BM section for the configuration to take effect.

                 

                Finally, you’re going to have a problem with the HQ and BRANCH routers rejecting the BGP update from SP because they both belong to AS 100. The BGP loop prevention check will reject the updates. To fix this, you need to add the neighbor [PE-neighbor] allowas-in command. This will allow the CEs (HQ and BRANCH) to accept the routing updates.

                 

                After performing these steps, you should have a better chance at getting a successful ping between the loopback addresses and the physical interfaces configured on the HQ and Branch routers. If not, please post show ip route, show ip bgp vpnv4 all, and show bgp all summary output from the PE/CE routers. As well as perform a traceroute from PE1’s loopback to PE2’s loopback.

                 

                Also, the configs you have posted in the OP seem to slightly differ from the actual configuration in the GNS3 file.

                • 5. Re: MPLS VPN - BGP Lab
                  Mahmoud

                  Dear Sergey,

                   

                  the MPLS is already configured with #mpls ip then i disabled it on interfaces pointing to HQ,Branch but this cmd doesnt appear in show run

                  • 6. Re: MPLS VPN - BGP Lab
                    Mahmoud

                    OK i will check these points and will reply to you soon with the result

                    • 7. Re: MPLS VPN - BGP Lab
                      Sergey

                      Mahmoud,

                       

                      In this case you need to check if you are getting LDP adjacencies built. Can you please show the output of "show mpls interfaces" and "show mpls ldp neighbor" commands.

                      • 8. Re: MPLS VPN - BGP Lab
                        Mahmoud

                        Dear Dmnceil,Mark,Steven & Sergey,

                         

                        Thanks all for your reply,

                         

                        Regarding the LDP it was my mistake when I copied the configuration above as erased LDP cmds by mistake but all SP routers are configured with #mpls ldp router-id Loopback0  Also the #sh mpls ip binding on every PE is showing the other Loopbacks IPs so I think LDP is working OK

                         

                        I Also fixed Peering in BGP as you mentioned ,removed the Update source cmd and BGP peering between PEs,CEs with physical interfaces only. AlsoI After I added the #neighbor PE IP allowas-in, I succeeded to see the HQ route in Branch CE routing table and Vice versa. However, the both CEs still cant ping each other

                         

                        Other Last thing, Regarding the Loopbacks Mask , I changed it to /32 on PEs,CEs but after doing that, I noticed the Loopbacks of Branch disappeared from routing table of HQ and ViceVersa so ,I returned it to /24

                        But as far as i know ,when using OSPF as IGP it advertises the loopbacks with /32 so i apply cmd #ip ospf network point-to-point.So I dont know does it related to the problem or not

                         

                        Below Some Shows:

                        =================

                        HQ#show 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

                         

                        C    192.168.12.0/24 is directly connected, FastEthernet0/0

                             1.0.0.0/24 is subnetted, 1 subnets

                        C       1.1.1.0 is directly connected, Loopback0

                        B    192.168.45.0/24 [20/0] via 192.168.12.2, 01:05:40

                             5.0.0.0/24 is subnetted, 1 subnets

                        B       5.5.5.0 [20/0] via 192.168.12.2, 00:21:46

                         

                         

                        HQ#show bgp all summary

                        For address family: IPv4 Unicast

                        BGP router identifier 1.1.1.1, local AS number 100

                        BGP table version is 11, main routing table version 11

                        4 network entries using 468 bytes of memory

                        5 path entries using 260 bytes of memory

                        5/3 BGP path/bestpath attribute entries using 620 bytes of memory

                        2 BGP AS-PATH entries using 48 bytes of memory

                        0 BGP route-map cache entries using 0 bytes of memory

                        0 BGP filter-list cache entries using 0 bytes of memory

                        BGP using 1396 total bytes of memory

                        BGP activity 7/3 prefixes, 8/3 paths, scan interval 60 secs

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        192.168.12.2    4     1      85      77       11    0    0 01:07:47        3

                        HQ#

                         

                        ==============================================================

                        PE1#show 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

                         

                             2.0.0.0/24 is subnetted, 1 subnets

                        C       2.2.2.0 is directly connected, Loopback0

                             3.0.0.0/24 is subnetted, 1 subnets

                        O       3.3.3.0 [110/2] via 192.168.23.3, 00:20:49, FastEthernet0/0

                             4.0.0.0/32 is subnetted, 1 subnets

                        O       4.4.4.4 [110/3] via 192.168.23.3, 00:20:49, FastEthernet0/0

                        C    192.168.23.0/24 is directly connected, FastEthernet0/0

                        O    192.168.34.0/24 [110/2] via 192.168.23.3, 00:20:49, FastEthernet0/0

                        PE1#

                        PE1#

                        PE1#

                        PE1#

                        PE1#show ip bgp vpnv4 all

                        BGP table version is 13, local router ID is 2.2.2.2

                        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: 100:1 (default for vrf BM)

                        *> 1.1.1.0/24       192.168.12.1             0             0 100 i

                        *>i5.5.5.0/24       4.4.4.4                  0    100      0 100 i

                        *  192.168.12.0     192.168.12.1             0             0 100 i

                        *>                  0.0.0.0                  0         32768 ?

                        *>i192.168.45.0     4.4.4.4                  0    100      0 ?

                        PE1#

                         

                        PE1#show bgp all summary

                        For address family: IPv4 Unicast

                        BGP router identifier 2.2.2.2, local AS number 1

                        BGP table version is 3, main routing table version 3

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        4.4.4.4         4     1     126     124        3    0    0 01:56:20        0

                        192.168.12.1    4   100       0       0        0    0    0 never    Idle

                         

                        For address family: VPNv4 Unicast

                        BGP router identifier 2.2.2.2, local AS number 1

                        BGP table version is 13, main routing table version 13

                        4 network entries using 548 bytes of memory

                        5 path entries using 340 bytes of memory

                        6/4 BGP path/bestpath attribute entries using 744 bytes of memory

                        1 BGP AS-PATH entries using 24 bytes of memory

                        1 BGP extended community entries using 24 bytes of memory

                        0 BGP route-map cache entries using 0 bytes of memory

                        0 BGP filter-list cache entries using 0 bytes of memory

                        BGP using 1680 total bytes of memory

                        BGP activity 7/3 prefixes, 8/3 paths, scan interval 15 secs

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        4.4.4.4         4     1     126     124       13    0    0 01:56:22        2

                        192.168.12.1    4   100      77      85       13    0    0 01:07:12        2

                        =============================================================

                        PE2#show 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

                         

                             2.0.0.0/24 is subnetted, 1 subnets

                        O       2.2.2.0 [110/3] via 192.168.34.3, 00:20:58, FastEthernet1/0

                             3.0.0.0/24 is subnetted, 1 subnets

                        O       3.3.3.0 [110/2] via 192.168.34.3, 00:20:58, FastEthernet1/0

                             4.0.0.0/24 is subnetted, 1 subnets

                        C       4.4.4.0 is directly connected, Loopback0

                        O    192.168.23.0/24 [110/2] via 192.168.34.3, 00:20:58, FastEthernet1/0

                        C    192.168.34.0/24 is directly connected, FastEthernet1/0

                         

                        PE2#show ip bgp vpnv4 all

                        BGP table version is 13, local router ID is 4.4.4.4

                        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: 100:1 (default for vrf BM)

                        *>i1.1.1.0/24       2.2.2.2                  0    100      0 100 i

                        *> 5.5.5.0/24       192.168.45.5             0             0 100 i

                        *>i192.168.12.0     2.2.2.2                  0    100      0 ?

                        *  192.168.45.0     192.168.45.5             0             0 100 i

                        *>                  0.0.0.0                  0         32768 ?

                         

                         

                        PE2#show bgp all summary

                        For address family: IPv4 Unicast

                        BGP router identifier 4.4.4.4, local AS number 1

                        BGP table version is 3, main routing table version 3

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        2.2.2.2         4     1     124     126        3    0    0 01:56:29        0

                        192.168.45.5    4   100       0       0        0    0    0 never    Idle

                         

                        For address family: VPNv4 Unicast

                        BGP router identifier 4.4.4.4, local AS number 1

                        BGP table version is 13, main routing table version 13

                        4 network entries using 548 bytes of memory

                        5 path entries using 340 bytes of memory

                        6/4 BGP path/bestpath attribute entries using 744 bytes of memory

                        1 BGP AS-PATH entries using 24 bytes of memory

                        1 BGP extended community entries using 24 bytes of memory

                        0 BGP route-map cache entries using 0 bytes of memory

                        0 BGP filter-list cache entries using 0 bytes of memory

                        BGP using 1680 total bytes of memory

                        BGP activity 7/3 prefixes, 9/4 paths, scan interval 15 secs

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        2.2.2.2         4     1     124     126       13    0    0 01:56:31        2

                        192.168.45.5    4   100      73      77       13    0    0 01:05:58        2

                        ===============================================================

                        Branch#show 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

                         

                        B    192.168.12.0/24 [20/0] via 192.168.45.4, 01:04:50

                             1.0.0.0/24 is subnetted, 1 subnets

                        B       1.1.1.0 [20/0] via 192.168.45.4, 00:22:08

                        C    192.168.45.0/24 is directly connected, FastEthernet0/0

                             5.0.0.0/24 is subnetted, 1 subnets

                        C       5.5.5.0 is directly connected, Loopback0

                        Branch#

                        Branch#

                        Branch#

                        Branch#

                        Branch#show bgp all summary

                        For address family: IPv4 Unicast

                        BGP router identifier 5.5.5.5, local AS number 100

                        BGP table version is 9, main routing table version 9

                        4 network entries using 468 bytes of memory

                        5 path entries using 260 bytes of memory

                        5/3 BGP path/bestpath attribute entries using 620 bytes of memory

                        2 BGP AS-PATH entries using 48 bytes of memory

                        0 BGP route-map cache entries using 0 bytes of memory

                        0 BGP filter-list cache entries using 0 bytes of memory

                        BGP using 1396 total bytes of memory

                        BGP activity 6/2 prefixes, 7/2 paths, scan interval 60 secs

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        192.168.45.4    4     1      77      73        9    0    0 01:05:38        3

                        Branch#

                        Branch#

                        Branch#

                        Branch#show bgp all summary

                        For address family: IPv4 Unicast

                        BGP router identifier 5.5.5.5, local AS number 100

                        BGP table version is 9, main routing table version 9

                        4 network entries using 468 bytes of memory

                        5 path entries using 260 bytes of memory

                        5/3 BGP path/bestpath attribute entries using 620 bytes of memory

                        2 BGP AS-PATH entries using 48 bytes of memory

                        0 BGP route-map cache entries using 0 bytes of memory

                        0 BGP filter-list cache entries using 0 bytes of memory

                        BGP using 1396 total bytes of memory

                        BGP activity 6/2 prefixes, 7/2 paths, scan interval 60 secs

                         

                        Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd

                        192.168.45.4    4     1      78      74        9    0    0 01:06:09        3

                         

                         

                        Best Regards

                        • 9. Re: MPLS VPN - BGP Lab
                          Dmcneil

                          Mahmoud,

                           

                          Since the prefixes do appear on the CE routers, the issue might be related to LDP. Could you post the output of “show mpls-forwarding” from the R2, R3 and R4?

                           

                          Other Last thing, Regarding the Loopbacks Mask , I changed it to /32 on PEs,CEs but after doing that, I noticed the Loopbacks of Branch disappeared from routing table of HQ and ViceVersa so ,I returned it to /24. But as far as i know ,when using OSPF as IGP it advertises the loopbacks with /32 so i apply cmd #ip ospf network point-to-point.So I dont know does it related to the problem or not

                           

                          That’s right. I might have overstated earlier. If you have a netmask of /24 configured on the loopback, by default OSPF will advertise the loopback with the netmask of /32. LDP will however advertise the actual mask, that is the mask of /24. This discrepancy causes the MPLS forwarding table to be populated with a label for the /24 prefix and not /32.  Additionally, when you changed the loopback to /32 your BGP network statement had a mask of 255.255.255.0 (/24) that’s why they disappeared from the table most likely.

                           

                          As you have correctly configured, changing the network type to point-to-point will ensure that OSPF advertises the true mask of /24 configured for the loopback interfaces.

                           

                          The best way to troubleshoot from here is to do this on PE1:

                          traceroute 4.4.4.4 source 2.2.2.2

                           

                          and on HQ do the following:

                          traceroute 5.5.5.5 source 1.1.1.1

                          • 10. Re: MPLS VPN - BGP Lab
                            Mahmoud

                            Dear Dmcneil,


                            Kindly check  Below shows


                            PE1#show mpls forwarding-table

                            Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop

                            tag    tag or VC   or Tunnel Id      switched   interface

                            16     Untagged    192.168.34.0/24   0          Fa0/0      192.168.23.3

                            17     Untagged    3.3.3.0/24        0          Fa0/0      192.168.23.3

                            18     Untagged    4.4.4.4/32        0          Fa0/0      192.168.23.3

                            19     Aggregate   192.168.12.0/24[V]   \

                                                                 0

                            21     Untagged    1.1.1.0/24[V]     0          Fa1/0      192.168.12.1

                            ===============================================================

                            P#sh mpls forwarding-table

                            Tag switching is not operational.

                            CEF or tag switching has not been enabled.

                            No TFIB currently allocated.

                            ======================================================

                            PE2#sh mpls forwarding-table

                            Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop

                            tag    tag or VC   or Tunnel Id      switched   interface

                            16     Untagged    3.3.3.0/24        0          Fa1/0      192.168.34.3

                            17     Untagged    192.168.23.0/24   0          Fa1/0      192.168.34.3

                            18     Untagged    5.5.5.0/24[V]     0          Fa0/0      192.168.45.5

                            19     Aggregate   192.168.45.0/24[V]   \

                                                                 0

                            22     Untagged    2.2.2.0/24        0          Fa1/0      192.168.34.3

                             

                             

                            ===============================================

                            PE1#traceroute 4.4.4.4 source 2.2.2.2

                             

                            Type escape sequence to abort.

                            Tracing the route to 4.4.4.4

                             

                              1 192.168.23.3 48 msec 72 msec 36 msec

                              2 192.168.34.4 92 msec 120 msec *

                             

                            HQ#traceroute 5.5.5.5 source 1.1.1.1

                             

                            Type escape sequence to abort.

                            Tracing the route to 5.5.5.5

                             

                              1 192.168.12.2 52 msec 76 msec 44 msec

                              2  *  *  *

                              3  *  *  *

                              4  *  *  *

                              5  *  *  *

                              6  *  *  *

                              7  *  *  *

                              8  *

                             

                            Thanks in advance,

                             

                            Best Regards,

                            • 11. Re: MPLS VPN - BGP Lab
                              Dmcneil

                              Mahmoud,

                               

                              It looks like MPLS or CEF is disabled on your P router based on this output:

                              P#sh mpls forwarding-table

                              Tag switching is not operational.

                              CEF or tag switching has not been enabled.

                              No TFIB currently allocated.

                              Try this command on the P router to verify the same:

                              show running-config | in mpls|cef

                              • 12. Re: MPLS VPN - BGP Lab
                                Mahmoud

                                Dear Dmcneil,

                                 

                                When configuring MPLS, i configured it globally with #mpls ip not on interface basis

                                ============================================

                                P#show running-config | in mpls | cef

                                ip cef

                                mpls ldp router-id Loopback0

                                • 13. Re: MPLS VPN - BGP Lab
                                  Sergey

                                  Mahmoud,

                                   

                                  the command "mpls ip" in global mode, doesn't start running LDP on any interfaces. What it does is enable the MPLS forwarding and create an empty MPLS forwarding table, which can then be populated by the LDP neighbours. Your issue is as I mentioned in my first reply is that you don't have MPLS configured on your core facing interfaces. Either run "mpls ip" command on these interfaces, or just as dmcneil330 suggested, use "mpls ldp autoconfig" command in the context of your OSPF routing protocol.

                                  • 14. Re: MPLS VPN - BGP Lab
                                    Dmcneil

                                    Mahmoud,

                                     

                                    Configuring MPLS globally does not enable MPLS forwarding or LDP at the interface level. It triggers the generation of the data structures required to support MPLS, similar to how the ip routing command enables IP routing but interfaces not be used to route IP traffic until configured appropriately (with an IPv4 address).

                                     

                                    You have configured an MPLS LDP router-id globally (which will be used to identify the router to other LDP neighbors), but have not enabled MPLS forwarding on a per-interface basis. This can be remedied by either configuring mpls ldp autoconfig under your OSPF process on the P and PE routers OR configuring mpls ip under the interfaces directly.

                                     

                                    example:

                                    interface f0/0

                                    mpls ip

                                    ! -OR-

                                    router ospf 1

                                    mpls ldp autoconfig

                                    1 2 Previous Next