-
-
Notifications
You must be signed in to change notification settings - Fork 581
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
ip route
conflicts and race conditions when resolving best routes in clientNetwork.getBestRouteFromStatuses()
#2066
Comments
I've noticed that I was connected to the I had to do |
a single
making it impossible to know about other |
theoretically using netbird/client/internal/routemanager/manager.go Lines 243 to 251 in f176807
but I am not sure about the wider consequences |
@mlsmaycon noted that this part of the issue (removing routes still in use) will be fixed by #1943 , since it is a big refactor of (previously) linked code in this issue it will be worth analyzing and revisiting again after #1943 is merged |
ip route metric
to clientNetwork.getBestRouteFromStatuses()
ip route
conflicts and race conditions when resolving best routes in clientNetwork.getBestRouteFromStatuses()
Describe the problem
I have noticed the client-side route selection feature so during today's Netbird workshop for our team I have enabled both routes clashing on
10.4/16
and later today teammates started reporting problems with accessing theprimary
system so I switched thesecondary
off and dug into the code.First thing I have noticed using
ip route metric
was superseded by:Route.Metric
as the most significant scoring,7120
akanetbird
(the one I discovered in Make multiple Netbird client instances cooperate on theip route table
level on Linux (possibly other OS too?) #2023 )metric
parameter to createdip route
at allThe method is scoped to
*clientNetwork
, which I guess does not consider a possibility of anotherNetworkID
providing the same CIDR (10.4/16
in our case) resulting in a conflict/race condition on the createdip route
entry.To Reproduce
Steps to reproduce the behavior:
Expected behavior
Either of:
ip route
with themetric
argument (seems to benetlink.Route.Priority
) which would properly prioritize routes on theip route
level even in case of a clashAre you using NetBird Cloud?
Yes
NetBird version
0.27.7
NetBird status -d output:
If applicable, add the `netbird status -d' command output.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: