01-13-2015 05:39 AM
I'm trying to understand 'send-label' under bgp neighbor command and after a few hours I beleive I understand how it works, but I'm unable to produce the desired behaviour. I was trying on c7200 in gns3 and in csr1000v.
Topology is 3routers csr1---csr2---csr3. I have OSPF+LDP between R1 and R2 and BGP between R2 and R3. I see label for routes that R1 is generating on R2 (explicit-null) and I want to send these labels to R3:
R1 is advertising explicit-nul to R2 and R2 sees is properly.
csr2#show mpls forwarding Local Outgoing Prefix Bytes Label Outgoing Next Hop Label Label or Tunnel Id Switched interface 17 explicit-n 10.0.0.1/32 0 Gi2 10.0.12.1 csr2#show ip cef 10.0.0.1 10.0.0.1/32 nexthop 10.0.12.1 GigabitEthernet2 label explicit-null csr2#show ip ro O 10.0.0.1/32 [110/34] via 10.0.12.1, 01:31:15, GigabitEthernet2
But when I check if these labes are added into BGP, I see no-labels:
csr2#show ip bgp labels Network Next Hop In label/Out label 10.0.0.1/32 10.0.12.1 nolabel/nolabel
Show mpls forwarding reveals that csr2 generated label 17 for this network, but it's not advertising this over BGP to csr3. It's sending without label.
router bgp 10 bgp log-neighbor-changes neighbor 10.0.0.3 remote-as 10 neighbor 10.0.0.3 update-source Loopback0 ! address-family ipv4 redistribute ospf 1 route-map REDIS neighbor 10.0.0.3 activate neighbor 10.0.0.3 next-hop-self neighbor 10.0.0.3 send-label explicit-null exit-address-family
csr2#show ip bgp neighbors BGP neighbor is 10.0.0.3, remote AS 10, internal link ipv4 MPLS Label capability: advertised
I was testing in CSR1000V 15.4(2)S2 and in C7200 15.2(S3). What am I missing?
BR, Ziga
01-13-2015 06:36 AM
Hi Ziga,
You seems to have enabled this feature only on csr2 as below:
ipv4 MPLS Label capability: advertised
By default the ipv4 prefixes will be advertised in AFI=1;SAFI=1. In order to advertise labels, we need AFI=1;SAFI=4. THis will be used only when it is enabled on both the sides (else the neighbor may not understand the update).
-Nagendra
01-16-2015 02:41 AM
Hi,
Thanks!! This was part of the problem, I added 'send-label' on the other side too, but still don't see labels. R2 in the middle is redistributing ospf to bgp and received 'explicit-null' to reach R1.
R2#show mpls fo Local Outgoing Prefix Bytes Label Outgoing Next Hop Label Label or Tunnel Id Switched interface 17 explicit-n 10.0.0.1/32 0 Gi2 10.0.12.1 18 No Label 10.0.0.3/32 0 Gi3 10.0.23.3 R2#show ip bgp lab Network Next Hop In label/Out label 10.0.0.1/32 10.0.12.1 nolabel/nolabel 10.0.0.3/32 10.0.0.3 nolabel/imp-null 10.0.12.0/24 0.0.0.0 imp-null/nolabel
R2#show ip bgp Network Next Hop Metric LocPrf Weight Path *> 10.0.0.1/32 10.0.12.1 34 32768 ? r>i 10.0.0.3/32 10.0.0.3 0 100 0 i *> 10.0.12.0/24 0.0.0.0 0 32768 ?
second problem that I'm observing is that r3 is advertising it's loopback IP=10.0.0.3 via BGP and ospf but it's not in use at R2 (RIB-failure) and therefor R2 is not sending it towards R1. R1 also needs to get label from R2 to reach R3. I need ospf between R2 and R3 in order to establish BGP over loopback IPs.
05-18-2017 11:17 AM
Hi,
Verify that your WAN interfaces have enabled this command:
"mpls bgp forwarding"
BR
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide