Anvil Game Studios

Holdfast: Nations At War => Game Servers => Topic started by: Refleax on September 21, 2017, 07:26:01 pm

Title: Host Your Own Game Server! - Documentation
Post by: Refleax on September 21, 2017, 07:26:01 pm
(https://i.imgur.com/fUxGK53.jpg)



Documentation on how to host a server can be found below. It will be updated as we push updates towards the game.

View Documentation - Holdfast: NaW Server Documentation v2 (https://www.dropbox.com/s/yb02g69zc1q5ed0/Holdfast%20NaW%20Server%20Documentation%20v2.pdf?dl=0)




(http://www.holdfastgame.com/Content/imgs/Posts/8e94b7c7-a714-4a48-a0bc-e28daf684a84.png)

Server Tips



Your Server Is Experiencing Latency Issues
Take note of the following points if the server you are hosting is experiencing latency issues.

- Take note of the following:
1) Make sure that your CPU has a core speed of at least 3.6 GHz and that you’re not exceeding your bandwidth. You should also run your game server on a single physical and logical core.

2) Make sure that your server box's 'Power Options' are set to 'High Performance'. By default, this is set to 'Balanced'. Please change this!

3) Make sure that you have the latest Windows updates installed on your machine. This is very important.

4) Make sure that you follow the folder structure as defined in the documentation. Copy over the ‘holdfast_naw_public_servers’ folder over to your root drive then include the contents of the game from Steam in the ‘holdfast_naw_public_server’ folder.

5) Make sure that you properly allow the game ports from your firewall (outbound and inbound) on UDP.

6) Don’t rename the ‘Holdfast NaW.exe’ executable.

7) Don’t switch between Naval and Army based game modes.
Title: Re: Host Your Own Game Server! - Documentation
Post by: Gatts on September 22, 2017, 10:26:32 am
When I'm running batch file, it runs for 2 secs than shuts down, why this could be?
Title: Re: Host Your Own Game Server! - Documentation
Post by: Captain Conner on September 22, 2017, 11:19:13 am
When I'm running batch file, it runs for 2 secs than shuts down, why this could be?

Incorrect file paths.

If you can not figure it out, we host servers for less than 1.50 EUR /month all over the world. Check out http://www.oasis-hosting.net/gameservers/holdfastnaw
Title: Re: Host Your Own Game Server! - Documentation
Post by: Felix Buxton on September 22, 2017, 04:56:42 pm
When I'm running batch file, it runs for 2 secs than shuts down, why this could be?

Add me on steam if you're still having issues with this, I'll happily get it sorted for you. Be sure to check if you have the correct .NET Framework which is required, link for it can be found in the documentation under step 1, especially if you're using Windows Server 2008. If you're using 2012 then you shouldn't need to take this step as it's included with the OS.
From there if you have the server located somewhere other than 'C:/holdfast_naw_public_servers/' then you'll have to open each start .bat file with a text editor (Example: start_server1_armybattlefield_headless.bat) and edit the file path in the three areas it's included, I've written an example below you will just need to replace the '<FilePathHere>' with your directories path.

Example:
Code: [Select]
start "vapuriloadtester.exe" /affinity 3 "C:\<FilePathHere>\vapuriloadtester.exe" -s --serverConfigFilePath "serverconfig_server1_armybattlefield.txt" --outputLog "C:\<FilePathHere>\logs_output\outputlog_server1_armybattlefield.txt" --logArchivesDirectory "C:\<FilePathHere>\logs_archive" --framerate 60 --serverheadless

Complete Example:
Code: [Select]
start "vapuriloadtester.exe" /affinity 3 "C:\Users\Example\Holdfast\vapuriloadtester.exe" -s --serverConfigFilePath "serverconfig_server1_armybattlefield.txt" --outputLog "C:\Users\Example\Holdfast\logs_output\outputlog_server1_armybattlefield.txt" --logArchivesDirectory "C:\Users\Example\Holdfast\logs_archive" --framerate 60 --serverheadless

If the issue still persists add me or send me a PM and I'll happily help resolve the issue for you. And if anyone out there is using a Linux distribution and having issues you can also contact me if you want guidance on getting it running.
Title: Re: Host Your Own Game Server! - Documentation
Post by: Blackburn on September 22, 2017, 08:57:05 pm
When I'm running batch file, it runs for 2 secs than shuts down, why this could be?

I was copying the "Holdfast Nations At War" folder instead of its contents. Hope it helps.

Spoiler
[close]
Title: Re: Host Your Own Game Server! - Documentation
Post by: Hadrian on September 22, 2017, 09:34:58 pm
Cheers! Thanks for the detailed guide. Awesome that you guys obviously put a lot of effort into documentation as that'll certainly make sure it's picked up by the community faster.

Just a couple things from the guide I've noticed so far that you may want to consider putting in the guide:

I can write up instructions on how to use the SteamCMD to download/update the files if it'd be helpful.  And I can come up with a guide to install on linux as well if that's not currently being worked yet.
Title: Re: Host Your Own Game Server! - Documentation
Post by: Refleax on September 22, 2017, 11:19:39 pm
Cheers! Thanks for the detailed guide. Awesome that you guys obviously put a lot of effort into documentation as that'll certainly make sure it's picked up by the community faster.

Just a couple things from the guide I've noticed so far that you may want to consider putting in the guide:
  • When using SteamCMD to download the files, Holdfast's Steam AppID is 589290. Would probably be helpful for some users.
  • Secondly, there's a small typo in "Server Password" section, the example says "server_admin_password" instead of "server_password"

I can write up instructions on how to use the SteamCMD to download/update the files if it'd be helpful.  And I can come up with a guide to install on linux as well if that's not currently being worked yet.

I'll look into that, thanks!
Title: Re: Host Your Own Game Server! - Documentation
Post by: General Shepherd on September 26, 2017, 12:42:15 am
I think a professional server installation guide is required for videos
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on September 30, 2017, 02:41:32 am
Hey, guide is good, but I also got some comments:

Title: Re: Host Your Own Game Server! - Documentation
Post by: Captain Conner on September 30, 2017, 07:53:46 am
Hey, guide is good, but I also got some comments:

  • Obviously not at high priority for you guys, but could you please create a Linux server build? Wine is powerful, but really doesn't like 64bit .NET 4.5.2 exes
  • Another Linux comment: You are using a free version of dropbox (As of Oct 3, 2016, dl=1 no longer works for the Free tier users), which means you people can't directly download from it using curl or wget in terminals (bad for server admins and automatisation)
  • Paths in the .bat files are not relative
  • Any chance of getting the dedicated server as a separate appid? (So it's easier to maintain, also would get rid of needing to having to login with your Steamaccount)

Running Holdfast on Wine is not iffy at all. Feel free to read my guide on how to do it here: http://www.holdfastgame.com/forum/index.php?topic=2133.0
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on September 30, 2017, 09:28:58 am
Huh. Bookmarked, thanks. I did try and run it via wine but instead of going over mono, I tried it using winetricks dotnet452. Which resulted in holdfast complaining about a missing mscoree.dll even though it was in the same directory as the game (also present in the .wine/windows/system32). (Should have put 2and2 together and remember that Unity uses the Mono framework D:). Totally frustrated at 3am, made this post and wiped my Docker Container :p.

I'll use your instructions now. Still would be nice to get a Linux build though.

Title: Re: Host Your Own Game Server! - Documentation
Post by: Namelol on January 26, 2018, 09:50:07 pm
Are server is hoste by a company. We know how to use the server settings but we can't join server with the admin. Please help
Title: Re: Host Your Own Game Server! - Documentation
Post by: Jean-Baptiste on January 26, 2018, 10:42:49 pm
Are server is hoste by a company. We know how to use the server settings but we can't join server with the admin. Please help

You should probably contact your server host to resolve this issue! I'm not sure how to help without more information anyway.

edit: Just found you on the Discord, I'll try to help there :)
Title: Re: Host Your Own Game Server! - Documentation
Post by: Archeyopteryx on April 14, 2018, 09:32:44 pm
Everything is working except one thing. I cant join the server in the browser. Are there more ports like Steam that need to be opened on my router? I've opened the 20100 and 20101 ports on both my firewall (inbound and out) and my router. Is there another port I should be adding? Is there a reason I cant join?

Edit: Nvm, You need steams server ip, holdfast 20100 and 20101 all forwarded to you're the router.
Title: Re: Host Your Own Game Server! - Documentation
Post by: [VG] Le Royaliste on January 27, 2019, 07:32:34 pm
thanks for that !
Title: Re: Host Your Own Game Server! - Documentation
Post by: Aranos92 on May 27, 2019, 06:18:15 pm
It is possible to have the Server Files - Documentation updated version? Thanks in advance!
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on May 27, 2019, 06:19:39 pm
It is possible to have the Server Files - Documentation updated version? Thanks in advance!

What exactly are you looking for? We are currently working on migrating the .pdf to the new wiki:
https://wiki.holdfastgame.com/Server_Hosting
https://wiki.holdfastgame.com/Server_Configuration
Title: Re: Host Your Own Game Server! - Documentation
Post by: Aranos92 on May 27, 2019, 07:04:54 pm
Thanks for those links! Anyway i am trying to host a local server with the new Frigate's update, is there a template for that?
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on May 27, 2019, 07:07:49 pm
Thanks for those links! Anyway i am trying to host a local server with the new Frigate's update, is there a template for that?

Not really. However you can build your own ship presets now.
Check this:

https://wiki.holdfastgame.com/Server_Configuration#Ship_Spawning_.26_Custom_Ship_Presets

Title: Re: Host Your Own Game Server! - Documentation
Post by: TacticalDiplomacy on June 06, 2019, 01:09:24 am
I'm assuming an i7-4770K @ 4/4.4GHz could run as a holdfast server? Even if it is a little old?
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on June 07, 2019, 01:27:49 pm
I'm assuming an i7-4770K @ 4/4.4GHz could run as a holdfast server? Even if it is a little old?

Yes. That one is still quiet good, especially since you can overclock it.
Title: Re: Host Your Own Game Server! - Documentation
Post by: 如月红 on June 18, 2019, 12:51:12 pm
hi, I try it and my serve can be discovered in lobby successfully. But when you try joining it,you will find ERROR 14 on it and fail.
How to solve it,please :-[
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on June 18, 2019, 05:50:05 pm
hi, I try it and my serve can be discovered in lobby successfully. But when you try joining it,you will find ERROR 14 on it and fail.
How to solve it,please :-[

Can you show me your config?
Make sure to open the ports on your firewall.
Title: Re: Host Your Own Game Server! - Documentation
Post by: 如月红 on June 19, 2019, 05:16:46 am
hi, I try it and my serve can be discovered in lobby successfully. But when you try joining it,you will find ERROR 14 on it and fail.
How to solve it,please :-[

Can you show me your config?
Make sure to open the ports on your firewall.

Thanks,i5 9400f and rx580,
The vapuriloadtester show that
Code: [Select]
Number of clients to open: 0
Open interval (seconds): 1
Bot Clients? False
Headless clients? False
Carbon Players: (Server) 0

Opening server
When the bat works,the HF NAW.exe starts in black forever
Thanks again
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on June 19, 2019, 12:16:55 pm

Thanks,i5 9400f and rx580,
The vapuriloadtester show that
Code: [Select]
Number of clients to open: 0
Open interval (seconds): 1
Bot Clients? False
Headless clients? False
Carbon Players: (Server) 0

Opening server
When the bat works,the HF NAW.exe starts in black forever
Thanks again

I meant I needed the .bat content and the server config (.txt) file.
Title: Re: Host Your Own Game Server! - Documentation
Post by: 如月红 on June 19, 2019, 02:27:08 pm

Thanks,i5 9400f and rx580,
The vapuriloadtester show that
Code: [Select]
Number of clients to open: 0
Open interval (seconds): 1
Bot Clients? False
Headless clients? False
Carbon Players: (Server) 0

Opening server
When the bat works,the HF NAW.exe starts in black forever
Thanks again

I meant I needed the .bat content and the server config (.txt) file.

sorry,.bat =
Code: [Select]
start "vapuriloadtester.exe" /affinity 3 "C:\holdfast_naw_public_servers\vapuriloadtester.exe" -s --serverConfigFilePath "serverconfig_newserver7_meleearena.txt" --outputLog "C:\holdfast_naw_public_servers\logs_output\outputlog_newserver7_meleearena.txt" --adminCommandLogFilePath "C:\holdfast_naw_public_servers\logs_adminactions\adminactions_newserver7_meleearena.txt" --logArchivesDirectory "C:\holdfast_naw_public_servers\logs_archive"
and config =
Code: [Select]
server_port 20244
steam_communications_port 8857
steam_query_port 27244


server_name JOJO CHU
server_welcome_message Welcome
server_region china
server_admin_password abeitalekia
server_password abeitaleki

network_broadcast_mode HighAccuracy


thanks again
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on June 19, 2019, 02:31:37 pm
sorry,
No worries ;).

.bat =
Code: [Select]
start "vapuriloadtester.exe" /affinity 3 "C:\holdfast_naw_public_servers\vapuriloadtester.exe" -s --serverConfigFilePath "serverconfig_newserver7_meleearena.txt" --outputLog "C:\holdfast_naw_public_servers\logs_output\outputlog_newserver7_meleearena.txt" --adminCommandLogFilePath "C:\holdfast_naw_public_servers\logs_adminactions\adminactions_newserver7_meleearena.txt" --logArchivesDirectory "C:\holdfast_naw_public_servers\logs_archive"

Add "--serverheadless" to the end, that will make the empty black window disappear.

and config =
Code: [Select]
server_port 20244
steam_communications_port 8857
steam_query_port 27244


server_name JOJO CHU
server_welcome_message Welcome
server_region china
server_admin_password abeitalekia
server_password abeitaleki

network_broadcast_mode HighAccuracy


thanks again

Open port 20244, 8857 and 27244 on your firewall (TCP&UDP). If you are hosting this on your home pc make sure to also setup port forwarding from your router to your machine with these ports as well.
Title: Re: Host Your Own Game Server! - Documentation
Post by: Hadrian on June 20, 2019, 05:23:33 pm
Quick question that's been bothering me for some time --

Why on earth would you guys make it so that all the game servers for this game contact the lobby server at a hardcoded IP address? CNAME or subdomain (i.e. lobby.holdfastgame.com) would be much safer if you ever need migrate off of Hetzner's network or are forced to change IP's/servers for some reason down the road. You'd be able to update the DNS of that subdomain much easier than having EVERY server owner update their config to point to a new IP address in order to have their server listed.

Quote
Note: "94.130.66.231" - is the holdfast lobby server IP (masterserver).
Title: Re: Host Your Own Game Server! - Documentation
Post by: Walki on June 20, 2019, 05:36:58 pm
Why on earth would you guys make it so that all the game servers for this game contact the lobby server at a hardcoded IP address? CNAME or subdomain (i.e. lobby.holdfastgame.com) would be much safer if you ever need migrate off of Hetzner's network or are forced to change IP's/servers for some reason down the road. You'd be able to update the DNS of that subdomain much easier than having EVERY server owner update their config to point to a new IP address in order to have their server listed.

Quote
Note: "94.130.66.231" - is the holdfast lobby server IP (masterserver).

I wasn't the one who made the decision (I wasn't part of the team back then). However, I do know that it will in fact default to a FQDN (anvilstudios.eu) if the IP should ever become unreachable/reject the connection.
Title: Re: Host Your Own Game Server! - Documentation
Post by: Hadrian on June 20, 2019, 05:42:15 pm
I wasn't the one who made the decision (I wasn't part of the team back then). However, I do know that it will in fact default to a FQDN (anvilstudios.eu) if the IP should ever become unreachable/reject the connection.

Ohh okay. Wasn't aware of the fallback, so that's good so you guys can set up a temporary lobby service on that server or proxy it elsewhere if necessary. Likely won't be a major issue, just had me puzzled when I first encountered that since it didn't appear to be fault tolerant at all. Thanks for the quick response!
Title: Re: Host Your Own Game Server! - Documentation
Post by: 如月红 on August 31, 2019, 03:35:00 pm
hi, I try it and my serve can be discovered in lobby successfully. But when you try joining it,you will find ERROR 14 on it and fail.
How to solve it,please :-[

Can you show me your config?
Make sure to open the ports on your firewall.
Thanks a lot,But what remote port and local port,ip  are set for routers