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: Get link from the correct netns for vxlan #8895

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

leonshaw
Copy link
Contributor

If VRF backend is netns, bridges and SVIs are in the VRF's netns.
Get link information from there, rather than NS_DEFAULT.

Copy link

@polychaeta polychaeta left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution to FRR!

Click for style suggestions

To apply these suggestions:

curl -s https://gist.githubusercontent.com/polychaeta/3a197daf037246e29f9818d19414be2d/raw/08ce2bd16556525e398625a668c26e0c1a25362b/cr_8895_1624328326.diff | git apply

diff --git a/zebra/zebra_vxlan.c b/zebra/zebra_vxlan.c
index 8a7b12c0b..873e4e462 100644
--- a/zebra/zebra_vxlan.c
+++ b/zebra/zebra_vxlan.c
@@ -2032,7 +2032,8 @@ static int zebra_vxlan_handle_vni_transition(struct zebra_vrf *zvrf, vni_t vni,
 				   vni);
 
 		/* Find VxLAN interface for this VNI. */
-		for (rn = route_top(zvrf->zns->if_table); rn; rn = route_next(rn)) {
+		for (rn = route_top(zvrf->zns->if_table); rn;
+		     rn = route_next(rn)) {
 			ifp = (struct interface *)rn->info;
 			if (!ifp)
 				continue;

If you are a new contributor to FRR, please see our contributing guidelines.

After making changes, you do not need to create a new PR. You should perform an amend or interactive rebase followed by a force push.

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Jun 22, 2021

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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: Failed

Checkout code: Failed (click for details) Checkout code: No useful log found

@LabN-CI
Copy link
Collaborator

LabN-CI commented Jun 22, 2021

Outdated results 💚

Basic BGPD CI results: SUCCESS, 0 tests failed

_ _
Result 0
Date
Start
Finish vncregress-2021-06-21-22:20:50.txt
Run-Time autoscript-2021-06-21-22:22:01.log.bz2
Total 516 501 424
Pass SUCCESS git merge/8584 c921cf3
Fail 04/27/2021
Valgrind-Errors 22:20:50
Valgrind-Loss 23:01:55
Details 41:05
Log 1815
Memory 1815
SUCCESS git merge/8895 33df0a8 0
06/21/2021 0
22:20:50 0
22:46:14 vncregress-2021-04-27-22:20:50.txt
25:24 autoscript-2021-04-27-22:22:00.log.bz2
1815 502 505 428
1815

For details, please contact louberger

@LabN-CI
Copy link
Collaborator

LabN-CI commented Jun 22, 2021

Outdated results 🚧

Basic BGPD CI results: Partial FAILURE, 1 tests failed

_ _
Result 1
Date
Start
Finish vncregress-2021-06-21-22:50:51.txt
Run-Time autoscript-2021-06-21-22:52:10.log.bz2
Total 510 502 429
Pass SUCCESS git merge/8556 7e0ea66
Fail 04/23/2021
Valgrind-Errors 22:50:57
Valgrind-Loss 23:32:29
Details 41:32
Log 1815
Memory 1815
SUCCESS git merge/8895 1586ab1 0
06/21/2021 0
22:50:51 0
23:16:29 vncregress-2021-04-23-22:50:57.txt
25:38 autoscript-2021-04-23-22:52:03.log.bz2
1815 502 509 429
1814

For details, please contact louberger

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Jun 22, 2021

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-FRRPULLREQ-19738/

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.

@pjdruddy pjdruddy assigned pjdruddy and unassigned pjdruddy Jun 25, 2021
@pjdruddy pjdruddy self-requested a review June 25, 2021 08:26
@leonshaw
Copy link
Contributor Author

Rebased against master.
Removed zl3vni_from_svi() part as is resolved in #9416 by a walk through all namespaces. However, I think the walk could be avoided since the vxlan interface is in the same VRF of the bridge, which is already known (see original commit of this PR).

@LabN-CI
Copy link
Collaborator

LabN-CI commented Sep 27, 2021

Outdated results 💚

Basic BGPD CI results: SUCCESS, 0 tests failed

_ _
Result SUCCESS git merge/8895 c220ed4
Date 09/27/2021
Start 10:48:52
Finish 11:15:02
Run-Time 26:10
Total 1813
Pass 1813
Fail 0
Valgrind-Errors 0
Valgrind-Loss 0
Details vncregress-2021-09-27-10:48:52.txt
Log autoscript-2021-09-27-10:49:58.log.bz2
Memory 508 518 425

For details, please contact louberger

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Sep 27, 2021

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-361/

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 7, 2022

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 9: Failed (click for details) Topotests debian 10 amd64 part 9: Unknown Log URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-7275/artifact/TOPO9DEB10AMD64/ErrorLog/ Topotests debian 10 amd64 part 9: No useful log found
Successful on other platforms/tests
  • Topotests debian 10 amd64 part 4
  • 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 arm8 part 3
  • Addresssanitizer topotests part 5
  • Topotests Ubuntu 18.04 amd64 part 2
  • Topotests Ubuntu 18.04 amd64 part 3
  • Topotests debian 10 amd64 part 3
  • Addresssanitizer topotests part 0
  • Topotests debian 10 amd64 part 8
  • Topotests Ubuntu 18.04 i386 part 6
  • Topotests Ubuntu 18.04 arm8 part 9
  • Topotests Ubuntu 18.04 arm8 part 4
  • Addresssanitizer topotests part 2
  • Ubuntu 20.04 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 5
  • IPv6 protocols on Ubuntu 18.04
  • IPv4 ldp protocol on Ubuntu 18.04
  • Ubuntu 16.04 deb pkg check
  • Debian 10 deb pkg check
  • Topotests Ubuntu 18.04 amd64 part 4
  • IPv4 protocols on Ubuntu 18.04
  • Topotests Ubuntu 18.04 i386 part 1
  • Topotests Ubuntu 18.04 i386 part 3
  • Addresssanitizer topotests part 9
  • Topotests Ubuntu 18.04 arm8 part 2
  • Topotests Ubuntu 18.04 i386 part 8
  • Topotests Ubuntu 18.04 amd64 part 7
  • Topotests debian 10 amd64 part 0
  • Topotests Ubuntu 18.04 arm8 part 7
  • Addresssanitizer topotests part 3
  • Topotests Ubuntu 18.04 amd64 part 9
  • Addresssanitizer topotests part 6
  • Topotests Ubuntu 18.04 arm8 part 5
  • Fedora 29 rpm pkg check
  • CentOS 7 rpm pkg check
  • Topotests debian 10 amd64 part 1
  • Topotests Ubuntu 18.04 i386 part 9
  • 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
  • Topotests Ubuntu 18.04 amd64 part 0
  • Static analyzer (clang)
  • Topotests Ubuntu 18.04 i386 part 0
  • Topotests Ubuntu 18.04 i386 part 5
  • Ubuntu 18.04 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 arm8 part 6
  • Topotests Ubuntu 18.04 i386 part 2
  • Topotests debian 10 amd64 part 6
  • Topotests Ubuntu 18.04 arm8 part 1
  • Addresssanitizer topotests part 8
  • Topotests Ubuntu 18.04 amd64 part 6
  • Topotests debian 10 amd64 part 5

@leonshaw
Copy link
Contributor Author

leonshaw commented Sep 7, 2022

ci:rerun

@NetDEF-CI
Copy link
Collaborator

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

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.

@leonshaw
Copy link
Contributor Author

leonshaw commented Sep 8, 2022

@pjdruddy It's long since this PR was open, any comments?

@pguibert6WIND Could have look at this maybe?

@github-actions
Copy link

github-actions bot commented Mar 7, 2023

This PR is stale because it has been open 180 days with no activity. Comment or remove the autoclose label in order to avoid having this PR closed.

@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-10088/

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.

@leonshaw
Copy link
Contributor Author

rebased

@ton31337
Copy link
Member

@Mergifyio rebase

If VRF backend is netns, bridges and SVIs are in the VRF's netns.
Get link information from there, rather than NS_DEFAULT.

Signed-off-by: Xiao Liang <[email protected]>
Copy link

mergify bot commented Dec 15, 2023

rebase

✅ Branch has been successfully rebased

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.

LGTM

@ton31337
Copy link
Member

@chiragshah6 would you like to take a look at this before merging?

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