Server cvar reference

The cvars worth setting on a Call of Duty dedicated server, which games each applies to, and the places where the same setting is spelled differently between titles.

The three that cost people the most time: the rcon cvar is rconpassword on CoD1/UO but rcon_password on CoD2 and later; Team Deathmatch is tdm on CoD1/UO/CoD2 but war on CoD4 and WaW; and timelimits are in minutes, not seconds.

Server identity and access

The rcon cvar is spelled differently per game and this is the single most common configuration mistake when moving a config between titles.

CvarDefaultGamesDescription
sv_hostname"Call of Duty Server"allName shown in the browser. Colour codes ^1-^9 work. Set with seta so it persists.
rconpasswordCoD 1CoD:UORemote console password on CoD1 and United Offensive. One word, no underscore.
rcon_passwordCoD 2CoD 4CoD:WaWRemote console password on CoD2, CoD4 and World at War.
g_password""allServer join password. Empty means public.
sv_privatePassword""allPassword for the reserved slots counted by sv_privateClients.
sv_privateClients0allSlots reserved for sv_privatePassword holders, taken from sv_maxclients.
sv_maxclients8allTotal player slots. Also settable on the command line.
dedicated0all0 listen, 1 LAN dedicated, 2 internet dedicated. Must be 2 for a public server.
net_port28960allUDP port the server binds. Command line only in practice.

Networking and performance

CvarDefaultGamesDescription
sv_fps20allServer tick rate. Snapshot bandwidth per client scales with it; 20 is the sane public default.
sv_maxRate0allPer-client bandwidth cap in bytes/sec. 0 is unlimited, which can saturate the uplink. 25000 is a good public value.
sv_minPing0allReject clients below this ping. Rarely useful.
sv_maxPing0allReject clients above this ping. 0 disables.
sv_timeout240allSeconds before a silent client is dropped.
sv_zombietime2allSeconds a disconnected client's slot is held.
sv_floodProtect1allRate-limits client commands. Also applies to rcon, which is why rapid rcon calls fail.
sv_reconnectlimit3allSeconds before a dropped client may reconnect.
g_antilag1allLag compensation. Leave on.

Content and downloads

sv_pure and sv_allowDownload are independent settings that are frequently confused. The full behaviour matrix is in the fast download guide.

CvarDefaultGamesDescription
sv_pure1allAudit client pak checksums and kick on mismatch. Set 0 when loading a mod pak. Unusable on CoD1 1.1.
sv_allowDownload0allAllow the server to send missing paks to clients over the game protocol.
sv_wwwDownload0CoD 2CoD 4CoD:WaWEnable the HTTP redirect download. Not available on CoD1.
sv_wwwBaseURL""CoD 2CoD 4CoD:WaWRoot URL clients prefix to the pak path. The web root must mirror the server directory tree.
sv_wwwDlDisconnected0CoD 2CoD 4CoD:WaW1 disconnects the client during download. Keep 0.
sv_fastDownload0CoD 1CodExtended only. Raises UDP download block size from 2 KB to 8 KB.
cl_allowDownload0CoD 1Client-side opt-in. CodExtended flags it CVAR_SYSTEMINFO so a server can propagate it.
fs_game""allMod directory mounted on top of the gamedir. Must be set on the command line, before the config is executed.
fs_basepathallRoot directory containing the gamedir. Pass explicitly rather than relying on the working directory.
fs_homepathallWhere the server writes logs and downloads. Usually set equal to fs_basepath.

Gameplay rules

CvarDefaultGamesDescription
g_gametypedmallActive gametype code. See the gametype table below.
scr_friendlyfire0all0 off, 1 on, 2 reflect, 3 shared.
scr_killcam1allShow the killcam after death.
scr_teambalance0allAuto-balance teams.
scr_drawfriend0CoD 1CoD:UOCoD 2Show friendly name tags through walls.
g_allowVote1allAllow client callvote. Set 0 when a mod owns map selection.
g_deadChat0CoD 1CoD:UOCoD 2Let dead players chat to the living.
g_forcerespawn0allSeconds until forced respawn. 0 disables.
sv_punkbuster0CoD 2CoD 4CoD:WaWEnable PunkBuster. Leave 0; the infrastructure is unmaintained.
pb_sv_guidRelax0CoD 2CoD 4CoD:WaWRelaxes PunkBuster GUID enforcement, reducing false kicks.

Per-gametype limits

Limit cvars are prefixed with the gametype code, so the timelimit for Team Deathmatch on CoD2 is scr_tdm_timelimit and on CoD4 it is scr_war_timelimit. Setting the wrong prefix does nothing at all, silently.

CvarDefaultGamesDescription
scr_<gt>_timelimitallMinutes, not seconds. On CoD1 a non-zero value is clamped to 1440; 0 means unlimited and is not clamped.
scr_<gt>_scorelimitallScore at which the map ends.
scr_<gt>_roundlimitallRound-based gametypes (sd). 0 means unlimited.
scr_<gt>_numlivesallLives per round in round-based gametypes. 0 is unlimited.
scr_<gt>_waverespawndelayCoD 1CoD:UOCoD 2Wave respawn interval in seconds. 0 disables wave respawn.
scr_<gt>_playerrespawndelayallExtra respawn delay in seconds.

Logging

CvarDefaultGamesDescription
g_log"games_mp.log"allLog filename, relative to fs_homepath/<gamedir>.
g_logsync0all1 flushes every line. 0 buffers, which is measurably better on a busy server.
logfile0allConsole log. 1 buffered, 2 flushed per line.
sv_showCommands0CoD 1CoD:UOCoD 2Debug: print client commands. Very noisy.

Master server

Leave these alone for a public server. Configs copied from private servers often blank them, which is how a server ends up invisible with everything else correct.

CvarDefaultGamesDescription
sv_master1allPrimary master server. Blank it only to suppress registration.
sv_master2allAdditional master slots, sv_master2 through sv_master5.
sv_disableClientConsole0CoD 4CoD:WaWPrevent clients opening the console.

Gametype codes

Set with g_gametype and used as the gametype token inside sv_mapRotation. Limit cvars take the code as a prefix, so Team Deathmatch on CoD2 is scr_tdm_timelimit and on CoD4 it is scr_war_timelimit.

CodeGametypeGames
dmDeathmatch / Free-for-Allall
tdmTeam DeathmatchCoD 1CoD:UOCoD 2
warTeam DeathmatchCoD 4CoD:WaW
sdSearch and Destroyall
hqHeadquartersCoD 1CoD:UOCoD 2
kothHeadquartersCoD 4CoD:WaW
sabSabotageCoD 4CoD:WaW
domDominationCoD:UOCoD 4CoD:WaW
ctfCapture the FlagCoD:UOCoD 2CoD:WaW
belBehind Enemy LinesCoD 1CoD:UO
reRetrievalCoD 1CoD:UO
basBase AssaultCoD:UO
twarWarCoD:WaW

Build a complete config from these with the server.cfg generator.