L4D2 2023 dedicated server tutorial

Overview

It's been a while since I last played and recently I was trying play versus but always high ping. Looks like there aren't many Brazilian servers anymore (vanilla versus). Next, I've decided to try to host my own. It took me some weeks to figure out everything, plus my limitations around linux management. Therefore, here's my own tutorial about hosting a L4D2 versus linux. It may sound funny but the linux setup it's not that hard.

In short, this will help you how to setup a vanilla versus server (with extra mods to keep the server running in VERSUS).

Server Piol @gangsta L4D2 Versus BRAZIL

Configuration

Setup

We'll cover each separately: VM and Software setup (SteamCMD, LinuxGSM and mods and server).

VM setup

Create a ubuntu linux VM in Azure

This should be straightforward. By default, only ssh connections will be available. If needed, you can install the remote desktop on it and be able to have visual interface. https://learn.microsoft.com/en-us/azure/virtual-machines/linux/quick-create-portal?tabs=ubuntu

Make sure TPC and UDP ports are open for the server. If you didn't change, the default port for source games is 27015

Optional: graphical interface for remote desktop

If you want, just follow these instructions: https://learn.microsoft.com/en-us/azure/virtual-machines/linux/use-remote-desktop?tabs=azure-cli

Software setup

SteamCMD

Steam CMD is the console version used by dedicated servers. No graphical interface. Install using following instructions https://developer.valvesoftware.com/wiki/SteamCMD

LinuxGSM

LinuxGSM is a command-line tool for quick, simple deployment of linux dedicated game servers. https://linuxgsm.com/servers/l4d2server/

Metamod and Sourcemod

We'll need to install Metamod first followed by Sourcemod. These are the binaries that will enable us adding some plugins to the server.

Metamod is a C++ plugin environment for Source engine games. Find the install guide here https://www.sourcemm.net/

Sourcemod is a server modification that depends on Metamod https://www.sourcemod.net/

Mods

Here are the list of plugins that I've added to my server:

Server configuration

Now, the last but not least important steps:

Below is the final image of what a player will see when joining the game

L4D2 server welcome page

Final notes

After getting everything done, the server should be good to go live. Following are some commands for server management.

    
$ ./l4d2server start
$ ./l4d2server stop
$ ./l4d2server restart
$ ./l4d2server details
    

Running details should return Status: STARTED as seen in the image below

L4D2 console saying status started

Usefull locations:

Links