Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zebra: add LSP entry to nexthop via recursive #12469

Closed
wants to merge 10 commits into from

Conversation

dmytroshytyi-6WIND
Copy link
Contributor

@dmytroshytyi-6WIND dmytroshytyi-6WIND commented Dec 8, 2022

The goal consists in establishing IP connectivity
between two CPEs, where in the middle there are:

a) 3 separate IGPs configured in Segment routing

  • north-east
  • east-west
  • west-south

b) BGP peerings are established between each endpoint of each IGP

  • iBGP between (north) and (east)
  • iBGP between (east) and (west)
  • iBGP between (west) and (south)

This patch allows to create an additional LSP
path forged by labeled iBGP.

There is an issue when creating this additional
LSP path, since the traffic from north to south
is dropped on east, and the traffic from south
to north is dropped on west.

The reason behind this is that labeled iBGP fails
to find a BGP route to install its LSP, because
there is an other IGP LSP.
This patch allows to create an additional LSP
path forged by labeled IBGP. This addition LSP
path will sit on top of an existing LSP path forged by an existing IGP.

Before:

east-vm# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label
 -------------------------------------------------------
 1011           SR (IS-IS)  10.125.0.1  1011
 1022           SR (IS-IS)  lo          -
 11022          SR (IS-IS)  lo          -
 11035          SR (IS-IS)  10.126.0.3  11035
 36000          SR (IS-IS)  10.126.0.3  implicit-null

After command "mpls fec recursive-via-nexthop" was applied:

east-vm# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label
 -------------------------------------------------------
 80             SR (IS-IS)  10.125.0.1  1011
 81             SR (IS-IS)  10.126.0.3  11035
 82             BGP         3.3.3.3     80
 1011           SR (IS-IS)  10.125.0.1  1011
 1022           SR (IS-IS)  lo          -
 11022          SR (IS-IS)  lo          -
 11035          SR (IS-IS)  10.126.0.3  11035
 36000          SR (IS-IS)  10.126.0.3  implicit-null

UPDATE:

When a FEC entry is registered, a BGP labeled route may not be
available to create an LSP entry. This is the case when trying
to forge an additional LSP path with BGP, on top of an IGP LSP path.
The following command authorises the creation of an additional
BGP labeled LSP path over an IGP LSP path:

mpls fec seamless-resolve

A topology consists of multiple segments:

    r1 ---- r2 ---- r3 ---- r4 ----- r5 ---- r6 ---- r7
     <--- ospf ----> <---- isis -----> <--- ospf ---->

UPDATE2:

The topology of topotest presented in this pull request is described by this figure:

(BGP)  ------- (BGP)  -------  (BGP)  -------  (BGP)
r1 ---- r2 ---- r3 ---- r4 ----- r5 ---- r6 ---- r7
<--- ospf ----> <---- isis -----> <--- ospf ---->

Commands examples:

Commands added:

r3# configure
r3(config)# mpls
  fec    MPLS FEC table
  label  Label configuration
  ldp    Label Distribution Protocol
  lsp    Establish label switched path
r3(config)# mpls fec
  seamless-resolve  Authorise seamless MPLS resolution
r3(config)# mpls fec seamless-resolve

r3# configure
r3(config)# vrf default
r3(config-vrf)# mpls
  fec  MPLS FEC table
r3(config-vrf)# mpls fec
  resolve-seamless  Authorise seamless MPLS resolution
r3(config-vrf)# mpls fec seamless-resolve

east-vm# show running-config
Building configuration...
...
!
mpls fec seamless-resolve
!
...

"Seamless-resolve" is disabled with command:

r3(config)# no mpls fec seamless-resolve

and r3 has the next mpls table:

r3# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label  
 ------------------------------------------------------- 
 1011           SR (OSPF)   10.126.0.2  1011             
 1022           SR (OSPF)   10.126.0.2  implicit-null    
 11044          SR (IS-IS)  10.127.0.4  implicit-null    
 11055          SR (IS-IS)  10.127.0.4  11055            
 30000          SR (OSPF)   10.126.0.2  implicit-null    
 30001          SR (OSPF)   10.126.0.2  implicit-null    
 36000          SR (IS-IS)  10.127.0.4  implicit-null    

"Seamless-resolve" is enabled with command:

r3(config)# mpls fec seamless-resolve

and r3 has the next mpls table:

r3# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label  
 -------------------------------------------------------
 17             SR (IS-IS)  10.127.0.4  11055           
 18             SR (OSPF)   10.126.0.2  1011            
 19             BGP         10.127.0.4  11055/19        
 1011           SR (OSPF)   10.126.0.2  1011            
 1022           SR (OSPF)   10.126.0.2  implicit-null   
 11044          SR (IS-IS)  10.127.0.4  implicit-null   
 11055          SR (IS-IS)  10.127.0.4  11055           
 30000          SR (OSPF)   10.126.0.2  implicit-null   
 30001          SR (OSPF)   10.126.0.2  implicit-null   
 36000          SR (IS-IS)  10.127.0.4  implicit-null   

@mjstapp
Copy link
Contributor

mjstapp commented Dec 8, 2022

A couple of top-level questions: the description here is too lean. How will this new lookup solve the problem you're trying to describe? The existing recursive check is probably trying to avoid a situation where some next-hop doesn't speak mpls at all - or doesn't understand the label stack. How can you ensure that won't happen?

@mjstapp
Copy link
Contributor

mjstapp commented Dec 8, 2022

It would be better not to be working from "master" in your fork - it would be better to work from a branch in your fork.

Copy link
Contributor

@mjstapp mjstapp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Must have docs for this, and it should be included in a topotest as well.

(safi == SAFI_UNICAST && !peer->afc[afi][safi] &&
peer->afc[afi][SAFI_LABELED_UNICAST] &&
CHECK_FLAG(peer->af_flags[afi][SAFI_LABELED_UNICAST],
PEER_FLAG_REFLECTOR_CLIENT)))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can't add this much unconditional change without ... a comment explaining exactly what these additional terms mean.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit log was updated with a comment.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's good, from the commit-log pov, but it's really what I asked for? I'd like to see a comment here in the code, where this very particular decision is being taken. Otherwise, someone who is trying to follow the logic bears the burden of doing a git blame, walking through the code, and searching the git history in order to locate the comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

zebra/rib.h Outdated
@@ -416,6 +416,7 @@ extern struct route_entry *rib_match_ipv6_multicast(vrf_id_t vrf_id,

extern struct route_entry *rib_lookup_ipv4(struct prefix_ipv4 *p,
vrf_id_t vrf_id);
extern struct route_entry *rib_lookup(struct prefix *p, vrf_id_t vrf_id);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need yet-another copy of the "lookup a route" logic for this purpose?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is only ipv4 lookup available, no ipv6 lookup was found. changing the prototype of "rib_lookup_ipv4" will lead to code impact as other functions use it. Instead of creating ipv6_lookup, the generic rib_lookup was added.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like route_node_lookup() is widely used - won't that work?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Finally we do not need another copy, as you are suggesting. The rib_lookup_ipv4 evolved to rib_lookup with generic ipv4 ipv6 functionality in new version.

@@ -197,10 +200,29 @@ static int lsp_install(struct zebra_vrf *zvrf, mpls_label_t label,
*/
for (nexthop = re->nhe->nhg.nexthop;
nexthop; nexthop = nexthop->next) {
nexthop_via_recursive = nexthop;
/* Skip inactive and recursive entries. */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Old comment?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will be fixed

}

re_recursive = rib_lookup(&p, zvrf->vrf->vrf_id);
nexthop_via_recursive = re_recursive->nhe->nhg.nexthop;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if the lookup doesn't succeed?
and again, we have to have a comment describing what this branch is trying to do.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed, the code should also cope with this situation.

* vtysh configuration of "mpls fec resolve-via-recursive"
*/
void zebra_mpls_fec_recursive_seamless_enabled(bool status,
struct zebra_vrf *zvrf)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add zvrf apis to the zvrf module, not the zebra_mpls module?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reply: thanks will be moved to zvrf module

return write;
}

/* Enable seamless MPLS */
DEFUN (mpls_fec_recursive_seamless,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DEFPY now, please, and you can use one block that includes the 'no' form.

Copy link
Contributor Author

@dmytroshytyi-6WIND dmytroshytyi-6WIND Dec 9, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Understood, it is going to be addressed.

@@ -641,15 +641,56 @@ struct route_entry *rib_lookup_ipv4(struct prefix_ipv4 *p, vrf_id_t vrf_id)
return NULL;
}

struct route_entry *rib_lookup(struct prefix *p, vrf_id_t vrf_id)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding another copy of the route-lookup logic is pretty unappealing. Is this absolutely necessary (and correct)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is only ipv4 lookup available, no ipv6 lookup was found. changing the prototype of "rib_lookup_ipv4" will lead to code impact as other functions use it. Instead of creating ipv6_lookup, the generic rib_lookup was added.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To further this point a cut-n-paste of code just fixing up struct prefix_ipv4 to struct prefix_ipv6 is a big hard no from me. Abstract to the generic functionality and replace all the places that rib_lookup_ipv4 is used with just a plain old rib_lookup. I'm not interested in cut-n-paste code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this comment. In new version of the PATCH,
struct route_entry *rib_lookup_ipv4 will be replaced by
struct route_entry *rib_lookup with generic functionality for ipv4 and ipv6 prefixes with replacement of all occurrences in the code without cut-n-paste.


if (re->type != ZEBRA_ROUTE_BGP)
if ((re->type != ZEBRA_ROUTE_BGP) &&
!zvrf->zebra_mpls_fec_recursive_seamless)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, why this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when a FEC entry is added in zebra on
reception of a BGP labeled unicast update, an LSP entry is
created. That LSP entry is resolved by using the re route entry
which is also installed by BGP labeled unicast.

This route entry is not available when we face with i-bgp
peering session.
Actually, the BGP labeled unicast is working over an
LSP network, but associated BGP labeled unicast entries are not selected.

This change disables the (re->type != ZEBRA_ROUTE_BGP) check.
Thus we rely on the available network entry.

Without this modification we have:

east-vm# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label
 -------------------------------------------------------
 1011           SR (IS-IS)  10.125.0.1  implicit-null
 1033           SR (IS-IS)  10.126.0.3  implicit-null
 1044           SR (IS-IS)  10.126.0.3  1044
 30000          SR (IS-IS)  10.125.0.1  implicit-null
 30001          SR (IS-IS)  10.126.0.3  implicit-null

After this modification we have:

east-vm# show mpls table
 Inbound Label  Type        Nexthop     Outbound Label
 -------------------------------------------------------
 17             SR (IS-IS)  10.125.0.1  implicit-null
 19             SR (IS-IS)  10.126.0.3  implicit-null
 20             SR (IS-IS)  10.126.0.3  1044
 1011           SR (IS-IS)  10.125.0.1  implicit-null
 1033           SR (IS-IS)  10.126.0.3  implicit-null
 1044           SR (IS-IS)  10.126.0.3  1044
 30000          SR (IS-IS)  10.125.0.1  implicit-null
 30001          SR (IS-IS)  10.126.0.3  implicit-null

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please look at all the places where this function is called. We can't just return true in all of those paths.

Copy link
Contributor Author

@dmytroshytyi-6WIND dmytroshytyi-6WIND Dec 16, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello, I updated the description with IETF document that highlights the approach proposed by these series of patches ( I hope this might help )

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 8, 2022

Continuous Integration Result: SUCCESSFUL

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-8760/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Warnings Generated during build:

Checkout code: Successful with additional warnings
<stdin>:177: trailing whitespace.
{        
warning: 1 line adds whitespace errors.
Report for zebra_mpls_vty.c | 2 issues
===============================================
< WARNING: Avoid line continuations in quoted strings
< #315: FILE: /tmp/f1-1648343/zebra_mpls_vty.c:315:

Copy link
Member

@ton31337 ton31337 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And also... tests + docs?

@dmytroshytyi-6WIND
Copy link
Contributor Author

A couple of top-level questions: the description here is too lean. How will this new lookup solve the problem you're trying to describe? The existing recursive check is probably trying to avoid a situation where some next-hop doesn't speak mpls at all - or doesn't understand the label stack. How can you ensure that won't happen?

The description was updated.

I supposed too that recursive check is probably present to avoid the case when next-hop is not an mpls hop. This patch is optional feature enabled by the vtysh command only where network operator ensures that setup is properly configured.
BGP labeled LSP requires that an existing BGP route with a labeled nexthop is available. Enabling recursivity authorises the BGP lableed LSP to use an other labeled nexthop route. The case with no label never happens.

@dmytroshytyi-6WIND
Copy link
Contributor Author

It would be better not to be working from "master" in your fork - it would be better to work from a branch in your fork.

For next pull request, I will pay attention. Thank you.

@dmytroshytyi-6WIND
Copy link
Contributor Author

Must have docs for this, and it should be included in a topotest as well.

I will work on this, Thanks.

@dmytroshytyi-6WIND
Copy link
Contributor Author

dmytroshytyi-6WIND commented Dec 9, 2022

And also... tests + docs?

I will work on this.

@mjstapp
Copy link
Contributor

mjstapp commented Dec 9, 2022

Why are you trying to use bgp-lu here at all, when you don't have hop-by-hop peers? If you announced recursive ip routes, they'd be installed to use the SR LSPs just fine - I think?

A couple of top-level questions: the description here is too lean. How will this new lookup solve the problem you're trying to describe? The existing recursive check is probably trying to avoid a situation where some next-hop doesn't speak mpls at all - or doesn't understand the label stack. How can you ensure that won't happen?

The description was updated.

I supposed too that recursive check is probably present to avoid the case when next-hop is not an mpls hop. This patch is optional feature enabled by the vtysh command only where network operator ensures that setup is properly configured. BGP labeled LSP requires that an existing BGP route with a labeled nexthop is available. Enabling recursivity authorises the BGP lableed LSP to use an other labeled nexthop route. The case with no label never happens.

nhlfe = nhlfe_add(lsp, lsp_type,
nexthop_via_recursive->type,
&nexthop->gate,
nexthop_via_recursive->ifindex,
nexthop->nh_label->num_labels,
nexthop->nh_label->label,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

trying to be clearer about the question here: so this says "send an mpls packet with the LU labels on a link where there's no assurance that those labels mean anything. and the destination mac will be ... for an address that doesn't exist on the link." so ... how can that be meaningful to do?

p.prefixlen = IPV6_MAX_BITLEN;
}

re_recursive = rib_lookup(&p, zvrf->vrf->vrf_id);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm willing to bet that this 1st commit in the tree needs rib_lookup to work. This will not even compile. I'm not interested in taking code that will fail me when I have a git bisect. Please take the time and make sure the code will work and compile in sequence

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm working on the new version that has the code which compiles in sequence. Thank you for the comment.

@donaldsharp
Copy link
Member

There needs to be doc changes as well as an topotest or two to show this new feature working

@dmytroshytyi-6WIND
Copy link
Contributor Author

There needs to be doc changes as well as an topotest or two to show this new feature working

I'm currently working on 3 topotests, thanks.

What doc changes exactly do you have in mind? (Please note I updated the topic with IETF document, this might help).

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 30, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Failed

Topotests Ubuntu 18.04 i386 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18I386-9034/test

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18I386/TopotestLogs/log_topotests.txt
Topotests Ubuntu 18.04 i386 part 6: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18I386/TopotestDetails/

Topotests Ubuntu 18.04 arm8 part 1: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 1: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO1U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 1: No useful log found
Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests debian 10 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6DEB10AMD64-9034/test

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests Ubuntu 18.04 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18AMD64-9034/test

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 4: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO4DEB10AMD64-9034/test

Topology Tests failed for Topotests debian 10 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO4DEB10AMD64/TopotestLogs/log_topotests.txt

Successful on other platforms/tests
  • Topotests Ubuntu 18.04 i386 part 1
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 amd64 part 5
  • Topotests Ubuntu 18.04 amd64 part 4
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests debian 10 amd64 part 5
  • Topotests debian 10 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 2
  • Topotests Ubuntu 18.04 arm8 part 7
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 arm8 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 i386 part 7
  • Fedora 29 rpm pkg check
  • Addresssanitizer topotests part 6
  • CentOS 7 rpm pkg check
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests Ubuntu 18.04 i386 part 5
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests debian 10 amd64 part 8
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 4
  • Topotests Ubuntu 18.04 arm8 part 9
  • Topotests debian 10 amd64 part 3
  • Debian 10 deb pkg check
  • Debian 9 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 1
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 i386 part 4
  • Ubuntu 18.04 deb pkg check
  • Topotests Ubuntu 18.04 i386 part 3
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Addresssanitizer topotests part 7
  • Addresssanitizer topotests part 4
  • Topotests Ubuntu 18.04 arm8 part 5
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 i386 part 9
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests Ubuntu 18.04 arm8 part 0
  • Static analyzer (clang)
  • Ubuntu 16.04 deb pkg check
  • Addresssanitizer topotests part 0

Warnings Generated during build:

Checkout code: Successful with additional warnings
Topotests Ubuntu 18.04 i386 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18I386-9034/test

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18I386/TopotestLogs/log_topotests.txt
Topotests Ubuntu 18.04 i386 part 6: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18I386/TopotestDetails/

Topotests Ubuntu 18.04 arm8 part 1: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 1: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO1U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 1: No useful log found
Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests debian 10 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6DEB10AMD64-9034/test

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests Ubuntu 18.04 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18AMD64-9034/test

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO6U18AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 4: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO4DEB10AMD64-9034/test

Topology Tests failed for Topotests debian 10 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9034/artifact/TOPO4DEB10AMD64/TopotestLogs/log_topotests.txt

<stdin>:29: trailing whitespace.
WhenaFECentryisregistered,aBGPlabeled routemaynotbe 
warning: 1 line adds whitespace errors.
Report for zebra_mpls.c | 2 issues
===============================================
< ERROR: do not use assignment in if condition
< #511: FILE: /tmp/f1-3178530/zebra_mpls.c:511:

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 30, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Failed

Topotests Ubuntu 18.04 i386 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18I386-9036/test

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18I386/TopotestLogs/log_topotests.txt
Topotests Ubuntu 18.04 i386 part 6: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18I386/TopotestDetails/

Topotests debian 10 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6DEB10AMD64-9036/test

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests Ubuntu 18.04 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18AMD64-9036/test

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 4: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO4DEB10AMD64-9036/test

Topology Tests failed for Topotests debian 10 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO4DEB10AMD64/TopotestLogs/log_topotests.txt

Successful on other platforms/tests
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 amd64 part 5
  • Ubuntu 16.04 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 4
  • Topotests Ubuntu 18.04 i386 part 1
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests Ubuntu 18.04 arm8 part 1
  • Topotests Ubuntu 18.04 arm8 part 2
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests debian 10 amd64 part 5
  • Topotests debian 10 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 7
  • Topotests Ubuntu 18.04 arm8 part 8
  • Addresssanitizer topotests part 7
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 i386 part 7
  • Addresssanitizer topotests part 6
  • CentOS 7 rpm pkg check
  • Fedora 29 rpm pkg check
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests debian 10 amd64 part 8
  • Topotests Ubuntu 18.04 arm8 part 4
  • Topotests Ubuntu 18.04 i386 part 5
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 9
  • Ubuntu 18.04 deb pkg check
  • Debian 10 deb pkg check
  • Debian 9 deb pkg check
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 i386 part 4
  • Topotests Ubuntu 18.04 amd64 part 1
  • Topotests Ubuntu 18.04 i386 part 3
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Addresssanitizer topotests part 4
  • Topotests Ubuntu 18.04 arm8 part 5
  • Addresssanitizer topotests part 5
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 i386 part 9
  • Topotests Ubuntu 18.04 arm8 part 0
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests debian 10 amd64 part 3
  • Addresssanitizer topotests part 0
  • Static analyzer (clang)

Warnings Generated during build:

Checkout code: Successful with additional warnings
Topotests Ubuntu 18.04 i386 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18I386-9036/test

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18I386/TopotestLogs/log_topotests.txt
Topotests Ubuntu 18.04 i386 part 6: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18I386/TopotestDetails/

Topotests debian 10 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6DEB10AMD64-9036/test

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests Ubuntu 18.04 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18AMD64-9036/test

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO6U18AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 4: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO4DEB10AMD64-9036/test

Topology Tests failed for Topotests debian 10 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9036/artifact/TOPO4DEB10AMD64/TopotestLogs/log_topotests.txt

<stdin>:29: trailing whitespace.
WhenaFECentryisregistered,aBGPlabeled routemaynotbe 
warning: 1 line adds whitespace errors.
Report for zebra_mpls.c | 2 issues
===============================================
< ERROR: do not use assignment in if condition
< #511: FILE: /tmp/f1-3394531/zebra_mpls.c:511:

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Jan 3, 2023

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

Test incomplete. See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Incomplete

Topotests Ubuntu 18.04 arm8 part 8: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 8: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO8U18AMD64/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 8: No useful log found
Topotests Ubuntu 18.04 i386 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18I386-9050/test

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO6U18I386/TopotestLogs/log_topotests.txt
Topotests Ubuntu 18.04 i386 part 6: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO6U18I386/TopotestDetails/

Topotests Ubuntu 18.04 i386 part 7: Incomplete (check logs for details)
Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO6U18ARM8/TopotestDetails/ Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests debian 10 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6DEB10AMD64-9050/test

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO6DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests Ubuntu 18.04 amd64 part 6: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO6U18AMD64-9050/test

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO6U18AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 4: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO4DEB10AMD64-9050/test

Topology Tests failed for Topotests debian 10 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-9050/artifact/TOPO4DEB10AMD64/TopotestLogs/log_topotests.txt

Topotests debian 10 amd64 part 3: Incomplete (check logs for details)
Successful on other platforms/tests
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests debian 10 amd64 part 5
  • Topotests Ubuntu 18.04 arm8 part 2
  • Topotests debian 10 amd64 part 0
  • Ubuntu 16.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 7
  • Addresssanitizer topotests part 7
  • Topotests Ubuntu 18.04 i386 part 1
  • Topotests Ubuntu 18.04 amd64 part 5
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 i386 part 3
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 i386 part 5
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 3
  • Topotests debian 10 amd64 part 8
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 arm8 part 4
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 arm8 part 9
  • Fedora 29 rpm pkg check
  • CentOS 7 rpm pkg check
  • Topotests Ubuntu 18.04 amd64 part 4
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 arm8 part 0
  • Static analyzer (clang)
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 5
  • Debian 10 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 1
  • Addresssanitizer topotests part 6
  • Ubuntu 18.04 deb pkg check
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 arm8 part 1
  • Addresssanitizer topotests part 0
  • Addresssanitizer topotests part 4
  • Debian 9 deb pkg check
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 i386 part 4
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests Ubuntu 18.04 i386 part 9

@mjstapp
Copy link
Contributor

mjstapp commented Jan 5, 2023

I don't think that there's really any value in referring to a draft that expired in ... 2014 or 2015.

We use the word "recursive" in most places when we want to refer to nexthop resolution - and it seems like that's what you're attempting to use here - so let's use that keyword for LSPs also, unless there's some compelling reason to introduce a new term.

@mjstapp
Copy link
Contributor

mjstapp commented Jan 5, 2023

I'm all for leveraging the work we're already doing to resolve recursive IP routes. But I think I still don't follow the logic that you're proposing for LSPs. If an mpls frame with a composite label stack arrives at the boundary between the IGP and BGP, what happens, exactly? How does that last IGP hop know what to do with the BGP label advertised to and imposed at the source?

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: FAILED

See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-11210/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Failed

Topotests debian 10 amd64 part 1: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-PULLREQ2-TOPO1DEB10AMD64-11210/test

Topology Tests failed for Topotests debian 10 amd64 part 1
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-11210/artifact/TOPO1DEB10AMD64/TopotestLogs/log_topotests.txt
Topotests debian 10 amd64 part 1: Unknown Log
URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-11210/artifact/TOPO1DEB10AMD64/TopotestDetails/

Successful on other platforms/tests
  • Topotests Ubuntu 18.04 i386 part 6
  • Topotests Ubuntu 18.04 i386 part 1
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 amd64 part 5
  • Topotests Ubuntu 18.04 amd64 part 4
  • Topotests Ubuntu 18.04 arm8 part 1
  • Topotests Ubuntu 18.04 arm8 part 7
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 arm8 part 6
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests debian 10 amd64 part 5
  • Topotests debian 10 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 2
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 arm8 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 i386 part 7
  • Addresssanitizer topotests part 6
  • CentOS 7 rpm pkg check
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 i386 part 5
  • Topotests debian 10 amd64 part 8
  • Topotests Ubuntu 18.04 i386 part 0
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 9
  • Debian 10 deb pkg check
  • Topotests debian 10 amd64 part 3
  • Debian 9 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 1
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 i386 part 4
  • Ubuntu 18.04 deb pkg check
  • Topotests Ubuntu 18.04 i386 part 3
  • Topotests Ubuntu 18.04 amd64 part 6
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Addresssanitizer topotests part 7
  • Topotests debian 10 amd64 part 4
  • Addresssanitizer topotests part 4
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests Ubuntu 18.04 i386 part 9
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests Ubuntu 18.04 arm8 part 0
  • Static analyzer (clang)
  • Addresssanitizer topotests part 0

@dmytroshytyi-6WIND
Copy link
Contributor Author

ci:rerun

1 similar comment
@dmytroshytyi-6WIND
Copy link
Contributor Author

ci:rerun

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-11212/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-11213/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

dmytroshytyi-6WIND and others added 10 commits September 4, 2023 16:31
Commands added:

r3# configure
r3(config)# mpls
  fec    MPLS FEC table
  label  Label configuration
  ldp    Label Distribution Protocol
  lsp    Establish label switched path
r3(config)# mpls fec
  mpls fec nexthop-resolution  Authorise nexthop resolution
				over all labeled routes.
r3(config)# mpls fec mpls fec nexthop-resolution

r3# configure
r3(config)# vrf default
r3(config-vrf)# mpls
  fec  MPLS FEC table
r3(config-vrf)# mpls fec
  mpls fec nexthop-resolution  Authorise nexthop resolution
				over all labeled routes.
r3(config-vrf)# mpls fec nexthop-resolution

east-vm# show running-config
Building configuration...
...
!
mpls fec nexthop-resolution
!
...

Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Upon reconfiguring nexthop-resolution updates, update the
lsp entries accordingly.
If fec nexthop-resolution becomes true, then call again
fec_change_update_lsp() for each fec entry available.

If fec nexthop-resolution becomes false, then call again
fec_change_update_lsp() for each fec entry available, and
if the update fails, uninstall any lsp related with the fec
entry. In the case lsp_install() and no lsp entry could be
created or updated, then consider this call as a failure, and
return -1.

Co-developed-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
This commit addresses an issue that happens when using bgp
labeled unicast peering with a rr client, with a received prefix
which is the local ip address of the bgp session.

When using bgp ipv4 labeled session, the local prefix is
received by a peer, and finds out that the proposed prefix
and its next-hop are the same. To avoid a route loop locally,
no nexthop entry is referenced for that prefix, and the route
will not be selected.

As it has been done for ipv4-unicast, apply the following fix
for labeled address families: when the received peer is
a route reflector, the prefix has to be selected, even if the
route can not be installed locally.

Fixes: f874552 ("bgpd: authorise to select bgp self peer prefix on rr case")

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
There are two ways of iterating over nexthops of a given
route entry.
- Either only the main nexthop are taken into account
(which is the case today when attempting to install an
LSP entry on a BGP connected labeled route.
- Or by taking into account nexthops that are resolved
and linked in nexthop->resolved of the previous nexthop
which has RECURSIVE flag set. This second case has to be
taken into account in the case where recursive routes may
be used to install an LSP entry.

Introduce a new API in nexthop that will parse over the
appropriate nexthop, if the nexthop-resolution flag is turned
on or not on the given VRF.

Use that API in the lsp_install() function so as to walk
over the appropriate nexthops.

Co-developed-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
When an LSP entry is created from a FEC entry, multiple labels
may now be appended to the LSP entry, instead of one single.

Upon lsp creation, the LSP trace will display all the labels
appended.

Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Until now, when a FEC entry is added in zebra, driven by the
reception of a BGP labeled unicast update, an LSP entry is
created. That LSP entry is resolved by using the route entry
which is also installed by BGP labeled unicast.

This route entry is not available when we face with i-bgp
peering session. I-BGP labeled sessions are used to establish
IP connectivity across separate IGPs.

The below dumps illustrate a 3 IGP topology. An attempt to create
connectivity between the north and the south machines is done.

The 3 separate IGPs are configured in Segment routing:
- north-east
- east-west
- west-south

We create BGP peerings between each endpoint of each IGP:
- iBGP between (north) and (east)
- iBGP between (east) and (west)
- iBGP between (west) and (south)

Before that patch, the FEC entries could not be resolved on the
east machine:

Before:
east-vm# show mpls fec
192.0.2.1/32
  Label: 18
  Client list: bgp(fd 48)
192.0.2.5/32
  Label: 17
  Client list: bgp(fd 48)
192.0.2.7/32
  Label: 19
  Client list: bgp(fd 48)

east-vm# show mpls table
 Inbound Label  Type        Nexthop      Outbound Label
 --------------------------------------------------------
 1011           SR (OSPF)   192.168.2.2  1011
 1022           SR (OSPF)   192.168.2.2  implicit-null
 11044          SR (IS-IS)  192.168.3.4  implicit-null
 11055          SR (IS-IS)  192.168.3.4  11055
 30000          SR (OSPF)   192.168.2.2  implicit-null
 30001          SR (OSPF)   192.168.2.2  implicit-null
 36000          SR (IS-IS)  192.168.3.4  implicit-null

east-vm# show ip route
[..]
B   192.0.2.1/32 [200/0] via 192.0.2.1 inactive, label implicit-null, weight 1, 00:17:45
O>* 192.0.2.1/32 [110/20] via 192.168.2.2, r3-eth0, label 1011, weight 1, 00:17:47
O>* 192.0.2.2/32 [110/10] via 192.168.2.2, r3-eth0, label implicit-null, weight 1, 00:17:47
O   192.0.2.3/32 [110/0] is directly connected, lo, weight 1, 00:17:57
C>* 192.0.2.3/32 is directly connected, lo, 00:18:03
I>* 192.0.2.4/32 [115/20] via 192.168.3.4, r3-eth1, label implicit-null, weight 1, 00:17:59
B   192.0.2.5/32 [200/0] via 192.0.2.5 inactive, label implicit-null, weight 1, 00:17:56
I>* 192.0.2.5/32 [115/30] via 192.168.3.4, r3-eth1, label 11055, weight 1, 00:17:58
B>  192.0.2.7/32 [200/0] via 192.0.2.5 (recursive), label 19, weight 1, 00:17:45
  *                        via 192.168.3.4, r3-eth1, label 11055/19, weight 1, 00:17:45
[..]

After command "mpls fec nexthop-resolution" was applied, the FEC
entries will resolve over any non BGP route that has a labeled path
selected.

east-vm# show mpls table
 Inbound Label  Type        Nexthop      Outbound Label
 --------------------------------------------------------
 17             SR (IS-IS)  192.168.3.4  11055
 18             SR (OSPF)   192.168.2.2  1011
 19             BGP         192.168.3.4  11055/19
 1011           SR (OSPF)   192.168.2.2  1011
 1022           SR (OSPF)   192.168.2.2  implicit-null
 11044          SR (IS-IS)  192.168.3.4  implicit-null
 11055          SR (IS-IS)  192.168.3.4  11055
 30000          SR (OSPF)   192.168.2.2  implicit-null
 30001          SR (OSPF)   192.168.2.2  implicit-null
 36000          SR (IS-IS)  192.168.3.4  implicit-null

Co-developed-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Change the comment in the code that refers to ZEBRA_FLAG_XXX
defines.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Because the nhlfe label stack may contain more than one
label, ensure to copy all labels.

Co-developed-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
There are 3 tests with OSPF, IS-IS, BGP and MPLS configured:
1. Check the status of BGP session
between North and South == Established
2. Check the connectivity with "ping South -I North"
3. Check the label on the West.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
FEC nexthop entry resolution over MPLS networks

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: FAILED

Test incomplete. See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-13978/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Incomplete

Addresssanitizer topotests part 4: Incomplete (check logs for details)
Successful on other platforms/tests
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests debian 10 amd64 part 2
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 arm8 part 0
  • Static analyzer (clang)
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Ubuntu 20.04 deb pkg check
  • Debian 10 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 5
  • Addresssanitizer topotests part 6
  • Topotests Ubuntu 18.04 amd64 part 1
  • Ubuntu 18.04 deb pkg check
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 arm8 part 1
  • Topotests Ubuntu 18.04 arm8 part 6
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 amd64 part 6
  • Addresssanitizer topotests part 0
  • Topotests debian 10 amd64 part 4
  • Topotests debian 10 amd64 part 3
  • Debian 9 deb pkg check
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 i386 part 4
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests Ubuntu 18.04 i386 part 9
  • Topotests Ubuntu 18.04 arm8 part 7
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests debian 10 amd64 part 5
  • Topotests Ubuntu 18.04 arm8 part 2
  • Topotests debian 10 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 8
  • Addresssanitizer topotests part 7
  • Topotests Ubuntu 18.04 i386 part 6
  • Topotests Ubuntu 18.04 i386 part 1
  • Topotests Ubuntu 18.04 i386 part 7
  • Topotests Ubuntu 18.04 amd64 part 5
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 i386 part 3
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 i386 part 5
  • Topotests Ubuntu 18.04 i386 part 8
  • Topotests Ubuntu 18.04 i386 part 0
  • Addresssanitizer topotests part 3
  • Topotests debian 10 amd64 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 arm8 part 4
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 arm8 part 9
  • Topotests Ubuntu 18.04 amd64 part 4
  • CentOS 7 rpm pkg check

@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants