Skip to content

Counter-Strike 2 on a VPS

CS2 dedicated server

Category
Game servers
Author
Valve; installer by LinuxGSM
License
Proprietary

The script is free · VPS from $13.30 per month · installs in about 15 minutes

Install over SSH

root@vps:~# useradd -m -s /bin/bash cs2server && su - cs2server -c 'curl -Lo linuxgsm.sh https://linuxgsm.sh && chmod +x linuxgsm.sh && bash linuxgsm.sh cs2server' && cd /home/cs2server && ./cs2server install && su - cs2server -c './cs2server auto-install'

  • SystemUbuntu 24.04 · x86_64ok
  • Sourcegithub.com/GameServerManagers/LinuxGSMok
  • Port27015/tcp/udplisten

✓ Counter-Strike 2 installed · about 15 minutes

root@vps:~#

Install command from the library. Output is shortened and may differ on your server.

What it is

  • CS2
  • Steam
  • LinuxGSM
  • Game server

Your own Counter-Strike 2 dedicated server for a clan, practice or a community: your maps, modes, plugins and rules, with no third-party ads or restrictions.

Installation and maintenance are handled by LinuxGSM (MIT), a popular game server manager for Linux. It downloads the server via SteamCMD, installs dependencies, tracks updates and runs the server in the background.

A CS2 server takes several tens of gigabytes of disk space, so choose a plan with plenty of NVMe headroom.

  • Install and update via SteamCMD
  • Runs in the background via tmux
  • Auto-restart on crash (monitor)
  • Backups with the backup command
  • Telegram and Discord notifications via LinuxGSM

Recommended plan

For Counter-Strike 2: at least 4 vCPU, 8 GB RAM and 150 GB NVMe.

Minimum to run
2 vCPU · 4 GB RAM · 60 GB disk
Systems
Ubuntu 22.04 · Ubuntu 24.04 · Debian 11 · Debian 12

How to install

Three steps in the bot or one command over SSH; installation takes about 15 minutes.

  1. 01

    Choose a plan in the bot

    Open @ExpressHost_bot and pay for a VPS. The server will be ready in about 60 seconds.

  2. 02

    Add Counter-Strike 2

    At the “Add-ons” step pick the script from the library, or run it later: Server settings → Scripts.

  3. 03

    Start the server

    su - cs2server -c './cs2server start'

Manually over SSH

Connect to the server as root and run the command. Supported systems: Ubuntu 22.04, Ubuntu 24.04, Debian 11, Debian 12.

Install command
useradd -m -s /bin/bash cs2server && su - cs2server -c 'curl -Lo linuxgsm.sh https://linuxgsm.sh && chmod +x linuxgsm.sh && bash linuxgsm.sh cs2server' && cd /home/cs2server && ./cs2server install && su - cs2server -c './cs2server auto-install'

Ports

Counter-Strike 2 ports
PortProtocolPurpose
27015tcp/udpServer game port

After installation

  1. 1.Start the server: su - cs2server -c './cs2server start'
  2. 2.To make the server visible in the public list, get a GSLT token at steamcommunity.com/dev/managegameservers and set it in the config (gslt parameter)
  3. 3.Server console: su - cs2server -c './cs2server console' (exit with Ctrl+B, then D)

Counter-Strike 2 FAQ

Didn’t find an answer? Message @ExpressHost_SupportBot.

How do I update the server?

su - cs2server -c './cs2server update' — LinuxGSM checks Steam for an update and restarts the server only if there is one.

Where are the files and settings?

In /home/cs2server: game files in serverfiles, LinuxGSM settings in lgsm/config-lgsm/cs2server. ./cs2server details shows all ports and paths.

Why doesn't the server run as root?

LinuxGSM forbids running game servers as root for security, so the command creates a separate cs2server user.

Counter-Strike 2 installs at checkout.