In this guide, you will learn how to setup your own\u00a0“7 Days to Die”<\/strong>\u00a0server (7D2D) on Ubuntu. Please note that this game is still\u00a0“early access”<\/strong>\u00a0and that the installation steps may change without notice as updates are released.<\/p>\n Ensure that you are logged in as the root user. 64-bit Ubuntu users need to install the 32-bit libraries.<\/p>\n 7D2D has very little output to the console. The option is up to you whether or not to use screen. If so, then you may need to install it.<\/p>\n Next, we want to create a user account for 7D2D to run under. We will also create a secure password.<\/p>\n Switch to the newly created user account.<\/p>\n Download the steamcmd utility from the Steam website. This tool is also available on the Steam Wiki.<\/p>\n Once this is done, make the steamcmd “executable”, and run it.<\/p>\n Once it loads, enter your login credentials. You may receive a Steamguard warning. You could also login anonymously with\u00a0 Warning:<\/strong>\u00a0Your password is visible in plain text.<\/p><\/blockquote>\n Set the installation directory and install the application.<\/p>\n Edit\u00a0 Once this is open, replace:<\/p>\n with:<\/p>\n Now, edit the config file:<\/p>\n There are a few key settings in this file that you may want to modify.<\/p>\n Now is a good time to look through other settings that you may want to modify.<\/p>\n Time to start the server. If want to use\u00a0screen, make sure that you are in the 7D2D directory.<\/p>\n Otherwise, start the server without screen.<\/p>\n If you have enabled telnet, you can type “shutdown” from the telnet window.<\/p>\n If you are running in screen,\u00a0Ctrl + C<\/strong>\u00a0will break it out and shut down.<\/p>\n If you are not running screen, run these commands.<\/p>\n Everyone likes a new 7 days to die update. You can set to your 7D2D server to auto-update with a few steps. First, you need to create an update file with the steam login and update commands. Then, create a cron job to run it.<\/p>\n Start by creating the update file.<\/p>\n Save the file. Then, the update script.<\/p>\n Save the update script. Make the script “executable”.<\/p>\n Add a cron entry.<\/p>\n Save the crontab file.<\/p>\n Using your favorite text editor, create the following file:\u00a0 After saving the file, you can use the\u00a0 You can also set\u00a0 At this point, you’re all set. Enjoy your 7D2D server!<\/p>\n If you restart your server, it will reset the game back to day 1.<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","format":"standard","manualknowledgebasecat":[105,247],"manual_kb_tag":[210],"_links":{"self":[{"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manual_kb\/2310"}],"collection":[{"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manual_kb"}],"about":[{"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/types\/manual_kb"}],"author":[{"embeddable":true,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/comments?post=2310"}],"version-history":[{"count":1,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manual_kb\/2310\/revisions"}],"predecessor-version":[{"id":2311,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manual_kb\/2310\/revisions\/2311"}],"wp:attachment":[{"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/media?parent=2310"}],"wp:term":[{"taxonomy":"manualknowledgebasecat","embeddable":true,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manualknowledgebasecat?post=2310"},{"taxonomy":"manual_kb_tag","embeddable":true,"href":"https:\/\/support.aklwebhost.com\/wp-json\/wp\/v2\/manual_kb_tag?post=2310"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}Prerequisites<\/strong><\/h3>\n
dpkg --add-architecture i386\r\napt-get update\r\napt-get install libc6-i386 lib32gcc1 lib32stdc++6 -y\r\n<\/code><\/pre>\n
apt-get update\r\napt-get install screen -y\r\n<\/code><\/pre>\n
adduser <choose a account name>\r\n<\/code><\/pre>\n
su <new account>\r\n<\/code><\/pre>\n
Installation<\/strong><\/h3>\n
mkdir ~\/steamcmd\r\ncd ~\/steamcmd\r\nwget http:\/\/media.steampowered.com\/client\/steamcmd_linux.tar.gz\r\ntar -xf steamcmd_linux.tar.gz\r\nrm steamcmd_linux.tar.gz\r\n<\/code><\/pre>\n
chmod +x steamcmd.sh\r\n.\/steamcmd.sh\r\n<\/code><\/pre>\n
login anonymous<\/code>.<\/p>\n
login <username> <password>\r\n<\/code><\/pre>\n
force_install_dir .\/7D2D\r\napp_update 294420\r\nquit\r\n<\/code><\/pre>\n
Configure the server<\/strong><\/h3>\n
startserver.sh<\/code>\u00a0with your favorite text editor.<\/p>\n
cd 7D2D\r\nnano startserver.sh\r\n<\/code><\/pre>\n
.\/7DaysToDie.x86_64 -logfile 7DaysToDie_Data\/output_log.txt $@\r\n<\/code><\/pre>\n
.\/7DaysToDie.x86 -configfile=serverconfig.xml -logfile 7DaysToDie_Data\/output_log.txt $@\r\n<\/code><\/pre>\n
nano serverconfig.xml\r\n<\/code><\/pre>\n
\n
Start the server<\/strong><\/h3>\n
screen -s 7D2D .\/startserver.sh\r\n<\/code><\/pre>\n
.\/startserver.sh\r\n<\/code><\/pre>\n
Shut down the server<\/strong><\/h3>\n
ps aux | grep -i \"7days\"\r\nkill <procid returned>\r\n\r\n# or (case sensitive)\r\n\r\npkill 7Days\r\n<\/code><\/pre>\n
Auto-update<\/strong><\/h3>\n
nano \/home\/<account name you name in first section>\/serverupdate.txt\r\n\r\n@ShutdownOnFailedCommand 1\r\nlogin steamaccount steampass\r\nforce_install_dir .\/7D2D\r\napp_update 294420\r\nquit\r\n<\/code><\/pre>\n
nano \/home\/<account name you name in first section>\/update.sh\r\n\r\n#!\/bin\/sh\r\ncd \/home\/<account name you made in the first section>\r\n.\/steamcmd.sh +runscript updateserver.txt\r\n<\/code><\/pre>\n
chmod +x update.sh\r\n<\/code><\/pre>\n
crontab -e\r\n\r\n00 00 * * * \/home\/<account name you made in the first section>\/update.sh\r\n<\/code><\/pre>\n
Optional: Setup the server to run as a service<\/strong><\/h3>\n
\/usr\/lib\/systemd\/system\/7dtd.service<\/code>\u00a0then add the following to it:<\/p>\n
[Unit]\r\nDescription=7 Days to Die\r\nAfter=network.target nss-lookup.target\r\n\r\n[Service]\r\nType=simple\r\nPIDFile=\/run\/7dtd.pid\r\nExecStart=<path to 7 Days to Die>\/startserver.sh -configfile=serverconfig.xml\r\nExecReload=\/bin\/kill -s HUP $MAINPID\r\nExecStop=\/bin\/kill -s QUIT $MAINPID\r\nRestart=always\r\n\r\n[Install]\r\nWantedBy=multi-user.target\r\n<\/code><\/pre>\n
systemctl<\/code>\u00a0to start\u00a0
7dtd<\/code>\u00a0as follows:<\/p>\n
systemctl start 7dtd\r\n<\/code><\/pre>\n
7dtd<\/code>\u00a0to start automatically when the server (re)starts using the following command:<\/p>\n
systemctl enable 7dtd\r\n<\/code><\/pre>\n
Final notes<\/strong><\/h3>\n