How to Create an RP Server on Garry's Mod From Scratch?
Par Benjamin D. · PDG
· Mis à jour le August 11, 2026 · Lecture 11 min

Contents
Setting up a Garry's Mod RP server is one of the most rewarding projects in the Source engine world, and also one of the most technical: you're not just booting a map, you're running a Lua-driven economy, a Workshop content pipeline, an admin hierarchy and a database. This 2026 tutorial walks through the full stack, from gamemode choice to tickrate tuning, whether you host on a managed panel or on your own VPS.
Before you install: planning your Garry's Mod RP server
A roleplay server is heavier than a sandbox or TTT server. Every player carries entities: printers, doors, shipments, vehicles, props, NPC vendors. The CPU does the physics and Lua work on a single main thread, so raw single-core performance matters far more than core count.
Choose your RP gamemode first
| Gamemode | Profile | Notes |
|---|---|---|
| DarkRP | Classic, huge addon ecosystem | Easiest entry point, tons of documentation, easy to configure via darkrp_config/ |
| DarkRP forks (custom bases) | Heavily modified DarkRP | Better performance if the fork cleaned up old code, but less community support |
| Semi-serious / custom RP frameworks | Military RP, SCP RP, City RP | Usually DarkRP-derived, requires more Lua work |
| Serious RP bases (nutscript-like) | Character-driven, schema based | Steeper learning curve, lower entity spam |
For a first Garry's Mod RP server, DarkRP is the pragmatic choice. It's stable, it's documented, and 90% of the paid and free addons on the Workshop assume DarkRP hooks.
Sizing your resources
- CPU: the single most important factor. A modern Ryzen 9 with high clocks handles a busy RP server with hundreds of entities far better than an old server-grade CPU with many slow cores.
- RAM: srcds is a 32-bit-friendly workload but Workshop content and Lua caches add up. Plan roughly 3–4 GB for a 32-slot DarkRP setup with a large collection, more if you stack vehicles, weapon packs and map content.
- Storage: NVMe SSD. Map loading, Workshop extraction and FastDL packing are I/O bound. Mechanical storage will make map changes painfully slow.
- Slots: start at 32. RP communities live or die on population density, not on empty slots. An overprovisioned 128-slot server with 12 players feels dead and costs you performance headroom.
- Network: RP servers are chatty (entity updates). Anti-DDoS is not optional — RP communities attract retaliation from banned players. On Garry's Mod server hosting at Nexus Games, DDoS protection is included by default on every instance.
Pick your hosting model
Two viable routes:
- Managed game server — instant deployment, NexusPanel with live console, file manager, addon/plugin installation, sub-users for your staff team, and automatic backups. You focus on Lua and moderation instead of Linux.
- Self-hosted on a VPS — full control over srcds, cron jobs, MySQL, FastDL web server. A Linux VPS works well here, or a Pterodactyl VPS if you want a container panel to run several game instances yourself.
Installing your Garry's Mod RP server step by step
Route A: deploy through a panel
With a managed instance, the base install is done for you. Your checklist looks like this:
- Create the Garry's Mod server, select region closest to your player base (latency matters more than you think for RP driving and combat).
- In the panel startup settings, set the gamemode to
darkrpand the map torp_downtown_v4c_v2(or your paid map). - Upload or clone DarkRP into
garrysmod/gamemodes/darkrp/. - Add your Workshop collection ID and Steam Web API key in the startup parameters.
- Edit
garrysmod/cfg/server.cfgthrough the file manager. - Restart from the console tab and watch the live output for Lua errors.
Route B: install srcds on a VPS with SteamCMD
Start from a clean Debian or Ubuntu box. Never run a game server as root.
sudo apt update && sudo apt upgrade -y
sudo dpkg --add-architecture i386
sudo apt update
sudo apt install -y lib32gcc-s1 lib32stdc++6 curl tar screen unzip
sudo useradd -m -s /bin/bash gmod
sudo su - gmod
mkdir -p ~/steamcmd && cd ~/steamcmd
curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar zxvf -
./steamcmd.sh +force_install_dir /home/gmod/gmodserver \
+login anonymous \
+app_update 4020 validate \
+quit
Then install DarkRP and its dependency DarkRP modification:
cd /home/gmod/gmodserver/garrysmod/gamemodes
git clone https://github.com/FPtje/DarkRP.git darkrp
git clone https://github.com/FPtje/darkrpmodification.git ../addons/darkrpmodification
Never edit files inside gamemodes/darkrp/ directly. All your jobs, shipments and settings belong in addons/darkrpmodification/lua/darkrp_config/ and darkrp_customthings/. That way a DarkRP update never wipes your configuration.
A systemd unit so the server survives reboots
sudo nano /etc/systemd/system/gmod.service
[Unit]
Description=Garry's Mod DarkRP Server
After=network-online.target
[Service]
Type=simple
User=gmod
WorkingDirectory=/home/gmod/gmodserver
ExecStart=/home/gmod/gmodserver/srcds_run -game garrysmod \
-console -norestart \
+gamemode darkrp \
+map rp_downtown_v4c_v2 \
+maxplayers 42 \
-tickrate 22 \
-port 27015 \
+host_workshop_collection 123456789 \
-authkey YOUR_STEAM_WEB_API_KEY
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
sudo systemctl daemon-reload
sudo systemctl enable --now gmod
sudo systemctl status gmod
sudo journalctl -u gmod -f
server.cfg: the core of your configuration
Edit garrysmod/cfg/server.cfg. A sane RP baseline:
hostname "[EU] MyCity RP | Serious DarkRP | Custom Jobs"
sv_password ""
rcon_password "aVeryLongRandomRconPassword"
sv_lan 0
sv_region 3
// Networking - RP servers push a lot of entity data
sv_minrate 100000
sv_maxrate 0
sv_minupdaterate 20
sv_maxupdaterate 66
sv_mincmdrate 20
sv_maxcmdrate 66
net_maxfilesize 64
// Sandbox limits: keep prop spam under control
sbox_maxprops 40
sbox_maxragdolls 2
sbox_maxeffects 5
sbox_maxvehicles 2
sbox_maxnpcs 0
sbox_godmode 0
sbox_noclip 0
sbox_playergod 0
// Physics stability
gmod_physiterations 2
sv_gravity 600
// Anti-cheat / abuse basics
sv_allowcslua 0
sv_alltalk 0
sv_kickerrornum 0
// FastDL
sv_downloadurl "https://cdn.yourdomain.com/gmod/"
sv_allowdownload 1
sv_allowupload 0
exec banned_user.cfg
exec banned_ip.cfg
sv_allowcslua 0 is non-negotiable on an RP server: it blocks a large class of client-side Lua exploits. Keep sbox_maxprops low — RP is not build sandbox, and prop spam is the number one cause of tickrate collapse.
Workshop collection and FastDL
You have two content delivery paths, and serious servers use both:
- Workshop collection — create a public collection on Steam, grab its ID, pass it via
+host_workshop_collectionwith a Steam Web API key. Clients download through Steam's CDN, which is fast and cached. - FastDL — for content that isn't on the Workshop (custom paid maps, your own materials/sounds). Pack it in
garrysmod/, compress to.bz2, and serve it over HTTP from a web server or object storage, then pointsv_downloadurlat it.
Force-download Workshop items with a small autorun file, garrysmod/lua/autorun/server/sv_workshop.lua:
resource.AddWorkshop("2818169195")
resource.AddWorkshop("104815552")
resource.AddWorkshop("112806637")
A quick bz2 pack loop for FastDL on a VPS:
cd /home/gmod/gmodserver/garrysmod
find maps materials models sound -type f \
\( -name "*.bsp" -o -name "*.vmt" -o -name "*.vtf" -o -name "*.mdl" -o -name "*.vvd" -o -name "*.wav" -o -name "*.mp3" \) \
-exec bzip2 -kf {} \;
rsync -av --include="*/" --include="*.bz2" --exclude="*" ./ /var/www/fastdl/gmod/
Configuring DarkRP: jobs, entities, economy
Inside addons/darkrpmodification/lua/darkrp_config/settings.lua, the values that actually shape gameplay:
GM.Config.startingmoney = 500
GM.Config.normalsalary = 45
GM.Config.paydelay = 300
GM.Config.propertytax = false
GM.Config.doorcost = 45
GM.Config.propcost = 5
GM.Config.adminsents = 1
GM.Config.deathblack = true
GM.Config.dropmoneyondeath = true
GM.Config.maxdoorsallowed = 5
GM.Config.enablebuypistol = true
GM.Config.voiceradius = true
GM.Config.chatradius = 250
GM.Config.propspawning = false
propspawning = false is standard on serious RP: only staff and certain jobs spawn props, which kills half your moderation workload. A custom job in jobs.lua looks like this:
TEAM_MEDIC = DarkRP.createJob("Paramedic", {
color = Color(47, 79, 79, 255),
model = {"models/player/kleiner.mdl"},
description = [[Heal injured citizens for a fee.]],
weapons = {"med_kit"},
command = "medic",
max = 3,
salary = 65,
admin = 0,
vote = false,
hasLicense = false,
candemote = false,
category = "Citizens",
PlayerSpawn = function(ply)
ply:SetHealth(100)
ply:SetArmor(25)
end
})
Admin mod and staff structure
Install ULX + ULib (or ServerGuard) into garrysmod/addons/. Then set your own rank from the live console:
ulx adduserid STEAM_0:1:12345678 superadmin
ulx addgroup moderator
ulx addgroupallow moderator ulx kick
ulx addgroupallow moderator ulx ban
ulx addgroupallow moderator ulx jailtp
ulx groupallow moderator "ulx who"
Define your ranks before you recruit staff, not after. A typical ladder: User → Trusted → Moderator → Admin → Superadmin, with prop/tool permissions granted only from Moderator up. Use the panel's sub-user feature to give head admins console and restart access without handing over your billing account.
Performance, security and maintenance of an RP server
Tickrate and the Lua profiler
Garry's Mod defaults to 33 tick. Many RP servers run 22 tick intentionally: lower CPU cost per second, more headroom for entities, and RP gameplay rarely needs competitive hit registration. If your server hosts heavy gunfights, 33 is the sweet spot; going to 66 on a full RP server usually costs more than it gains.
Diagnose lag from the console instead of guessing:
// server console
stats
net_graph 1
lua_run print(#ents.GetAll())
lua_run for _,v in ipairs(ents.GetAll()) do print(v:GetClass()) end
If #ents.GetAll() creeps toward the 8192 entity ceiling, you have an addon leaking entities. Common culprits: money printers that never clean up, dropped weapons, unremoved decals and NPC spawners. Add a cleanup timer:
timer.Create("RPCleanupDroppedMoney", 600, 0, function()
for _, ent in ipairs(ents.FindByClass("darkrp_money")) do
if ent:GetCreationTime() and CurTime() - ent:GetCreationTime() > 600 then
ent:Remove()
end
end
end)
Other practical wins:
- Audit your Workshop collection quarterly. Broken or abandoned addons throw Lua errors every tick.
- Keep one addon per feature. Three weapon bases fighting each other will tank performance.
- Use MySQL instead of SQLite once you pass ~40 concurrent players — SQLite writes block the main thread.
MySQL for money, jobs and bans
On a VPS, install MariaDB and create a dedicated user with minimal privileges:
sudo apt install -y mariadb-server
sudo mysql_secure_installation
sudo mysql -u root -p
CREATE DATABASE gmod_rp CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'gmodrp'@'127.0.0.1' IDENTIFIED BY 'long-random-password';
GRANT SELECT, INSERT, UPDATE, DELETE ON gmod_rp.* TO 'gmodrp'@'127.0.0.1';
FLUSH PRIVILEGES;
Bind MySQL to localhost only (bind-address = 127.0.0.1 in /etc/mysql/mariadb.conf.d/50-server.cnf). Never expose port 3306 to the internet for a game server database.
Security practices that actually matter
Volumetric DDoS filtering is handled at infrastructure level on Nexus Games, so your job is the application and system layer:
- RCON: a long random password, rotated whenever a staff member leaves. Never share the RCON password with moderators — give them panel sub-user access instead.
- sv_allowcslua 0 and no unvetted "free leak" addons. Backdoored DarkRP addons are the most common way RP servers get wiped.
- Backups: automatic backups on the panel, plus a manual export of your MySQL database and
darkrpmodificationfolder before every major change. - Update discipline: update srcds after Garry's Mod patches, and test on a staging instance before touching production.
If you run your own VPS, harden the box before opening the server to players:
# local machine
ssh-keygen -t ed25519 -C "gmod-admin"
ssh-copy-id -i ~/.ssh/id_ed25519.pub [email protected]
# on the VPS
sudo sed -i 's/^#\?PasswordAuthentication.*/PasswordAuthentication no/' /etc/ssh/sshd_config
sudo sed -i 's/^#\?PermitRootLogin.*/PermitRootLogin no/' /etc/ssh/sshd_config
sudo systemctl restart ssh
sudo apt install -y ufw fail2ban
sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw allow 22/tcp
sudo ufw allow 27015/tcp
sudo ufw allow 27015/udp
sudo ufw enable
sudo systemctl enable --now fail2ban
sudo fail2ban-client status sshd
Automated restarts and backups
A daily restart clears entity leaks and memory fragmentation. On a VPS, cron does the job:
crontab -e
# nightly restart at 05:00
0 5 * * * /usr/bin/systemctl restart gmod
# daily config + db backup at 04:30
30 4 * * * tar czf /home/gmod/backups/darkrp-$(date +\%F).tar.gz /home/gmod/gmodserver/garrysmod/addons/darkrpmodification /home/gmod/gmodserver/garrysmod/cfg
35 4 * * * mysqldump -u gmodrp -p'long-random-password' gmod_rp | gzip > /home/gmod/backups/db-$(date +\%F).sql.gz
On a managed instance, schedule the restart directly in NexusPanel and rely on the automatic backups, keeping one off-site copy of your Lua configuration in a private Git repository.
Reference documentation
Keep the official Lua API open while you edit jobs and hooks: the Garry's Mod Wiki is the authoritative source for hooks, entity methods and network variables. For anything server-config related, cross-check ConVars there before copying values from a random forum post.
Growing the community
Technically solid is half the work. RP servers retain players through staff availability, clear rules and stable events. A Discord bot hosting instance for ticket handling, ban appeals and player counts is usually the second service an RP community deploys. If you plan to run several communities later, browse All our game servers — the same panel logic applies whether you add a Rust server hosting instance or a Minecraft server hosting network next to your RP project.
Conclusion
A stable RP server comes down to four things: strong single-core CPU, a lean and audited Workshop collection, all customisation isolated in darkrpmodification, and disciplined backups. Get those right and you can iterate on jobs, maps and economy without ever breaking production. Start small, monitor entity counts, and scale slots only when your population actually fills them.
FAQ
What tickrate should I use for a DarkRP server in 2026?22 tick is the pragmatic default for large RP servers: it lowers CPU cost per second and leaves headroom for entities, printers and vehicles. If your gameplay involves frequent gunfights, use 33 tick. Going to 66 on a populated RP server usually causes more frame instability than it solves, because Lua and physics run on a single main thread.
Why do players get stuck downloading content when they join?Almost always a content delivery issue. Verify your Workshop collection is public, that a valid Steam Web API key is passed with -authkey, and that every item is declared with resource.AddWorkshop. For non-Workshop files, check that your sv_downloadurl host serves the .bz2 files over HTTPS with the exact same folder structure as garrysmod/, and that sv_allowdownload 1 is set.
Take a managed instance if you want instant deployment, a live console, file manager, sub-users for staff and automatic backups without Linux administration. Take a VPS if you need full control over srcds flags, your own MySQL, a self-hosted FastDL web server or several instances side by side. A Pterodactyl VPS is a good middle ground: container panel plus root-level freedom.