Skip to content

Dedicated Server: Left 4 Dead 2 Dedicated Server Linux Setup

Learn how to set up a Left 4 Dead 2 Dedicated Server on your Linux VPS for seamless multiplayer gaming → Find out more

12 November 20262 min read24 Views0 helpful

Introduction

Have a Linux VPS and want to install the Left 4 Dead 2 Dedicated Server on it? You're in the right place. In this guide, we'll walk you through installing the service on your Linux server with SteamCMD. We'll use Ubuntu as an example, but the process is very similar on other distributions.

Preparation

First, connect to your VPS via SSH. If you need help, follow our SSH Initial Access guide. You'll also need to set up SteamCMD on your Linux server the first time you use it. Follow our SteamCMD Linux Setup guide, and make sure SteamCMD is fully set up before continuing.

Installation

Log in as the steam user and switch to the steam user's home directory to keep everything organized.

Code
sudo -u steam -s
cd ~

Once you're logged in, start the installation with the following command. It uses SteamCMD to install the server directly in the steam user's directory:

Code
steamcmd +force_install_dir '/home/steam/l4d2-ds' +login anonymous +app_update 222840 validate +quit

Be patient—the download may take a while, depending on the size of the game. Once it's finished, you'll see a success message.

Configuration

The basic installation of your Left 4 Dead 2 server is now complete. You can configure additional server settings directly in the startup file.

Go to your root directory. In the cfg folder, you'll find the server.cfg file, which you can edit to adjust server options.

Code
nano /home/steam/l4d2-ds/l4d2/cfg/server.cfg

Register a GSL Token

To let other players join your server, you need to generate and add a Game Server Login Token (GSLT). This token authenticates your server with Steam. Create your GSLT at http://steamcommunity.com/dev/managegameservers using the game ID 222840 for Left 4 Dead 2.

Then add the token to your server startup parameters with +sv_setsteamaccount <TOKEN>.

Start and Connect to the Server

You can now start your server. Go to the game's main directory and run the following command:

Code
./srcds_run -console -game left4dead2 -secure +maxplayers 22 +map de_dust +sv_setsteamaccount XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

You should now see logs in the terminal indicating that the server started successfully. Note that the first startup may take a little longer while everything is being set up. Alternatively, you can connect directly by using the search at the bottom of the server list and entering [your_ip_address]:2456.

Conclusion

Congratulations, you've successfully installed and configured your Left 4 Dead 2 server on your VPS! As a next step, we recommend following our Setup Linux Service guide. It explains how to set up your new Dedicated Game Server as a service. This offers many benefits, including automatic startup when your system boots, automatic updates, easy management, and access to logs—and much more!

If you have any questions or run into problems, our support team is here to help every day! 🙂

FAQ

Frequently asked questions

You need SSH access to your Linux server and a one-time SteamCMD setup (see the “SteamCMD Linux Setup” guide).
As the steam user, run steamcmd +force_install_dir '<path>' +login anonymous +app_update 222840 validate +quit (Steam app ID 222840).
This keeps the server from running with root privileges. The guide uses the steam user and installs everything in that user's home directory.

Feedback

Was this article helpful?

Your feedback helps us prioritize and improve content.

0 of 0 Users found this article helpful.

Personal support

Need more help than the guide provides?

Our ZAP support team knows your product — briefly describe your issue and we'll help you personally.

Zappy knows this guide and answers you right in the chat.