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.
Cvar
Default
Games
Description
sv_hostname
"Call of Duty Server"
all
Name shown in the browser. Colour codes ^1-^9 work. Set with seta so it persists.
rconpassword
—
CoD 1CoD:UO
Remote console password on CoD1 and United Offensive. One word, no underscore.
rcon_password
—
CoD 2CoD 4CoD:WaW
Remote console password on CoD2, CoD4 and World at War.
g_password
""
all
Server join password. Empty means public.
sv_privatePassword
""
all
Password for the reserved slots counted by sv_privateClients.
sv_privateClients
0
all
Slots reserved for sv_privatePassword holders, taken from sv_maxclients.
sv_maxclients
8
all
Total player slots. Also settable on the command line.
dedicated
0
all
0 listen, 1 LAN dedicated, 2 internet dedicated. Must be 2 for a public server.
net_port
28960
all
UDP port the server binds. Command line only in practice.
Networking and performance
Cvar
Default
Games
Description
sv_fps
20
all
Server tick rate. Snapshot bandwidth per client scales with it; 20 is the sane public default.
sv_maxRate
0
all
Per-client bandwidth cap in bytes/sec. 0 is unlimited, which can saturate the uplink. 25000 is a good public value.
sv_minPing
0
all
Reject clients below this ping. Rarely useful.
sv_maxPing
0
all
Reject clients above this ping. 0 disables.
sv_timeout
240
all
Seconds before a silent client is dropped.
sv_zombietime
2
all
Seconds a disconnected client's slot is held.
sv_floodProtect
1
all
Rate-limits client commands. Also applies to rcon, which is why rapid rcon calls fail.
sv_reconnectlimit
3
all
Seconds before a dropped client may reconnect.
g_antilag
1
all
Lag 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.
Cvar
Default
Games
Description
sv_pure
1
all
Audit client pak checksums and kick on mismatch. Set 0 when loading a mod pak. Unusable on CoD1 1.1.
sv_allowDownload
0
all
Allow the server to send missing paks to clients over the game protocol.
sv_wwwDownload
0
CoD 2CoD 4CoD:WaW
Enable the HTTP redirect download. Not available on CoD1.
sv_wwwBaseURL
""
CoD 2CoD 4CoD:WaW
Root URL clients prefix to the pak path. The web root must mirror the server directory tree.
sv_wwwDlDisconnected
0
CoD 2CoD 4CoD:WaW
1 disconnects the client during download. Keep 0.
sv_fastDownload
0
CoD 1
CodExtended only. Raises UDP download block size from 2 KB to 8 KB.
cl_allowDownload
0
CoD 1
Client-side opt-in. CodExtended flags it CVAR_SYSTEMINFO so a server can propagate it.
fs_game
""
all
Mod directory mounted on top of the gamedir. Must be set on the command line, before the config is executed.
fs_basepath
—
all
Root directory containing the gamedir. Pass explicitly rather than relying on the working directory.
fs_homepath
—
all
Where the server writes logs and downloads. Usually set equal to fs_basepath.
Gameplay rules
Cvar
Default
Games
Description
g_gametype
dm
all
Active gametype code. See the gametype table below.
scr_friendlyfire
0
all
0 off, 1 on, 2 reflect, 3 shared.
scr_killcam
1
all
Show the killcam after death.
scr_teambalance
0
all
Auto-balance teams.
scr_drawfriend
0
CoD 1CoD:UOCoD 2
Show friendly name tags through walls.
g_allowVote
1
all
Allow client callvote. Set 0 when a mod owns map selection.
g_deadChat
0
CoD 1CoD:UOCoD 2
Let dead players chat to the living.
g_forcerespawn
0
all
Seconds until forced respawn. 0 disables.
sv_punkbuster
0
CoD 2CoD 4CoD:WaW
Enable PunkBuster. Leave 0; the infrastructure is unmaintained.
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.
Cvar
Default
Games
Description
scr_<gt>_timelimit
—
all
Minutes, not seconds. On CoD1 a non-zero value is clamped to 1440; 0 means unlimited and is not clamped.
scr_<gt>_scorelimit
—
all
Score at which the map ends.
scr_<gt>_roundlimit
—
all
Round-based gametypes (sd). 0 means unlimited.
scr_<gt>_numlives
—
all
Lives per round in round-based gametypes. 0 is unlimited.
scr_<gt>_waverespawndelay
—
CoD 1CoD:UOCoD 2
Wave respawn interval in seconds. 0 disables wave respawn.
scr_<gt>_playerrespawndelay
—
all
Extra respawn delay in seconds.
Logging
Cvar
Default
Games
Description
g_log
"games_mp.log"
all
Log filename, relative to fs_homepath/<gamedir>.
g_logsync
0
all
1 flushes every line. 0 buffers, which is measurably better on a busy server.
logfile
0
all
Console log. 1 buffered, 2 flushed per line.
sv_showCommands
0
CoD 1CoD:UOCoD 2
Debug: 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.
Cvar
Default
Games
Description
sv_master1
—
all
Primary master server. Blank it only to suppress registration.
sv_master2
—
all
Additional master slots, sv_master2 through sv_master5.
sv_disableClientConsole
0
CoD 4CoD:WaW
Prevent 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.