Unable to connect via P2P even both public IPv6 are available #1251

Closed
opened 2025-11-20 05:26:58 -05:00 by saavagebueno · 3 comments
Owner

Originally created by @jjqtony on GitHub (Sep 16, 2024).

Describe the problem
I am pretty sure that both of my peers have public IPv6 address, however I fail to connect two peers via P2P.

Peer 1: ubunt Linux (with public IPv6)
Peer 2: Alpine linux (with public IPv6)

To Reproduce

Steps to reproduce the behavior:

Start Netbird service on two peers (both of them have public IPv6 address, their ping latency less than 40ms)
Run netbird status -d

Expected behavior

Status: Connected
-- detail --
Connection type: P2P
Direct: true

Are you using NetBird Cloud?

Yes

NetBird version

0.29.2

NetBird status -dA output:
netbird.cloud:
NetBird IP: 100.83.111.47
Status: Connected
-- detail --
Connection type: Relayed
ICE candidate (Local/Remote): relay/prflx
ICE candidate endpoints (Local/Remote): 198.51.100.0:46600/198.51.100.1:32751

Originally created by @jjqtony on GitHub (Sep 16, 2024). **Describe the problem** I am pretty sure that both of my peers have public IPv6 address, however I fail to connect two peers via P2P. Peer 1: ubunt Linux (with public IPv6) Peer 2: Alpine linux (with public IPv6) **To Reproduce** Steps to reproduce the behavior: Start Netbird service on two peers (both of them have public IPv6 address, their ping latency less than 40ms) Run netbird status -d **Expected behavior** Status: Connected -- detail -- Connection type: P2P Direct: true **Are you using NetBird Cloud?** Yes **NetBird version** 0.29.2 **NetBird status -dA output:** netbird.cloud: NetBird IP: 100.83.111.47 Status: Connected -- detail -- Connection type: Relayed ICE candidate (Local/Remote): relay/prflx ICE candidate endpoints (Local/Remote): 198.51.100.0:46600/198.51.100.1:32751
saavagebueno added the waiting-feedbacktriage-neededlinux labels 2025-11-20 05:26:58 -05:00
Author
Owner

@jclds139 commented on GitHub (Dec 12, 2024):

I'm running into the problem right now as well. I think (not absolutely certain), that it's related to client/internal/peer/worker_ice.go@153.
When I run the client manually, I get error in the form of
2024-12-12T16:59:14-05:00 WARN [peer: *****************=] client/internal/peer/worker_ice.go:269: got an error while resolving the udp address, err: address ****:****:****:****:****:****:****:****:51820: too many colons in address. which is triggering from line 267 which resolves the addresses. The go docs say If the host is a literal IPv6 address it must be enclosed in square brackets, as in "[2001:db8::1]:80" or "[fe80::1%zone]:80" (https://pkg.go.dev/net#Dial), so I'm guessing that up at line 153 there needs to be a check for IPv6 addresses so that the string is formatted correctly when loaded from the ice CandidatePair.

If so, that means this issue and #2327 are related.

@jclds139 commented on GitHub (Dec 12, 2024): I'm running into the problem right now as well. I think (not absolutely certain), that it's related to [client/internal/peer/worker_ice.go@153](https://github.com/netbirdio/netbird/blob/dcba6a6b7e5bcb8980860fee4d634002a9270e56/client/internal/peer/worker_ice.go#L153). When I run the client manually, I get error in the form of `2024-12-12T16:59:14-05:00 WARN [peer: *****************=] client/internal/peer/worker_ice.go:269: got an error while resolving the udp address, err: address ****:****:****:****:****:****:****:****:51820: too many colons in address`. which is triggering from [line 267](https://github.com/netbirdio/netbird/blob/dcba6a6b7e5bcb8980860fee4d634002a9270e56/client/internal/peer/worker_ice.go#L267) which resolves the addresses. The go docs say `If the host is a literal IPv6 address it must be enclosed in square brackets, as in "[2001:db8::1]:80" or "[fe80::1%zone]:80"` (https://pkg.go.dev/net#Dial), so I'm guessing that up at line 153 there needs to be a check for IPv6 addresses so that the string is formatted correctly when loaded from the ice `CandidatePair`. If so, that means this issue and #2327 are related.
Author
Owner

@nazarewk commented on GitHub (Apr 28, 2025):

Hello @jjqtony,

We're currently reviewing our open issues and would like to verify if this problem still exists in the latest NetBird version.

Could you please confirm if the issue is still there?

We may close this issue temporarily if we don't hear back from you within 2 weeks, but feel free to reopen it with updated information.

Thanks for your contribution to improving the project!

@nazarewk commented on GitHub (Apr 28, 2025): Hello @jjqtony, We're currently reviewing our open issues and would like to verify if this problem still exists in the [latest NetBird version](https://github.com/netbirdio/netbird/releases). Could you please confirm if the issue is still there? We may close this issue temporarily if we don't hear back from you within **2 weeks**, but feel free to reopen it with updated information. Thanks for your contribution to improving the project!
Author
Owner

@mlsmaycon commented on GitHub (Jun 1, 2025):

closing issue due to no recent feedback. Feel free to open a new one if the issue persist or reopen if this was a feature request.

@mlsmaycon commented on GitHub (Jun 1, 2025): closing issue due to no recent feedback. Feel free to open a new one if the issue persist or reopen if this was a feature request.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SVI/netbird#1251