Skip to content
This repository has been archived by the owner on Oct 28, 2023. It is now read-only.

Different ports #3

Closed
catzoo opened this issue May 26, 2020 · 5 comments
Closed

Different ports #3

catzoo opened this issue May 26, 2020 · 5 comments

Comments

@catzoo
Copy link
Contributor

catzoo commented May 26, 2020

Image Setup Details

  • Image Tag: latest
  • Docker Host OS: Ubuntu Server 18.04.2
  • docker run command or docker-compose.yml file:

Current:

sudo docker run -d --name ark_server \
-p 27015:27015 \
-p 7777:7778 \
-p 7778:7779 \
-p 27020:32330 \
-v ark:/ark \
-v steam:/home/steam/steam \
-e am_serverMap=Valguero_P \
-e am_ark_SessionName="ButterNuggetz server" \
-e am_ark_MaxPlayers=8 \
-e am_ark_ServerAdminPassword=password\
-e am_ark_ServerPassword=password\
-e am_discordWebhookURL=https://discordapp.com/api/webhooks/712947228037218344/rJLTLT-5rl54B4BFldYMKSlqzqbBz6MMqJXp9kUIllK_vgM6vEFq4JwlAOaAp30V-csL \
-e am_ark_GameModIds=760199681,749172455,749172455,736236773,874109084,725398419,847495728,754885087,926028694,722649005,922859221,943290066,702828089,679529026,558651608,821530042,756389708,854186603,731604991,880871931,793605978,538827119,708807240,1139775728,1091147617,1400323349,2041551342,2043866694,2024119790 \
thmhoag/arkserver

Before:

sudo docker run -d --name ark_server \
--network=host \
-v ark:/ark \
-v steam:/home/steam/steam \
-e am_serverMap=Valguero_P \
-e am_ark_SessionName="ButterNuggetz server" \
-e am_ark_MaxPlayers=8 \
-e am_ark_QueryPort=27015 \
-e am_ark_Port=7777 \
-e am_ark_RCONPort=27020 \
-e am_ark_ServerAdminPassword=abc123 \
-e am_ark_ServerPassword=abc123 \ 
-e am_discordWebhookURL=https://discordapp.com/api/webhooks/712947228037218344/rJLTLT-5rl54B4BFldYMKSlqzqbBz6MMqJXp9kUIllK_vgM6vEFq4JwlAOaAp30V-csL \
-e am_ark_GameModIds=760199681,749172455,749172455,736236773,874109084,725398419,847495728,754885087,926028694,722649005,922859221,943290066,702828089,679529026,558651608,821530042,756389708,854186603,731604991,880871931,793605978,538827119,708807240,1139775728,1091147617,1400323349,2041551342,2043866694,2024119790 \
thmhoag/arkserver

Description of Issue

I'm not sure if i'm using it wrong. For some reason the ports keep changing on me. For example, before I set ark_Port=7777 and the server starts up with it being set to 7778.

I tried to solve the issue by exposing the ports with a different port on the host system. (Current docker run command) But the server started it up with port 7777 rather 7778.

I checked the configuration file in /ark/config/arkmanager.cfg and the enviromental variables are correct in there. Just for some reason when the server starts the arguments are different.

Additional Information

Run logs of the current docker run command:

2020-05-26 02:53:31: Running /ark/server/ShooterGame/Binaries/Linux/ShooterGameServer Valguero_P\?RCONPort=32330\?SessionName=ButterNuggetz\ server\?GameModIds=760199681\,749172455\,749172455\,736236773\,874109084\,725398419\,847495728\,754885087\,926028694\,722649005\,922859221\,943290066\,702828089\,679529026\,558651608\,821530042\,756389708\,854186603\,731604991\,880871931\,793605978\,538827119\,708807240\,1139775728\,1091147617\,1400323349\,2041551342\,2043866694\,2024119790\?MaxPlayers=8\?QueryPort=27015\?ServerPassword=abc123\?ServerAdminPassword=abc123\?Port=7777\?RCONEnabled=True\?listen -log
@thmhoag
Copy link
Owner

thmhoag commented May 26, 2020

Hey @catzoo. By default the dedicated server will open up two ports, both the one you specify and then another for RawSockets, typically the one you specified +1. So in your case, it would be opening the following:

7777 - the one you specified
7778 - the RawSocket port.

More information on the RawSockets stuff can be found here: https://ark.gamepedia.com/Dedicated_Server_Setup

As far as fixing the issue, I'd recommend just opening both ports on the container. So your docker run command would end up looking something like this:

sudo docker run -d --name ark_server \
-p 27015:27015 \
-p 7777:7777 \
-p 7778:7778 \
-p 32330 :32330 \
-v ark:/ark \
-v steam:/home/steam/steam \
-e am_serverMap=Valguero_P \
-e am_ark_SessionName="ButterNuggetz server" \
-e am_ark_MaxPlayers=8 \
-e am_ark_ServerAdminPassword=password\
-e am_ark_ServerPassword=password\
-e am_ark_QueryPort=27015 \
-e am_ark_Port=7777 \
-e am_ark_RCONPort=32330 \
thmhoag/arkserver

@catzoo
Copy link
Contributor Author

catzoo commented May 26, 2020

Thank you for responding.

Sorry, I should've put more info in my issue. When I set am_ark_port=7777 for some reason in the run arguments it has ?Port=7778. I also tried it using the default environment port 7778 and the run arguments go in reverse and have ?Port=7777. I mean when I looked at the logs and when it runs the ark server with those arguments.

Or is that normal since it opens both 7777 and 7778?

I will modify my run command to the one you gave me and try it again.

Thanks!

@catzoo
Copy link
Contributor Author

catzoo commented May 26, 2020

There might've not been an issue. I run the ark_server and i'm still seeing the ?Port argument different, this time it was set to ?Port=7776.

But I successfully joined the ark server.

Sorry about that and thanks for your help.

@catzoo catzoo closed this as completed May 26, 2020
@thmhoag
Copy link
Owner

thmhoag commented May 26, 2020

No problem @catzoo, glad you were able to get it figured out.

@catzoo
Copy link
Contributor Author

catzoo commented May 26, 2020

oh sorry to comment on a closed issue. I found more information and a solution to the problem I was having.

If anyone is having this issue, it decrease the port by one. So if you're trying to set the port to 7777-7778, set Port to 7778.

More information here: arkmanager/ark-server-tools#887

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants