mschnitzer / ark-survival-ascended-linux-container-image

A docker/podman container that is able to run an ARK: Survival Ascended on a Linux host.
70 stars 13 forks source link

How to add a second server and configure it as a cluster #54

Closed heusmich closed 3 months ago

heusmich commented 4 months ago

Hi,

I noticed that the second map "Scorched Earth" for ASA shall be released beginning of March. I want to setup a second server with this map and configure it as a cluster, so that a transfer and a travel from the current map "The Island" to "Scorched Earth" and vice versa will be possible.

I read your documentation and in the part "Setting up a second server" (https://github.com/mschnitzer/ark-survival-ascended-linux-container-image?tab=readme-ov-file#setting-up-a-second-server) you described what has to be done.

Just to be sure that I understood it correctly, in the file "docker-compose.yml" for the entry of the second server I only have to change the container name from "asa-server-1" to "asa-server-2", the ports for the new server to the ports I want, the volumes from "steam-1" to "steam-2", "steamcmd-1" to "steamcmd-2" and "server-files-1" to "server-files-2". And I also have to change the map name in the start params in part "environment" from "- ASA_START_PARAMS=TheIsland_WP?" to "- ASA_START_PARAMS=XXX?" and XXX will be the name of the new map.

Is that correct?

And regarding the cluster, does the transfer and the travel from one server to another server work immediately as soon as the new server is up or do I have to do some additional changes?

Best regards heusmich

mschnitzer commented 4 months ago

Hi,

the documentation for a second server was written when clusters were still an afterthought and were not supported at that time. This is purely referring to a second independent server.

However, I merged a proposal by someone who worked on cluster support just recently in #51

Have a look at the changed files of #51 and what @PoweredByte suggested as changes: https://github.com/mschnitzer/ark-survival-ascended-linux-container-image/pull/51/files

Please keep in mind to set on both servers then the -ClusterOverrideDir and -clusterid option on the command line once you did the other changes to the docker-compose.yml file.

I didn't test it myself, but I got confirmation on Steam forums.

heusmich commented 4 months ago

OK, thanks for the info. I will try it as soon as the new map is available and then give a short response if it works or not.

mschnitzer commented 4 months ago

You can already test it with two The Island servers.

heusmich commented 4 months ago

Yes, you are right. I can do this.

If it works, do you know how I then can replace the second "The Island" server with "Scorched Earth" when it will be released?

I have to change the map name in the start params but do I also have to delete some files? Maybe delete the folder "_data" in folder "/var/lib/docker/volumes/asa-server_server-files-2", then run the command "docker-compose up -d" again and then the server files for "Scorched Earth will be downloaded and installed?

aircode commented 3 months ago

I have to change the map name in the start params but do I also have to delete some files? Maybe delete the folder "_data" in folder "/var/lib/docker/volumes/asa-server_server-files-2", then run the command "docker-compose up -d" again and then the server files for "Scorched Earth will be downloaded and installed?

Change the map name, in your docker-compose.yml - ASA_START_PARAMS=TheIsland_WP? to (eg.) - ASA_START_PARAMS=Svartalfheim_WP?

and install the mod MAP of your desire (eg. Swartalfheim) -mods=942355

(you dont need to delete the "_data" / just for a complete fresh install

heusmich commented 3 months ago

Hi both,

Thanks for your help so far. For me the cluster is working now, yesterday I successfully added a second "The Island" server and it was working as a cluster. I could upload and download items and dinos and could travel from one server to the other one and vice versa.

At first I made a little mistake with the cluster folder and then when I tried to travel I lost my char, but then I made a change in the "docker-compose.yml" file and since then everything is working without any problems.

Today or tomorrow I will try to replace the the map name with another one and then check if this also works, if yes, everything will be fine... :D

heusmich commented 3 months ago

Hi again,

Sorry it took a little bit longer but now I had a chance to replace the second map with another one and it worked without any problems. So thank you both for your help!

mschnitzer commented 3 months ago

Hi, thanks for confirming it works!