Hello all I have issues with running the
# client
d
Hello all. I have issues with running the Netmaker server (in a container) and a client node (on host OS) on the same machine. They don't seem to be able to ping each other, but according to documentation at the 2nd paragraph of https://docs.netmaker.org/troubleshoot.html#server it should be possible.
Some details about what I've been doing: 1. Installed Netmaker following the public documentation. I used Docker Compose method and deployed it on a VPS. 2. Created a new network called 'testnet1' with the IP range of 10.20.30.0/24. The server got assigned the IP of 10.20.30.254. 3. Ran
sudo netclient join -t <mytoken> --port 51840
on the same VPS. Got a new node with the IP of 10.20.30.1. Now I have two nodes deployed on the same host. 4. Ran
sudo netclient join -t <mytoken>
on another server (sits within my LAN). Got one more node with the IP of 10.20.30.2. 5. Now, trying to validate connectivity in the mesh with pings in all possible directions. Here's what I am getting: * From 10.20.30.1: * ping to 10.20.30.2 succeeds * ping to 10.20.30.254 fails with
ping: sendmsg: Required key not available
message * From 10.20.30.2: * pings to both 10.20.30.1 and 10.20.30.254 succeed * From 10.20.30.254: * ping to 10.20.30.1 fails with
ping: sendto: Destination address required
message * ping to 10.20.30.2 succeeds So, 10.20.30.1 and 10.20.30.254 cannot ping each other. Ports 51821-51830 and 51840 are both open in the iptables and VPS web console.
I tried running
sudo wg showconf nm-testnet1
on all nodes and here is what I am seeing (public IPs and private keys redacted): On 10.20.30.1:
Copy code
[Interface]
ListenPort = 51840
PrivateKey = <redacted>

[Peer]
PublicKey = I9zImybbBw9TyHQy92ePYMwoYNPtstFbI1xKICMG0iI=
AllowedIPs = 10.20.30.2/32
Endpoint = XXX.YYY.ZZZ.74:54206
PersistentKeepalive = 20
On 10.20.30.2:
Copy code
[Interface]
ListenPort = 54206
PrivateKey = <redacted>

[Peer]
PublicKey = 0wuGST3vFYBR9z4xTCIf4q2xmLJDU5Ee1WboEQ0dx3U=
AllowedIPs = 10.20.30.254/32
Endpoint = AAA.BBB.CCC.208:51821
PersistentKeepalive = 20

[Peer]
PublicKey = QQiiv2TtBvRv6vvv8yLzl3oJJVnIqrQwm9+umptYJzE=
AllowedIPs = 10.20.30.1/32
Endpoint = AAA.BBB.CCC.208:51840
PersistentKeepalive = 20
On 10.20.30.254:
Copy code
[Interface]
ListenPort = 51821
PrivateKey = <redacted>

[Peer]
PublicKey = I9zImybbBw9TyHQy92ePYMwoYNPtstFbI1xKICMG0iI=
AllowedIPs = 10.20.30.2/32
Endpoint = XXX.YYY.ZZZ.74:54206
PersistentKeepalive = 20

[Peer]
PublicKey = QQiiv2TtBvRv6vvv8yLzl3oJJVnIqrQwm9+umptYJzE=
AllowedIPs = 10.20.30.1/32
PersistentKeepalive = 20
What looks wrong to me is that config on 10.20.30.1 does not have a peer entry for 10.20.30.254. Also, config on 10.20.30.254 has the peer entry for 10.20.30.1, but it is missing the Endpoint attribute. All the problematic observations are limited to the nodes deployed on the VPS. The client node on the server inside my LAN looks perfectly correct. Wondering if I misconfigured something somewhere. Any help appreciated.
b
At first glance, I think you did everything correctly.
can you run a
netclient pull
on node with ip 10.20.30.1
What looks wrong to me is that config on 10.20.30.1 does not have a peer entry for 10.20.30.254. Also, config on 10.20.30.254 has the peer entry for 10.20.30.1, but it is missing the Endpoint attribute.
the pull should cure the problem on 10.20.30.1...... the reason why 10.20.30.254 does not have an endpoint for x.x.x.1 is because x.x.x.1 has to initiate comms with the server before the endpoint is populated (but x.x.x.1 cannot initiate comms as it does not have the server node as a peer ----- a pull command (or waiting 5 minutes for a periodic peer update) should fix everything
d
Yeah, I tried doing pulls a few times, and it didn't change anything, same errors.
b
have you tried leaving and then rejoining the network on the 10.20.30.1 node?
btw, what version (netmaker/netclient)are you using?
d
Yup like 10 times 😂
0.16.2 for netmaker and 0.16.1 for netclient
b
can you update the client to match the server (tho 0.16.1 client and 0.16.2 server should work)
please raise an issue on github .... the steps you did should work
d
I am on Debian and have been following this procedure to install netclient https://docs.netmaker.org/netclient.html#debian-distros-debian-ubuntu-mint-pop-os and it only gives me 0.16.1. Is there another way to get 0.16.2?
Yup sounds good will file on github
b
as 0.16.2 has not been formally released (still a pre-release) the apt packages have not been updated yet. you can get the 0.16.2 binary from the release page
wget https://github.com/gravitl/netmaker/releases/download/v0.16.2/netclient -O /tmp/netclient
sudo chmod +x /tmp/netclient
sudo /tmp/netclient install -vvvv
d
Ok, installed 0.16.2, but still seeing the same errors
Will go ahead with a github issue then
b
thank-you .. should have a fix soon
FYI ,, found source of issue --- now I just need to figure out a way to fix it without breaking something else
w
no handshake
b
what version are you running?