How to set up dedicated server?

Problems and solutions for installing or running FreeOrion, including discussion of bugs if needed before posting a bug report on GitHub. For problems building from source, post in Compile.

Moderator: Oberlus

Post Reply
Message
Author
MarisaG
Space Krill
Posts: 2
Joined: Wed Jul 10, 2019 4:12 am
Location: South San Francisco, CA

How to set up dedicated server?

#1 Post by MarisaG »

I have the latest version from the PPA for ubuntu, and I can start freeoriond but it just sits there with no output and if I put the host name in the client and try and connect the screen goes black and then just sits there. Is there a freeoriond config file to set desired settings?

Thx!
Marisa
--- https://SynchronetBBS.org/OurServers - All the servers we support or host

o01eg
Programmer
Posts: 2004
Joined: Sat Dec 10, 2011 5:46 am

Re: How to set up dedicated server?

#2 Post by o01eg »

MarisaG wrote: Wed Jul 10, 2019 4:15 am I have the latest version from the PPA for ubuntu, and I can start freeoriond but it just sits there with no output and if I put the host name in the client and try and connect the screen goes black and then just sits there. Is there a freeoriond config file to set desired settings?

Thx!
Marisa
First thing for dedicated server is you need to provide --hostless argument to freeoriond executable.
Gentoo Linux x64, gcc-11.2, boost-1.78.0
Ubuntu Server 22.04 x64, gcc-12, boost-1.74.0
Welcome to the slow multiplayer game at freeorion-lt.dedyn.io.Version 2024-03-15.b3de094.
Donations're welcome:BTC:bc1q007qldm6eppqcukewtfkfcj0naut9njj7audnm

MarisaG
Space Krill
Posts: 2
Joined: Wed Jul 10, 2019 4:12 am
Location: South San Francisco, CA

Re: How to set up dedicated server?

#3 Post by MarisaG »

Done.. What next?
--- https://SynchronetBBS.org/OurServers - All the servers we support or host

o01eg
Programmer
Posts: 2004
Joined: Sat Dec 10, 2011 5:46 am

Re: How to set up dedicated server?

#4 Post by o01eg »

MarisaG wrote: Wed Jul 10, 2019 8:18 am Done.. What next?
Check it again. Do you get to multiplayer lobby? Next depends on what you want to play on the server.
Gentoo Linux x64, gcc-11.2, boost-1.78.0
Ubuntu Server 22.04 x64, gcc-12, boost-1.74.0
Welcome to the slow multiplayer game at freeorion-lt.dedyn.io.Version 2024-03-15.b3de094.
Donations're welcome:BTC:bc1q007qldm6eppqcukewtfkfcj0naut9njj7audnm

User avatar
swaq
Space Dragon
Posts: 384
Joined: Tue Aug 20, 2019 1:56 pm

Re: How to set up dedicated server?

#5 Post by swaq »

I am also experimenting with the multiplayer server. I ran 'freeoriond --hostless' and could connect to it with multiple client windows and start a game. But if one of the clients leaves it kicks the others out of the game too.

User avatar
alleryn
Space Dragon
Posts: 259
Joined: Sun Nov 19, 2017 6:32 pm

Re: How to set up dedicated server?

#6 Post by alleryn »

swaq wrote: Sun Oct 13, 2019 3:15 am I am also experimenting with the multiplayer server. I ran 'freeoriond --hostless' and could connect to it with multiple client windows and start a game. But if one of the clients leaves it kicks the others out of the game too.
I just tried to start a server process and haven't gotten it working, but while looking through the options i found one which looks possibly pertinent to your situation:

Code: Select all

freeoriond.exe --help network.server.unconn-human-empire-players
Options:
--network.server.unconn-human-empire-players.max
     Maximum number of players, who control non-eliminated empires, who may be
       unconnected from the server before it stops the game being played.
       Disabled if 0, meaning the server will never stop the game due to
       empire-playing players being unconnected.
     Default: 1
With a default of "1" and the current wording, this sounds like it would allow a max of 1 to be disconnected, but probably this is really a max of 0, since "0" corresponds to infinity.

EDIT: Confirmed, this addresses your issue. I ran a server with 'freeoriond --hostless' and found the same behavior that you described: Exiting ("resigning") the game with one client caused the other client to exit to the multiplayer lobby.

Then i ran a server with 'freeoriond --hostless --network.server.unconn-human-empire-players.max 0' and when i exited the game with one client, the other stayed in the game. /EDIT

o01eg
Programmer
Posts: 2004
Joined: Sat Dec 10, 2011 5:46 am

Re: How to set up dedicated server?

#7 Post by o01eg »

Yes, also there is a option network.server.conn-human-empire-players.min which declares lower bound of connected players. Setting it to 0 allows server to not stop the game if no one is connected.

You could also use https://github.com/o01eg/freeorion/blob ... config.xml and https://github.com/o01eg/freeorion/blob ... freeoriond as an example with used options.
Gentoo Linux x64, gcc-11.2, boost-1.78.0
Ubuntu Server 22.04 x64, gcc-12, boost-1.74.0
Welcome to the slow multiplayer game at freeorion-lt.dedyn.io.Version 2024-03-15.b3de094.
Donations're welcome:BTC:bc1q007qldm6eppqcukewtfkfcj0naut9njj7audnm

User avatar
swaq
Space Dragon
Posts: 384
Joined: Tue Aug 20, 2019 1:56 pm

Re: How to set up dedicated server?

#8 Post by swaq »

Thanks! I was able to get it working.

User avatar
LienRag
Cosmic Dragon
Posts: 2148
Joined: Fri May 17, 2019 5:03 pm

Re: How to set up dedicated server?

#9 Post by LienRag »

To have a server accessible only on a LAN, is there something specific to do ?

Ophiuchus
Programmer
Posts: 3433
Joined: Tue Sep 30, 2014 10:01 am
Location: Wall IV

Re: How to set up dedicated server?

#10 Post by Ophiuchus »

LienRag wrote: Mon Feb 21, 2022 6:31 am To have a server accessible only on a LAN, is there something specific to do ?
depends on your set-up (the ports must be reachable/allowed to talk), but else no.
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

Look, ma... four combat bouts!

User avatar
LienRag
Cosmic Dragon
Posts: 2148
Joined: Fri May 17, 2019 5:03 pm

Re: How to set up dedicated server?

#11 Post by LienRag »

OK, thanks.
Which ports need to be allowed ?
Is there some documentation somewhere ?

o01eg
Programmer
Posts: 2004
Joined: Sat Dec 10, 2011 5:46 am

Re: How to set up dedicated server?

#12 Post by o01eg »

LienRag wrote: Mon Feb 21, 2022 7:59 pm OK, thanks.
Which ports need to be allowed ?
Is there some documentation somewhere ?
https://freeorion.org/index.php/Multiplayer

It didn't changed much.
Gentoo Linux x64, gcc-11.2, boost-1.78.0
Ubuntu Server 22.04 x64, gcc-12, boost-1.74.0
Welcome to the slow multiplayer game at freeorion-lt.dedyn.io.Version 2024-03-15.b3de094.
Donations're welcome:BTC:bc1q007qldm6eppqcukewtfkfcj0naut9njj7audnm

Post Reply