Installing a Linux Left 4 Dead Dedicated Server

01 December 2008

Here’s what I did to install a dedicated linux server for Left 4 Dead. Ideally you want to do this on a non-root account.

First, prep a directory for your steam client. Your game installs will reside here, each in its own subdirectory.


mkdir steam
cd steam

Download the linux steam client and unzip it. Type yes when prompted. Afterwards you’ll have an executable named steam which is used to download and update games.

wget http://storefront.steampowered.com/download/hldsupdatetool.bin
chmod +x hldsupdatetool.bin
./hldsupdatetool.bin

Run ./steam and you’ll see a list of options for the steam client. I used the command below to download, but I’m not sure yet what l4d_full is. I figure I can switch to that easy enough if I run into a roadblock with left4dead.


./steam
./steam -command update -game left4dead -dir .

I like to run servers inside screen so that I can logout and log back in from any computer with ssh. This will also keep the server running in the background if your desktop has to reboot.


cd l4d
screen
./srcds_run

You’ll see a bunch of text fly by, and now your server is running! Press ctrl+a then d to detach from your screen, getting you back to the command prompt. To bring the left4dead server back up make sure you’re logged into the right user and run screen -xD. The screen program is quite elaborate but these are the basics to keep a process running in the background.

This just gets a very basic server running. There are plenty of things you can customize in your steam/l4d/left4dead/ directory. For instance:

motd.txt: This is the message displayed when players join your server.
missioncycle.txt: Pick which missions are played and in what order.
maplist.txt: This is the list of what maps are available on the server. Essentially these maps can be picked by an admin or possibly by player vote, even if they aren’t part of the normal rotation.
host.txt: This appears to be a website displayed when players join the server. This may be displayed alongside the motd.txt?

In the steam/l4d/left4dead/cfg/ directory there are some options for configuring gameplay. A lot of these appear to be defaults for other types of servers and even client configurations which are irrelevant to the server.

server.cfg: This is the one that you typically put all your custom config options in. Fortunately the defaults are very good.
game.cfg: I believe this is the client-side version of server.cfg. So on your machine you play on, you can put custom options here that aren’t part of the default options interface.
infected.cfg: Looks like changing this 0 to a 1 lets humans play as zombies on your server. infected_off.cfg is the same file with the 0 set

I don’t have a good listing of the options that you can put in game.cfg, but if you check through some of the default configs in that directory like two_players.cfg and infected_360.cfg you’ll see a few of the options you can change.

This entry was posted on 01 December 2008 and is filed under Games.

Leave a Reply

You must be logged in to post a comment.