Skip to content

Local subnets relaying due to route metrics. #4990

Description

@1nerdyguy

Describe the problem

Been happening for numerous versions now, but I'm having an issue I can't resolve.

I have a multi-vlan environment, as I'd expect many do. One of those vlans, lets say 10.10.10.x/24, I'm publishing as a Network so clients can access it when remote. These clients are all Windows for this discussion

The issue I run into is, when those clients aren't remote, but are on premise and say in the 10.10.11.x/24 subnet, the route distributed by netbird for 10.10.10.x/24 gets placed into the routing table with lower metric than the existing default gateway. As such, any client that tries to access 10.10.10.x/24 will go out through the netbird interface, relay about, and come back to hit that network as if they are remote.

Windows adds like 256 or something to local routes by default, so this is difficult to handle.

The answer would be to not use Netbird when on premise, which I agree with. However, with setup keys vs making users login (for an always-on setup where you identify the device vs user for ACL), this becomes difficult.

Posture checks are not an option without a large amount of overhead in cases of numerous client vlans, and still wanting to use Netbird to access some vlans all the time (air gapped vlans, etc)

To Reproduce
Pass a network through Netbird.
Go into a vlan that has that network OR has L3 access to that network.
Watch how your traffic goes out Netbird vs local resources, adding latency.

Expected behavior
Netbird routes get applied with a metric that doesn't make it lower than the standard windows metrics, allowing local routes to take precedent without manual intervention client side.

Are you using NetBird Cloud?

Both, and is the same on both.

NetBird version

from .38 to now.

Is any other VPN software installed?

No
Debug output

To help us resolve the problem, please attach the following anonymized status output

netbird status -dA

Create and upload a debug bundle, and share the returned file key:

netbird debug for 1m -AS -U

Uploaded files are automatically deleted after 30 days.

Alternatively, create the file only and attach it here manually:

netbird debug for 1m -AS

Screenshots

If applicable, add screenshots to help explain your problem.

Additional context

Add any other context about the problem here.

Have you tried these troubleshooting steps?

  • Reviewed client troubleshooting (if applicable)
  • Checked for newer NetBird versions
  • Searched for similar issues on GitHub (including closed ones)
  • Restarted the NetBird client
  • Disabled other VPN software
  • Checked firewall settings

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions