Downloading and Hosting a Dedicated Server
Dedicated servers are now downloaded using SteamCMD. This is a command line version of Steam.
You can download it from this page.
The first time you run it it will update and you will be left at a STEAM> console. You will want to log in. You can log into an anonymous account by typing:
If you want to specify a download folder then before you update enter this command:
force_install_dirfeature, or try reinstalling your server into another folder
You can then install or update the Garry's Mod Dedicated Server by using the command:
It will slowly download or update.
If you wish to verify your server, enter this instead of the above:
Once it's done you can type quit at the console to exit or just close the SteamCMD window.
You probably don't want to do that every time you want to install/update a server. Don't worry - it supports command lines too.
After downloading and installing the server files you can now run the dedicated sever.
You can either just run
srcds.exe directly or use its command line interface like so:
After installing your server you should set up your GSL Token and the server's location.
Please see Steam Game Server Accounts (GSLT) for help with
sv_setsteamaccount. This is mandatory. Your server's ranking will be penalized if you do not do this.
Please make sure your server conforms to Server Operator Rules.
Next you should set your server's location. This is done via the
sv_location console variable. The convar should directly correspond to a flag icon stored in the
materials/flags16/ folder, without the
.png extension. The maximum length is currently set to 5 characters.
The flag icon filenames follow the
ISO 3166-1 alpha-2 country codes. (http://www.famfamfam.com/lab/icons/flags/)
sv_location gb will display the Great Britain flag,
sv_location us will display the USA flag, etc.
European Union has a special case:
Optionally you can add
+host_workshop_collection <collectionID> to your command line to automatically install workshop addons onto your dedicated server.
Please see Workshop for Dedicated Servers for help with workshop for dedicated servers.
Main article: Linux Dedicated Server Hosting
Install SteamCMD as per the recommendations from the Valve Developer Wiki.
Then install the GMod dedicated server in a similar manner to Windows:
The server is now available in ~/gmodds/.
If you get the error message
You are most likely running 64 a bit system and missing 32 bit libraries.
If the output of this command is x86_64, you are running a 64 bit system and need 32 bit libraries.
See this article on the valve wiki.
32-bit libraries on 64-bit Linux systems
macOS dedicated servers are no longer shipped.
To update your server to the development branch, you'll have to launch your SteamCMD and enter these commands manually:
For the pre-release branch:
For the x64 branch:
To revert back to stable branch:
The development branch is updated regularly.