Open mesmariusz opened 1 year ago
At a guess, there is no DNS resolution for the agent to contact the server.
If I'm logged in to the meshcentral server (192.168.56.111 located on LAN_A) from the same machine where the agent should be installed, using (192.168.7.100 located in LAN_B) using a webbrowser and IP address 192.168.56.111 to connect the meshcentral webpanel, and then I downloaded apropriate agent (from meshcentral to this remote host), and then I install it, I unfortunately can't see the agent visible in a meshcentral.
If I'm able to connect from this host (192.168.7.100) using the meshcentral webpanel IP address 192.168.56.111 in the browser on this host, what more should I do to make it possible make for this agent to be able to connect to meshcentral? Is this neccesary and possible to define for this agent the IP of meshcentral (192.168.56.111) ? If yes, where are stored the agent config files ?
Does your VPN restrict which ports are used?
If you go to one of the computers where your MeshAgent is installed and browse to the installation folder (the location of which will be dependent on if you've customized the agent or not- but should be something like C:\Program Files\MeshAgentName\Mesh Agent) and open the MeshAgent.msh file with a text editor like Notepad what are you seeing for the "MeshServer=wss://" line?
That line will tell you what the server name (or IP address) is of the Mesh Central server they are trying to connect to as well as which port. If it's using a FQDN instead of IP address make sure you can resolve that FQDN from that device.
The line I see on that host (192.168.7.100) is:
MeshServer=local
But why ? Should be 192.168.56.111...
You can modify that file manually
The reason that it is incorrect is that MeshCentral server doesn't know about the VPN and the VPN addresses This could be set in the config.json with a new 'domain' or you can simply modify the agent config as you go
The line I see on that host (192.168.7.100) is:
MeshServer=local
But why ? Should be 192.168.56.111...
Your config.json file Probably not necessary.
Ironically, this would have given it away instantly. Your mesh server is running in LAN only mode. In this mode, the agents use broadcasts on the local network to locate the mesh server. Obviously, the broadcast domains are separate on different subnets.
Set the following key in your config.json, under "settings".
"WANonly": true,
Remove LANonly if it is present.
You will need to redeploy agents or update their .msh files to point to the mesh server.
Describe the bug Agent installed on a network B behind VPN cant be seen in Meshcentral located in a netwerk A
To Reproduce
Expected behavior Agent should be visible @ meshcentral server automatically and immediately after agent on remote machine installation
Server Software (please complete the following information):
Client Device (please complete the following information):
Remote Device (please complete the following information):
Additional context No other context.
Your config.json file Probably not necessary.