avalanchego
avalanchego copied to clipboard
Regression: NAT Traversal constantly fails on 1.5.3
Describe the bug NAT traversal constantly fails on 1.5.3 while it's had no problems on Linux pre-1.5.3. NAT traversal with 1.5.2 and older versions work fine from the first attempt. Reverting the container back to 1.5.2 fixes this issue.
This is an upgrade blocker currently.
I feel like this might be a problem with a newer version of goupnp if it's updated. I didn't check the code though.
To Reproduce Start avalanchego v1.5.3.
Expected behavior NAT Traversal should succeed.
Logs 1.5.3 logs:
ERROR[09-10|02:40:15] /build/nat/nat.go#90: Renewing port mapping try #1 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:40:16] /build/nat/nat.go#90: Renewing port mapping try #2 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:40:17] /build/nat/nat.go#90: Renewing port mapping try #3 from external port 9651 to internal port 9651 failed with unknown protocol TCP
WARN [09-10|02:40:18] /build/nat/nat.go#120: Renew NAT Traversal failed from external port 9651 to internal port 9651 with unknown protocol TCP
ERROR[09-10|02:45:18] /build/nat/nat.go#90: Renewing port mapping try #1 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:45:19] /build/nat/nat.go#90: Renewing port mapping try #2 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:45:20] /build/nat/nat.go#90: Renewing port mapping try #3 from external port 9651 to internal port 9651 failed with unknown protocol TCP
WARN [09-10|02:45:21] /build/nat/nat.go#120: Renew NAT Traversal failed from external port 9651 to internal port 9651 with unknown protocol TCP
ERROR[09-10|02:50:21] /build/nat/nat.go#90: Renewing port mapping try #1 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:50:22] /build/nat/nat.go#90: Renewing port mapping try #2 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:50:23] /build/nat/nat.go#90: Renewing port mapping try #3 from external port 9651 to internal port 9651 failed with unknown protocol TCP
WARN [09-10|02:50:24] /build/nat/nat.go#120: Renew NAT Traversal failed from external port 9651 to internal port 9651 with unknown protocol TCP
ERROR[09-10|02:55:24] /build/nat/nat.go#90: Renewing port mapping try #1 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:55:25] /build/nat/nat.go#90: Renewing port mapping try #2 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|02:55:26] /build/nat/nat.go#90: Renewing port mapping try #3 from external port 9651 to internal port 9651 failed with unknown protocol TCP
WARN [09-10|02:55:27] /build/nat/nat.go#120: Renew NAT Traversal failed from external port 9651 to internal port 9651 with unknown protocol TCP
ERROR[09-10|03:00:27] /build/nat/nat.go#90: Renewing port mapping try #1 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|03:00:28] /build/nat/nat.go#90: Renewing port mapping try #2 from external port 9651 to internal port 9651 failed with unknown protocol TCP
ERROR[09-10|03:00:29] /build/nat/nat.go#90: Renewing port mapping try #3 from external port 9651 to internal port 9651 failed with unknown protocol TCP
WARN [09-10|03:00:30] /build/nat/nat.go#120: Renew NAT Traversal failed from external port 9651 to internal port 9651 with unknown protocol TCP
1.5.2 log:
INFO [09-10|03:08:24] /build/nat/nat.go#74: NAT Traversal successful from external port 9651 to internal port 9651
Operating System Linux 3.10.105 x86_64 Intel Braswell CPU
By submitting this issue I agree to the Terms and Conditions of the Developer Accelerator Program.
The only change regarding NAT I can see is a single line removal of a nil assignment which doesn't seem relevant at all:
goupnp package doesn't seem to be updated.
However, the whole network code seems to have been overhauled, and golang.org/x/net dependency seems to have been upgraded. I don't know if those are related though.
This issue has been resolved on my setup by changing the NAT filtering setting from "Secured" to "Open" on my Netgear Orbi. Please note that 1.5.2 used to work with "Secured" setting without any issues.