In this tutorial, I’ll be explaining how to set up a 7 Days to Die server on CentOS 7.
You need to own this game on your Steam account.
Let’s make sure the system is fully updated before we start. Then we’ll be creating a new user for the server. Make sure to use a tough password.
yum update
yum upgrade -y
adduser 7d2d
passwd 7d2dLet us also open the necessary firewall ports.
firewall-cmd --zone=public --add-port=26900/tcp --permanent
firewall-cmd --zone=public --add-port=26900/udp --permanent
firewall-cmd --reloadInstall the required libs to run SteamCMD.
yum install glibc.i686 libstdc++.i686 -yNow, let’s switch to the user that we have just created.
su 7d2d
cd ~Time to download SteamCMD.
wget https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
tar xf steamcmd_linux.tar.gzNow we have to run SteamCMD and install the server files. Please note that if you have Steam Guard enabled, you have to check your email for the code to log in.
./steamcmd.sh
login YourAccount
*enter your password and steam guard code if necessary*force_install_dir ./7d2d
app_update 294420 validateThe server software is now installed.
Want to customize the name, description, and perhaps the slots of the server?
To change the name of your server, edit the file serverconfig.xml.
nano serverconfig.xmlOnly change the value inside the value="" part.
On line 5, change My Game Host to whatever you want.
On line 7, change 8 to the number of slots you want. Max slots are 32.
On line 8, change A 7 Days to Die server to the description of your choice.
Need to update due to Steam Updates? Don’t worry! With this simple script, you can update your server with just one command.
Let’s create the file update_7d2d.txt first.
nano /home/7d2d/update_7d2d.txtThen, paste the following:
login YourUser YourPassword
force_install_dir ./7d2d
app_update 294420
quitAnd now to update your server, all you have to do is run the following command:
cd ~
./steamcmd.sh +runscript update_7d2d.txtNavigate to the following folder and run your server.
cd /home/7d2d/7d2d/
screen -dmS 7d2d ./startserver.sh -configfile=serverconfig.xmlThe server is now running in the background. To shut down the server, run the following command:
pkill 7DaysEnjoy your new 7D2D server!