How to Host Dedicated Counter Strike: Global Offensive (CS:GO) Server Linux (Ubuntu/CentOS)

Alon Shrestha » 28 Nov 2020 » linux, gaming

Ready for gaming? Yeah! haha 😎. Playing CS:GO with your friends on a dedicated server lower than 5 pings is an awesome feeling only gamers can understand.

Over two months ago I built my personal server for Counter-Strike: Global Offensive. Trust me it was more fun than I expected.

Steam allows you to host a CS:GO on custom server modifying settings like tick rate, number of players, base map, game rule, etc. Moreover, the best hack I enjoy is; you can download and install free custom skins for your weapons.

This is a complete guide for hosting a CS:GO dedicated server on linux. In order to understand the installation process, I expect you have some basic knowledge on linux.

For those who have never heard about linux, copy/paste the command and match the output given in this guide.

Since this is a long article, patiently follow the guide step by step till the end and then be ready for gaming.

How To Host CS:GO Dedicated Server

Table Of Content

I had used the EC2 t2.micro server from AWS with 1 GB RAM and 40 GB disk space. This spec was enough for me to play a competitive match with my 9 other friends.

However, if you are planning to build a server for a tournament, It will be better if you go with at least 4GB of RAM or higher.

CS:GO Server System Requirements

  • RAM: 2 GB Minimum - 4 GB Maximum
  • CPUs: 2 Minimum
  • Disk Space: 40 GB (Recommended)
  • Bandwidth: Unlimited (Recommended)
  • Operating System: Linux (CentOS, Ubuntu)

Usually, CS:GO can be installed in 15 - 20 GB disk space but due to frequent game updates and space used by OS(Operating System), 40 GB is recommended.

Affordable Hosting For CS:GO Server

Affordable Hosting For CS:GO Server

Now, we will need a VPS(Virtual Private Server) to deploy CS:GO.

  • RAM: 2 GB
  • Disk Space: 40 GB
  • Bandwidth: 2 TB
  • 30 days money back guarantee.


Setup CS:GO Environment In Ubuntu/CentOS Server

Login to your instance with a root user account then install libraries which allows steamCMD to run.

Step 1: Install library package


sudo apt-get install lib32gcc1


yum install glibc.i686 libstdc++.i686 -y

Step 2: Create a seperate user “steam” for running CS:GO.

sudo useradd -m steam

Switch user to “steam”

su - steam

Step 3:Create an installation path directory where we download SteamCMD.

mkdir ~ / Steam && cd ~ / Steam

Downloading and Installing SteamCMD

Step 4: Download the latest version of SteamCMD.


Step 5: Extract the downloaded file.

tar xf steamcmd_linux.tar.gz

Step 6: Run SteamCMD script file


This file will download the update from steam which seems like Downloading and Installing SteamCMD In Linux |
After that, the updated steam will provide you the cmd prompt as shown below.


Step 7: Login using a steam account here.

Steam> login <userID> <password>

Replace your userID and password with your steam credential.

You can also use an anonymous login which is recommended.

Steam> login anonymous

Step 8: Set your CS:GO dedicated server install directory.

force_install_dir ./cs_go/

Step 9: Finally, download and install CS:GO on the server.

app_update 740 validate

You will see “Success! App ‘740’ fully installed” as below. This will take some time to complete. Downloading and Installing SteamCMD In Linux |

Allow Access on Server’s TCP and UDP Ports

In order to connect the game server, TCP and UDP ports should be allowed to all the players from the server. Downloading and Installing SteamCMD In Linux |

You can find this option in your network setting. If you are unable to do this, contact your hosting provider for help.

This is optional if your server firewall is disable or it accepts all network protocols. But, make sure to check it.

Register CS:GO Game Auth Token ID

In order to run the game you need your steam token ID. Without a token ID, you won’t be able to host a game.

Your steam account should be qualified for generating token ID. Check here for the requirements and get your token ID.

Follow below picture to generate your auth token ID. Downloading and Installing SteamCMD In Linux |

Note: The appID 740 is the registered ID for Counter-Strike: Global Offensive dedicated server whereas appID 730 is the official game ID.

You will generate a token ID similar to this X38F6E71A3B8G6FE08354AF5BE078.

Run CS:GO On Server

There are specific commands to run different game modes. This means you have to enter different commands to run Causal, Competitive, and Deathmatch Mode.

The command seems to be like this:

./srcds_run -game csgo -console -usercon + game_type 0 + game_mode 0 + mapgroup mg_active + map de_dust2 + sv_setsteamaccount X38F6E71E4FA3B8G6FE08354AF5BE078 THISGSLTHERE -net_port_try

For different modes, you need to change the game_mode value.

Casual = game_mode 0

Competitive = game_mode 1

Deathmatch = game_mode 2

Important: Remember, you should be inside the cs_go directory before you run the command.

Replace “YOUR AUTH TOKEN” in the below command and enter.


./srcds_run -game csgo -console -usercon + game_type 0 + game_mode 0 + mapgroup mg_active + map de_dust2 + sv_setsteamaccount YOUR AUTH TOKEN THISGSLTHERE -net_port_try


./srcds_run -game csgo -console -usercon + game_type 0 + game_mode 1 + mapgroup mg_active + map de_dust2 + sv_setsteamaccount  YOUR AUTH TOKEN THISGSLTHERE -net_port_try


./srcds_run -game csgo -console -usercon + game_type 1 + game_mode 2 + mapgroup mg_allclassic + map de_dust + sv_setsteamaccount YOUR AUTH TOKEN THISGSLTHERE -net_port_try

You will see the public IP of your game server after entering the above command. Downloading and Installing SteamCMD In Linux |

Join CS:GO Server

Launch steam application and open CS:GO. There are two ways you can join the game server.

First, connect through the game console. For that enable the developer console. Downloading and Installing SteamCMD In Linux |

Get back to the dashboard and open the console using “~” keyword and type “connect < your-ip-address >”. Downloading and Installing SteamCMD In Linux |

Second, adding server IP to your favorite list. For that, go to the Community Server Browser.

Click on the favourite tab. Downloading and Installing SteamCMD In Linux |

Add your server IP and connect it. Downloading and Installing SteamCMD In Linux |

Run CS:GO In Server’s Background

Your game will be disconnected or stopped when you log out from the server.

It is not possible to host the game staying logged in 24x7 on the server. So, we will host the game in a background session. By doing so, your game won’t stop until your server gets turned off.

For that, we will install a screen application on the server.

Install Screen In Ubuntu

sudo apt-get install screen -y

Install Screen In CentOS

sudo yum install screen -y

After installation, create a new session named “csgo” by typing:

screen -R csgo

Now run the game host command. In my case, I am running competitive game mode.

./srcds_run -game csgo -console -usercon + game_type 0 + game_mode 1 + mapgroup mg_active + map de_dust2 + sv_setsteamaccount  YOUR AUTH TOKEN THISGSLTHERE -net_port_try

When the game is hosted successfully, exit from that screen(detach) by pressing the keys at the same time.

Crtl + a + d

Now you are out of that session. To see the running background session type

screen -ls

You will get the output like this:

There is a screen on:
    7166.csgo    (Detached)
1 Socket in /run/screen/S-stechalon.

7166 is the ID and csgo is the name of the screen.

To rejoin the detached screen type:

screen -r 7166

Set Username and Password in CS:GO Server

In this section, you will learn to configure your server hostname and password. This increases the security of the game.

Edit the autoexec.cfg file and add your hostname and password that you want. Downloading and Installing SteamCMD In Linux |

Refresh your favorite list and check the Hostname. You will see the changes as mine as shown below.
Downloading and Installing SteamCMD In Linux |

This “CS:GO advanced configuration” article can be helpful for you in order to customize the game.

Change CS:GO Tick Rate

Tick rate collects the information of incoming player data and events which help to calculate the performance of the game and send data to players. This allows players for better game performance. You can get more knowledge about the tick rates here.

It is easy to change the tick rate of your game. Simply, add some command in the autoexec.cfg file.

Edit the file located in csgo/cfg/autoexec.cfg and add the following line.

sv_minupdaterate 128
sv_mincmdrate 128

How to Update CS:GO On The Dedicated Server

Usually, CS:GO provides updates every week or in a month. In this case, you can’t run the game on the server without updating it. To update the game, run the command from above steps 6 to 9.

Low Ping CS:GO Gameplay

The best way to get the lowest ping is by hosting the game server near you or inside your country. Try to get a server from a well-known hosting provider.

You can also use a different VPN and select the country where the game is hosted to reduce the ping level.


Well, We have come to the end of this guide. I have tried my best to cover the topic on how to host your own CS:GO dedicated server in Linux. I hope you have hosted and enjoyed your personal server.

If there are any queries you have please let me know in the comment section below.

GG Guys 🤘🤘.