Has anyone tried using netclient with multiple Wan...
# netmaker
h
Has anyone tried using netclient with multiple Wan routers? I am not sure whether it is caused by symmetric NAT or multiple Wan routers, because I encounter a network environment, that is, symmetric NAT, and multiple public IP, and the public IP is constantly changing randomly. I guess it is because of this reason. I don't understand the workflow of netclient and the impact of changing public IP on it.
b
netclient checks periodically (every minute) to see if its public ip has changed. If it has, it sends a message to the server which will in turn send a message to all the peers of the node informing them of the new endpoint for the node.
h
Whether the detected public ip: port is inconsistent with the ip: port used by WG. For example, when detecting the ip: port, it may go out through another line. This is a question.
j
Change the endpoint to static in the ui and select an ip
What kind of router btw
h
The symmetric router at the upper end is controlled by the operator, and we have no right to change it. The IP is dynamically and randomly changing and set to static. I don't think it can be solved well.
It is not up to us to decide which IP (line) will send the detection and WG
I am considering whether the secondary router can restrict the exit through UPnP
After a few seconds, the detected public IP address will change. Do you notice?
How to make detection and WG the only channel?
The front-end router may be a multi WAN router composed of multiple PPPoE.
j
Is the client on the router or behind the router?
and you're saying that you made the public IP static in the UI, but it continued to be dynamic anyway?
h
Detecting the ip: port of WG should be completed from the server, not the client, so as to maintain consistency.
j
we used to detect ip from the server but this caused issues, because sometimes the docker/k8s routing gets in the way, and netmaker sees the bridge interface instead of the public ip
so it would send back addresses that are in the private space like 172.*
h
The client is behind the router
Unfortunately, I cannot test the WG SD mode. This is detected from the server side
j
can you confirm this?
h
I will test this as soon as possible,
The other side's network doesn't cooperate with my test because it is a third-party network environment.
It's someone else's network. They have no obligation,
j
you don't have to do anything client-side, you do it from the UI.
first switch off "Dynamic Endpoint" and click submit, then enter one of the endpoints under "Endpoint" and click submit. It should keep that endpoint without changing constantly
h
I understand. I will try to get the test again
In my opinion, the IP address of WG communication may also change. If it is set to static, it will be affected.
j
I'm not sure how we'd be able to do both. Either the endpoint is detected dynamically and it can change, or you tell it to keep the IP
h
This is why I mentioned WG SD repeatedly. Its working principle can give us inspiration
j
I agree with this in principle, we looked into integrating wgsd for a while, but not sure if we're willing to do such a big refactor of hole punching at the moment
h
Maybe we have a better method than wg-sd to report to the server. The current WG accurate ip:port
I have tested that the double-layer router has no impact on netmaker and IP changes. But the dynamic random IP of multi Wan will be a challenge
j
This would be ideal and is how it used to work. However, we found a pretty bad flaw with this design. Typically, the WG interface on the server will have the correct ip:port on initial startup. However, if anything wipes the interface (restart, change to server node), then the ip of ip:port becomes inaccurate. Let's say you have 1 client on the server at 1.2.3.4. When it first checks in with server, it will show in peers list as: endpoint: 1.2.3.4:12345 then, something happens to server such as a docker restart. When it comes back up, we see the peer changes to this: endpoint: 172.168.1.25:12345 where 172.168.1.25 is the docker gateway address. Then, this IP gets sent out to the clients, and the become unreachable.
we have not found a good way to solve this issue, so have avoided using the IP from the server and instead only send the port
h
I hope this problem can be solved as soon as possible. It is very important to drill holes in the underlying UDP. Relaying is not a good way
d
I have a somewhat similar setup. My provider gives me different IPs based on the destination. So in the code you have a few endpoints to get public ip (like ifconfig.me, etc) and they return different values. It doesn't impact me much so far as most my nodes have static public IPs, but it would be great to see a solution, sure
j
We'll need to have a broader discussion on this since it would be a big change. It's doable, but will have consequences. I'm open to suggestions if we want to cntinue this in the architecture channel
3 Views