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

bgp: multiple fixes for route leaking #11886

Closed
wants to merge 26 commits into from

Conversation

pguibert6WIND
Copy link
Member

continuation of #11127

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Aug 31, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7186/artifact/TOPO4U18I386/ErrorLog/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-7186/test

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

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

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7186/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

Topotests Ubuntu 18.04 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Successful on other platforms/tests
  • Topotests Ubuntu 18.04 amd64 part 1
  • Static analyzer (clang)
  • Addresssanitizer topotests part 1
  • Ubuntu 18.04 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests debian 10 amd64 part 2
  • Topotests debian 10 amd64 part 7
  • IPv4 protocols on Ubuntu 18.04
  • Topotests Ubuntu 18.04 arm8 part 0
  • Debian 9 deb pkg check
  • 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
  • Ubuntu 20.04 deb pkg check
  • Debian 10 deb pkg check
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests debian 10 amd64 part 1
  • Addresssanitizer topotests part 4
  • Topotests Ubuntu 18.04 arm8 part 5
  • Addresssanitizer topotests part 0
  • Topotests Ubuntu 18.04 i386 part 9
  • Topotests debian 10 amd64 part 3
  • 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
  • Topotests Ubuntu 18.04 i386 part 6
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 i386 part 1
  • IPv4 ldp protocol on Ubuntu 18.04
  • Addresssanitizer topotests part 7
  • Topotests Ubuntu 18.04 arm8 part 8
  • Topotests Ubuntu 18.04 arm8 part 1
  • Topotests Ubuntu 18.04 arm8 part 6
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 i386 part 7
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests Ubuntu 18.04 amd64 part 5
  • Fedora 29 rpm pkg check
  • Addresssanitizer topotests part 6
  • Topotests Ubuntu 18.04 i386 part 5
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 i386 part 3
  • CentOS 7 rpm pkg check
  • Topotests debian 10 amd64 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 9
  • Addresssanitizer topotests part 2
  • IPv6 protocols on Ubuntu 18.04

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Aug 31, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7185/artifact/TOPO4U18I386/ErrorLog/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-7185/test

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

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

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7185/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

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

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 2
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7185/artifact/TP2U1804AMD64/ErrorLog/log_topotests.txt

Topotests Ubuntu 18.04 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Successful on other platforms/tests
  • Topotests Ubuntu 18.04 amd64 part 1
  • Debian 9 deb pkg check
  • Ubuntu 18.04 deb pkg check
  • Addresssanitizer topotests part 1
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 8
  • IPv4 protocols on Ubuntu 18.04
  • Topotests debian 10 amd64 part 7
  • Topotests Ubuntu 18.04 arm8 part 0
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 9
  • Debian 10 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 6
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests debian 10 amd64 part 1
  • Addresssanitizer topotests part 5
  • Addresssanitizer topotests part 4
  • Topotests Ubuntu 18.04 arm8 part 5
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 i386 part 9
  • Addresssanitizer topotests part 0
  • Static analyzer (clang)
  • Topotests debian 10 amd64 part 3
  • Topotests debian 10 amd64 part 5
  • Topotests debian 10 amd64 part 0
  • Ubuntu 16.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 2
  • Topotests Ubuntu 18.04 arm8 part 7
  • Topotests Ubuntu 18.04 i386 part 1
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 i386 part 6
  • IPv4 ldp protocol on Ubuntu 18.04
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests Ubuntu 18.04 arm8 part 6
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 arm8 part 1
  • Addresssanitizer topotests part 7
  • Topotests Ubuntu 18.04 arm8 part 8
  • Topotests Ubuntu 18.04 i386 part 7
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 amd64 part 5
  • Topotests Ubuntu 18.04 i386 part 5
  • Addresssanitizer topotests part 6
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests Ubuntu 18.04 i386 part 3
  • CentOS 7 rpm pkg check
  • Fedora 29 rpm pkg check
  • Topotests Ubuntu 18.04 amd64 part 0
  • Topotests debian 10 amd64 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 arm8 part 9
  • Addresssanitizer topotests part 2
  • Topotests Ubuntu 18.04 amd64 part 3
  • IPv6 protocols on Ubuntu 18.04

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 1, 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-7191/

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

NetDEF-CI commented Sep 1, 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-7195/

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.

@pguibert6WIND pguibert6WIND changed the title bgp: multiple fixes for route leaking - draft bgp: multiple fixes for route leaking Sep 1, 2022
@pguibert6WIND pguibert6WIND reopened this Sep 5, 2022
@pguibert6WIND
Copy link
Member Author

ci:rerun

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 5, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 6: Failed (click for details)

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

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

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

@pguibert6WIND
Copy link
Member Author

ci:rerun

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 5, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 6: Failed (click for details)

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

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7232/artifact/TOPO6DEB10AMD64/ErrorLog/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-7232/test

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

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

pguibert6WIND and others added 11 commits September 5, 2022 17:24
When redistributing connected addresses, the address family has
to be figured out. The calculation was not done, the next-hop
address length was not set, and as consequence, the nexthop
is displayed like if it was an ipv6 address, which is wrong for
ipv4 addresses.

Calculate the family for connected addresses.
Change the topotests accordingly.

Fixes: ("7226bc40d606") bgpd: ignore NEXT_HOP for MP_REACH_NLRI

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Prefixes that are stated in the network command cannot be leaked to
the other VRFs BGP table whether or not they are present in the origin
VRF RIB.

Always validate the nexthop of BGP static routes (i.e. defined with the
network statement) if 'no network import-check' is defined on the source
BGP session.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
If 'network import-check' is defined on the source BGP session, prefixes
that are stated in the network command cannot be leaked to the other
VRFs BGP table even if they are present in the origin VRF RIB.

Always validate the nexthop of BGP static routes (i.e. defined with the
network statement) if 'network import-check' is defined on the source
BGP session and the prefix is present in source RIB.

It fixes the issue when the 'rt import' statement is defined after the
'network' ones.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
Move setting of some variables backwards to prepare next commits.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
"if not XX else" statements are confusing.

Replace two "if not XX else" statements by "if XX else" to prepare next
commits. The patch is only cosmetic.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
If 'network import-check' is defined on the source BGP session, prefixes
that are stated in the network command cannot be leaked to the other
VRFs BGP table even if they are present in the origin VRF RIB if the
'rt import' statement is defined after the 'network <prefix>' ones.

When a prefix nexthop is updated, update the prefix route leaking. The
current state of nexthop validation is now stored in the attributes of
the bgp path info. Attributes are compared with the previous ones at
route leaking update so that a nexthop validation change now triggers
the update of destination VRF BGP table.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
The following configuration creates an infinite routing leaking loop
because 'rt vpn both' parameters are the same in both VRFs.

> router bgp 5227 vrf r1-cust4
>    no bgp network import-check
>    bgp router-id 192.168.1.1
>    address-family ipv4 unicast
>      network 28.0.0.0/24
>      rd vpn export 10:12
>      rt vpn both 52:100
>      import vpn
>      export vpn
>    exit-address-family
> !
> router bgp 5227 vrf r1-cust5
>    no bgp network import-check
>    bgp router id 192.168.1.1
>    address-family ipv4 unicast
>      network 29.0.0.0/24
>      rd vpn export 10:13
>      rt vpn both 52:100
>      import vpn
>      export vpn
>    exit-address-family

The previous commit has added a routing leak update when a nexthop
update is received from zebra. It indirectly calls
bgp_find_or_add_nexthop() in which a static route triggers a nexthop
cache entry registration that triggers a nexthop update from zebra.

Do not register again the nexthop cache entry if the BGP_STATIC_ROUTE is
already set.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
Add a function to find the VRF or the loopback interface: the loopback
interface for the default VRF and the VRF master interface otherwise.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
Fix a CLANG warning

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
There is two cases where the nexthop interface is incorrect:

- Case 1: leaked routes from prefixes stated in 'network <prefix>' are
  inactive because they have no nexthop IP address or interface.
- Case 2: leaked routes from 'redistribute connected' contains the
  original nexthop interface.

======
Case 1
======
> router bgp 5227 vrf r1-cust1
>  bgp router-id 192.168.1.1
>  no bgp network import-check
> !
>  address-family ipv4 unicast
>   network 10.2.3.4/32
>   network 192.168.1.0/24
>   rd vpn export 10:1
>   rt vpn import 52:100
>   rt vpn export 52:101
>   export vpn
>   import vpn
>  exit-address-family
> exit
> !
> router bgp 5227 vrf r1-cust4
>  bgp router-id 192.168.1.1
> !
>  address-family ipv4 unicast
>   network 29.0.0.0/24
>   rd vpn export 10:1
>   rt vpn import 52:101
>   rt vpn export 52:100
>   export vpn
>   import vpn
>  exit-address-family
> exit

Extract from the routing table:

> VRF r1-cust1:
> S>* 192.0.0.0/24 [1/0] via 192.168.1.2, r1-eth4, weight 1, 00:47:53
> C>* 192.168.1.0/24 is directly connected, r1-eth4, 00:44:15
> B>* 29.0.0.0/24 [20/0] is directly connected, unknown (vrf r1-cust4), inactive, weight 1, 00:00:02
>
> VRF r1-cust4:
> B   10.2.3.4/32 [20/0] is directly connected, unknown (vrf r1-cust1) inactive, weight 1, 00:00:02
> C>* 29.0.0.0/24 is directly connected, r1-cust5, 00:27:40
> B   192.0.0.0/24 [20/0] is directly connected, unknown (vrf r1-cust1) inactive, weight 1, 00:03:40
> B   192.168.1.0/24 [20/0] is directly connected, unknown (vrf r1-cust1) inactive, weight 1, 00:00:02

======
Case 2
======

The previous is modified with the following settings:

> router bgp 5227 vrf r1-cust1
>  address-family ipv4 unicast
>   no network 192.168.1.0/24
>   redistribute connected
> !
> vrf r1-cust1
> ip route 29.0.0.0/24 r1-cust5 nexthop-vrf r1-cust5

Extract from the routing table:
> VRF r1-cust1:
> S>* 192.0.0.0/24 [1/0] via 192.168.1.2, r1-eth4, weight 1, 00:47:53
> C>* 192.168.1.0/24 is directly connected, r1-eth4, 00:44:15
> S>* 29.0.0.0/24 [1/0] is directly connected, r1-cust5 (vrf r1-cust5), weight 1, 00:00:30
>
> VRF r1-cust4:
> B   10.2.3.4/32 [20/0] is directly connected, unknown (vrf r1-cust1) inactive, weight 1, 00:00:02
> C>* 29.0.0.0/24 is directly connected, r1-cust5, 00:27:40
> B   192.0.0.0/24 [20/0] is directly connected, unknown (vrf r1-cust1) inactive, weight 1, 00:03:40
> B>* 192.168.1.0/24 [20/0] is directly connected, r1-eth4 (vrf r1-cust1), weight 1, 00:00:02

The nexthop interface is r1-eth4. It causes issue to traffic leaving
r1-cust4. The following ping to r1-eth4 local address 192.168.1.1 from
r1-cust5 local add does
not respond.

> # tcpdump -lnni r1-cust1 'icmp' &
> # ip vrf exec r1-cust4 ping -c1 192.168.1.1 -I 29.0.0.1
> PING 192.168.1.1 (192.168.1.1) 56(84) bytes of data.
PING 192.168.1.1 (192.168.1.1) from 29.0.0.1 : 56(84) bytes of data.
18:49:20.635638 IP 29.0.0.1 > 192.168.1.1: ICMP echo request, id 15897, seq 1, length 64
18:49:27.113827 IP 29.0.0.1 > 29.0.0.1: ICMP host 192.168.1.1 unreachable, length 92

Fix description:

When leaking prefix from other VRFs, if the nexthop IP address is not
set in the bgp path info attribures, reset nh_ifindex to the index of
master interface of the incoming BGP instance.

The result is for case 1 and 2:

> VRF r1-cust1:
> S>* 192.0.0.0/24 [1/0] via 192.168.1.2, r1-eth4, weight 1, 00:47:53
> C>* 192.168.1.0/24 is directly connected, r1-eth4, 00:44:15
> B>* 29.0.0.0/24 [20/0] is directly connected, r1-cust4 (vrf r1-cust4), weight 1, 00:00:08
>
> VRF r1-cust4:
> B>* 10.2.3.4/32 [20/0] is directly connected, r1-cust1 (vrf r1-cust1), weight 1, 00:00:08
> C>* 29.0.0.0/24 is directly connected, r1-cust5, 00:27:40
> B>* 192.0.0.0/24 [20/0] is directly connected, r1-cust1 (vrf r1-cust1), weight 1, 00:00:08
> B>* 192.168.1.0/24 [20/0] is directly connected, r1-cust1 (vrf r1-cust1), weight 1, 00:00:08

> # tcpdump -lnni r1-cust1 'icmp' &
> # ping -c1 192.168.1.1 -I 29.0.0.1
> PING 192.168.1.1 (192.168.1.1) from 29.0.0.1 : 56(84) bytes of data.
> 18:48:32.506281 IP 29.0.0.1 > 192.168.1.1: ICMP echo request, id 15870, seq 1, length 64
> 64 bytes from 192.168.1.1: icmp_seq=1 ttl=64 time=0.050 ms
> 18:48:32.506304 IP 192.168.1.1 > 29.0.0.1: ICMP echo reply, id 15870, seq 1, length 64

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>

 1, 00:47:53
4:15
vrf r1-cust4), inactive, weight 1, 00:00:02

vrf r1-cust1) inactive, weight 1, 00:00:02
40
(vrf r1-cust1) inactive, weight 1, 00:03:40
n (vrf r1-cust1) inactive, weight 1, 00:00:02

dress is not
the index of

 1, 00:47:53
4:15
(vrf r1-cust4), weight 1, 00:00:08

(vrf r1-cust1), weight 1, 00:00:08
40
 (vrf r1-cust1), weight 1, 00:00:08
t1 (vrf r1-cust1), weight 1, 00:00:08
Leaked connected routes have now the following nexthop interfaces:
- lo for routes imported from the default VRF
- or the VRF interface for routes imported from the other VRFs.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
@pguibert6WIND
Copy link
Member Author

ci:rerun

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 5, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 6: Failed (click for details)

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

Topology Tests failed for Topotests debian 10 amd64 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7246/artifact/TOPO6DEB10AMD64/ErrorLog/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-7246/test

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

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

@pguibert6WIND
Copy link
Member Author

test fail because of calling 'ip vrf exec <> ping ' : BPF prog: 'Operation not permitted'

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 6, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Topotests Ubuntu 18.04 amd64 part 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7264/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

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

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7264/artifact/TOPO4U18I386/ErrorLog/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-7264/test

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

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

@pguibert6WIND
Copy link
Member Author

the last commit may probably need to have boot parameters for debian 10 : "cgroup_no_v1=net_prio,net_cls" as suggested by https://bugzilla.kernel.org/show_bug.cgi?id=203483

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 6, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 4: Failed (click for details)

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

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

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

@riw777 riw777 self-requested a review September 6, 2022 15:23
@Jafaral Jafaral requested a review from eqvinox September 6, 2022 15:31
@eqvinox
Copy link
Contributor

eqvinox commented Sep 6, 2022

@pguibert6WIND actually you can use 2 -I options on ping to replace ip vrf exec, e.g. ping -I vrfname -I 1.2.3.4 2.3.4.5

tested with this ping version:

# ping -V       
ping from iputils 20211215

will double check in CI

The iproute2 utility is able to handle two '-I' parameters, with
the first one which is the vrf name where the ping command should sit,
and the second one which is the source address.
This change avoids using 'ip vrf exec' which may fail on some
distributions like debian 10.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
@pguibert6WIND
Copy link
Member Author

@pguibert6WIND actually you can use 2 -I options on ping to replace ip vrf exec, e.g. ping -I vrfname -I 1.2.3.4 2.3.4.5

tested with this ping version:

# ping -V       
ping from iputils 20211215

will double check in CI

lets see what happens with that change.

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 6, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 4: Failed (click for details)

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

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

Topotests Ubuntu 18.04 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Topotests Ubuntu 18.04 amd64 part 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7273/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

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

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 6
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7273/artifact/TOPO6U18I386/ErrorLog/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-7273/test

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

Topotests Ubuntu 18.04 arm8 part 6: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 6: No useful log found
Topotests Ubuntu 18.04 i386 part 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7273/artifact/TOPO4U18I386/ErrorLog/log_topotests.txt

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

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

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

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

@pguibert6WIND
Copy link
Member Author

pguibert6WIND commented Sep 7, 2022

@pguibert6WIND actually you can use 2 -I options on ping to replace ip vrf exec, e.g. ping -I vrfname -I 1.2.3.4 2.3.4.5
tested with this ping version:

# ping -V       
ping from iputils 20211215

will double check in CI

lets see what happens with that change.

@eqvinox proposed solution does not work.

build	06-Sep-2022 10:38:41		args: /usr/bin/nsenter -a -t 11068 -F --wd=/tmp/topotests/bgp_vrf_route_leak_basic.test_bgp-vrf-route-leak-basic/r1 /bin/bash -c ping -c1 10.0.0.1 -I DONNA -I 10.0.0.1
build	06-Sep-2022 10:38:41		stderr: bind: Cannot assign requested address:
error	06-Sep-2022 10:38:41	ERROR:topolog:test failed at "test_bgp-vrf-route-leak-basic/test_vrf_route_leak_test1": Ping from VRF fails - check https://bugzilla.kernel.org/show_bug.cgi?id=203483

@eqvinox
Copy link
Contributor

eqvinox commented Sep 7, 2022

Sigh. It was added in 2019: iputils/iputils@9e08707

ping on Ubuntu 18.04 is 20161105

The number of routes in BGP ce devices was wrong.
Change the expected values.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
…mmand after expected result found"

This reverts commit 6804af7.
@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 8, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 4: Failed (click for details)

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

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

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

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 8, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Topotests Ubuntu 18.04 i386 part 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7295/artifact/TOPO4U18I386/ErrorLog/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-7295/test

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

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

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7295/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

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

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: FAILED

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

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 arm8 part 4: Failed (click for details) Topotests Ubuntu 18.04 arm8 part 4: No useful log found
Topotests Ubuntu 18.04 i386 part 4: Failed (click for details)

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

Topology Tests failed for Topotests Ubuntu 18.04 i386 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7298/artifact/TOPO4U18I386/ErrorLog/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-7298/test

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

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

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

Topology Tests failed for Topotests Ubuntu 18.04 amd64 part 4
see full log at https://ci1.netdef.org/browse/FRR-PULLREQ2-7298/artifact/TP4U1804AMD64/ErrorLog/log_topotests.txt

Successful on other platforms/tests
  • Topotests Ubuntu 18.04 amd64 part 6
  • Topotests Ubuntu 18.04 i386 part 8
  • Addresssanitizer topotests part 0
  • Topotests debian 10 amd64 part 8
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 arm8 part 9
  • Topotests debian 10 amd64 part 3
  • Debian 10 deb pkg check
  • IPv6 protocols on Ubuntu 18.04
  • Addresssanitizer topotests part 1
  • Topotests Ubuntu 18.04 arm8 part 3
  • Topotests Ubuntu 18.04 i386 part 3
  • Addresssanitizer topotests part 4
  • IPv4 protocols on Ubuntu 18.04
  • Debian 9 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 9
  • Topotests Ubuntu 18.04 i386 part 9
  • Addresssanitizer topotests part 7
  • Static analyzer (clang)
  • Ubuntu 16.04 deb pkg check
  • Addresssanitizer topotests part 5
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 i386 part 6
  • Topotests Ubuntu 18.04 amd64 part 8
  • Topotests debian 10 amd64 part 2
  • Topotests Ubuntu 18.04 i386 part 1
  • Topotests Ubuntu 18.04 arm8 part 0
  • Topotests Ubuntu 18.04 arm8 part 5
  • IPv4 ldp protocol on Ubuntu 18.04
  • Topotests Ubuntu 18.04 arm8 part 1
  • Topotests Ubuntu 18.04 arm8 part 6
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests Ubuntu 18.04 amd64 part 0
  • Addresssanitizer topotests part 2
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 amd64 part 5
  • Fedora 29 rpm pkg check
  • 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 7
  • Addresssanitizer topotests part 3
  • Addresssanitizer topotests part 9
  • CentOS 7 rpm pkg check
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 arm8 part 8
  • Topotests debian 10 amd64 part 9
  • Topotests Ubuntu 18.04 i386 part 7
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests Ubuntu 18.04 i386 part 2
  • Addresssanitizer topotests part 6
  • Topotests Ubuntu 18.04 amd64 part 1
  • Topotests Ubuntu 18.04 i386 part 5
  • Ubuntu 18.04 deb pkg check
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests debian 10 amd64 part 7

Copy link
Member

@riw777 riw777 left a comment

Choose a reason for hiding this comment

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

one small nit/question, otherwise this looks fine

bgp_attr_get_transit(attr2) &&
attr1->rmap_table_id == attr2->rmap_table_id &&
(attr1->encap_tunneltype == attr2->encap_tunneltype) &&
encap_same(attr1->encap_subtlvs, attr2->encap_subtlvs)
#ifdef ENABLE_BGP_VNC
Copy link
Member

Choose a reason for hiding this comment

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

the formatting of all the other defines are changed but these ... should these be changed as well?

@mwinter-osr
Copy link
Member

CI:rerun Abusing this PR to verify CI upgrade

@github-actions
Copy link

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

1 similar comment
@github-actions
Copy link

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

@riw777
Copy link
Member

riw777 commented Jan 17, 2023

waiting on the conflicts here to re-review and see where we are ...

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