Page 1 of 1

Running Multiple Servers from one DNS

Posted: Sat 07.05.2016, 20:19
by TheHairyOne
How do I run multiple servers from one IP address?

I am assuming I probably have to go into my router and assign subdomains to the machines that will be playing host.
Something like: mangband.theinn.publicvm.com and pwmangband.theinn.publicvm.com

Never done this before...any help is appreciated.

Re: Running Multiple Servers from one DNS

Posted: Mon 09.05.2016, 01:53
by TheHairyOne
Maybe I am approaching this from the wrong perspective. How are ports handled between the server and the client. I have both of my servers set to different ports in the mangband.cfg file and I have my router set up to forward packets for the right ports to the right machines. Yet when clients connect, they always connect to the machine that is using the default port. How do the clients determine what port to communicate on?

Re: Running Multiple Servers from one DNS

Posted: Sun 22.05.2016, 13:26
by PowerWyrm
Isn't the port hardcoded? Something like 8602 in netserver.c?

Re: Running Multiple Servers from one DNS

Posted: Mon 27.04.2020, 17:05
by Flambard
TheHairyOne wrote:
Mon 09.05.2016, 01:53
Maybe I am approaching this from the wrong perspective. How are ports handled between the server and the client. I have both of my servers set to different ports in the mangband.cfg file and I have my router set up to forward packets for the right ports to the right machines. Yet when clients connect, they always connect to the machine that is using the default port. How do the clients determine what port to communicate on?
A bit late to the party, but probably still worth answering.

It works pretty much like any other networking software: the port is specified server-side via the TCP_PORT mangband.cfg option.

On client side, port can be provided during manual server address entry ("HOST:PORT") or via command line (./mangclient HOST PORT).

Naturally, port number is supplied by the meta-server, when client asks for a list of available servers. And when servers report to meta, they tell what port they use. It's not reflected on, say, "Online Servers" list on our webpage, but it's there.

Re: Running Multiple Servers from one DNS

Posted: Fri 30.10.2020, 18:30
by MiGFulcrum
Well, I'm glad you answered late, because as an even later newcomer, this is what the info I was looking for, my servers are now online and working. Thanks!