Project Zomboid

Project Zomboid

28 ratings
Linux Dedicated Server Guide
By Maxtraxv3
how to install a server and mods using linux on a Debian OS's.
such as Ubuntu, Linux Mint, Deepin, AntiX, Kali Linux, Pop_OS, Q4OS, Zorin OS, KDE neon, MX linux, Devuan, SparkyLinux.
Note i made this guide on AntiX.
3
   
Award
Favorite
Favorited
Unfavorite
Setup!
Note im using Debian Linux Distro, this is not for people using Arch linux distros.
(i do not know how pacman works)

First lets get the server files, by downloading the server file updater/downloader
Open your version of terminal, what ever comes preinstalled, ether via right click on the desktop any where and finding it in the menus or by searching for it in you search bar if you have one.

then type the basics before install any programs
sudo apt-get update
type your password when prompted

*** NOTE!
if your setting up on Debian OS it self you will have to run this command at this point
sudo apt install software-properties-common && sudo apt-add-repository non-free && sudo dpkg --add-architecture i386 && sudo apt-get update
most other OS based on debian will come with this as default.

once those are done lets install Steam CMD the download and updater of our server
apt-get install steamcmd

once its downloaded witch should take no time at all, we need to launch it once so finishes its install.
simply type this into your terminal;
steamcmd
it will download it self, then ask you to login, we want to close the terminal and open a new one.

now you want to make a new text file so open any text editor you have and you wanna type:
@NoPromptForPassword 1 force_install_dir /home/LOGINNAMEHERE/Zomboid login anonymous app_update 380870 validate quit

remember to replace the word "LOGINNAMEHERE" with your users account name
(the one you used to login with) save it as update_zomboid.txt

once you saved it where going to paste or copy it in your home folder
(witch is /home/LOGINNAME)

then back in terminal where going to type
steamcmd +runscript $HOME/update_zomboid.txt

it should make a folder in your home directory called Zomboid and start downloading the server files, you should run this command every time you need to update your server.

now run the server once to generate the server setting files
cd $HOME/Zomboid
then
bash start-server.sh
it will ask you to add an admin password on first run.
you can log in as admin by using the account name " admin " and that password you just setup.
once it finished type
quit
to close it.
Server Config!
now that you have downloaded the server files its time to modify the config files!

if we navigate to "/home/LOGINUSERNAME/Zomboid" there should be file called "Server"
in that folder you will have to Edit "servertest.ini" and you should give "servertest_SandBoxVars.lua" a good look as well.

here we can change the default welcome message at this line
ServerWelcomeMessage=Welcome to Project Zomboid Multiplayer! <LINE> <LINE> To interact with the Chat panel: press Tab, T, or Enter. <LINE> <LINE> The Tab key will change the target stream of the message. <LINE> <LINE> Global Streams: /all <LINE> Local Streams: /say, /yell <LINE> Special Steams: /whisper, /safehouse, /faction. <LINE> <LINE> Press the Up arrow to cycle through your message history. Click the Gear icon to customise chat. <LINE> <LINE> Happy surviving!

and you must add a name to your server here at this line:
PublicName=

and a public description at this line right blow it;
PublicDescription=

set your servers port
DefaultPort=16261

and remember to set a password for your Rcon weather you use it or not
RCONPassword=

i very much recommend read and going threw the files in the server folder and setting them up the way you like.

once your done, open terminal and type:
cd /home/LOGINUSERNAME/Zomboid

then type this:
bash start-server.sh
this will run the server.

you can type
quit
to save and quit your server
Mods!
now to add mods to your server, remember to make sure there the right version before you download (or subscribe) any mods.

for this you can install the normal steam client

sudo apt-get install steam
then
steam
in terminal or use what ever shop/app install that comes with your OS

alright once you are lodged into steam you need to download Project Zomboid witch will download any of the subscribed mods,

if you have never added any mods to your game before, you just click on Project Zomboid on your left in your library, then middle right, should say workshop click on that, and that where we find the mods we want to install on your server.


once you have downloaded the mods you want by clicking subscribe, you need to navigate to your steam install directory witch the default should be
$HOME/.local/share/Steam/steamapps/workshop/content/108600

you need each mods modid number witch can found here.

copy each number and add it to servertest.ini at the line
WorkshopItems=
after each mod id number, you have put a ";" like this:
WorkshopItems=324879;32423;432423;42354364
note the last one doesnt need the ";"

now we need the mod Name IDs and add them the same way to servertest.ini at this line:
Mods=

witch you can find "$HOME/.local/share/Steam/steamapps/workshop/content/108600/MODIDNUMBER/mods/MODNAME"
then open the file called "mod.info"


thankfully MOST mods have ther MOD ID NUMBER and MOD ID NAME on the page of there mod
on steams website HERE
i showed you this way because there are some who forget to do this.

now that you have your mods ids in your servertest.ini file we just need to copy the mod folders
(we only need the folder with the mod.info in it)


and copy it to our server by first making a folder in /Home/LOGINUSERNAME/Zomboid
called "mods" (all lower case) then copying all the mods into it.

once you have done that your all set to run your server with mods.
Map Mods!
***NOTE: you may have to add the mod and download the map files first by running the server once with it added to the "servertest.ini" before adding it to "servertest_spawnregions.lua"

Map mods are a little different form normal mods
after adding the mod id and name id to "servertest.ini"
you also need to find the line and add the "Map Folder" ID to it
Map=Greenport;Muldraugh, KY
this like works a lot like the others, with one exception, you HAVE to put "Muldraugh, KY" as the last map

and in order for the server to see it as a spawn location we need to edit "servertest_spawnregions.lua"
(not necessary if do not plan on players spawning there)

we can add line after
{ name = "Riverside, KY", file = "media/maps/Riverside, KY/spawnpoints.lua" },
by pressing return or enter

you just need to find where the file name
spawnpoints.lua if the map mod has one (not all do) here
Zomboid/steamapps/workshop/content/108600/WORKSHOPNUMBER/mods/MODID
replace "WORKSHOPNUMBER" with the Workshop ID and MODID with Mod ID

should look like this when we add the file path
file = "steamapps/workshop/content/108600/3033014448/mods/Greenport/media/maps/Greenport/spawnpoints.lua"

using the "Mod ID" as the "name" it should look like this

function SpawnRegions() return { { name = "Muldraugh, KY", file = "media/maps/Muldraugh, KY/spawnpoints.lua" }, { name = "West Point, KY", file = "media/maps/West Point, KY/spawnpoints.lua" }, { name = "Rosewood, KY", file = "media/maps/Rosewood, KY/spawnpoints.lua" }, { name = "Riverside, KY", file = "media/maps/Riverside, KY/spawnpoints.lua" }, { name = "Greenport", file = "steamapps/workshop/content/108600/3033014448/mods/Greenport/media/maps/Greenport/spawnpoints.lua" }, -- Uncomment the line below to add a custom spawnpoint for this server. -- { name = "Twiggy's Bar", serverfile = "servertest_spawnpoints.lua" }, } end

normally file name are not as long as this.
12 Comments
=sMu= Jun 23, 2024 @ 1:09am 
Hey, you’re welcome, and thanks for the guide as well.
Maxtraxv3  [author] Jun 18, 2024 @ 3:36am 
thanks updated.
=sMu= Jun 2, 2024 @ 12:26pm 
To install SteamCMD add the non-free repository and x86 packages must be enabled. In Debian 12 (Bookworm) the apt-add-repository command no longer works, so you will need to create a work-around (See also: https://stackoverflow.com/questions/76688863/apt-add-repository-doesnt-work-on-debian-12) .

sudo apt update; sudo apt install software-properties-common; sudo apt-add-repository non-free; sudo dpkg --add-architecture i386; sudo apt update
sudo apt install steamcmd
Maxtraxv3  [author] Nov 17, 2023 @ 6:53pm 
added guide for adding map mods with spawn point locations.
Maxtraxv3  [author] Nov 17, 2023 @ 4:08pm 
fix a few spelling errors added a step for debian os users.
Maxtraxv3  [author] Nov 17, 2023 @ 3:32pm 
fixed! :D
Maxtraxv3  [author] Nov 17, 2023 @ 3:22pm 
ah i see your correct ill change that now, thanks!
CHORZORD Nov 17, 2023 @ 10:25am 
I have been looking into why my mods are not working, and I found out that you got it swapped between the workshop ID and the mod ID. Basically, the word one is the mod ID and the number on is workshop id. I hope this helps other newbies like me haha.
Maxtraxv3  [author] Sep 16, 2023 @ 5:56pm 
"sudo apt install software-properties-common && sudo dpkg --add-architecture i386"
come with most servers os and desktop envoments os.
Maxtraxv3  [author] Sep 16, 2023 @ 5:53pm 
so your running a striped down version of debian 11? unless you really wanna end up trobble shooting for years dont do that.