Master server - LunaMultiplayer/LunaMultiplayer GitHub Wiki

A master server is NOT a LMP game server!

If you want to host a server to play on, this is not what you are looking for.

LMP uses a system called "NAT punchthrough" in order to connect clients and servers. This system allows people to host LMP games and become a server without having to open specific ports in their routers.

Basically the standard LMP servers announce themselves to a master server at a minimum interval of 5 seconds and clients ask that master server what LMP servers are available.

Once a client chooses an LMP server, the master server introduces each other so they can connect through NAT and firewalls. After the introduction the master server no longer interacts with the client<->server connection and data flows directly between client and the LMP server.

Master servers need to have an open port (default is 8700 UDP) as otherwise it would not be possible to query or register servers with it.

This file in the repo hold a list of all the master servers currently available.
It would be nice to have at least 3 servers as it will allow full-time support in case a master server is down, but to do that we need people that can have a computer/server/Raspberry PI turned on 24h, a stable internet connection and a static IP address or working DynDNS. If you are willing to contribute as a master server please let us know either by opening an issue or a pull request which adds your server to the above mentioned list (using a raw IPv4 address or a domain that resolves correctly).

If you are not listed in that file your master server will not be seen and will have no use!

Also, a master server can respond to HTTP requests on a given TCP port (default is 8701 TCP) and return a list of registered servers as an HTML page. There is also an endpoint to receive the list as JSON at /json.

By default the Master server will try to open both UDP and TCP ports using UPnP but if your router does not support it you will have to open them manually.

Bear in mind that master servers are version dependent, so only clients and servers on the same version will work. Therefore if you want to run a master server and keep it updated with the latest nightly version use the parameter /nightly. Otherwise the master server should update automatically once a new GitHub release is available and run the latest stable version.