28960/UDPCall of Duty 2 servers require specific ports to be open for proper operation:
| Port | Protocol | Purpose | Required |
|---|---|---|---|
| 28960 | UDP | Game port (default, configurable) | Yes |
| 28960 | TCP | RCON remote control (optional) | Optional |
| 20500-20510 | UDP | PunkBuster (if enabled) | Optional |
UFW (Ubuntu/Debian):
sudo ufw allow 28960/udp comment 'CoD2 Game Port'
sudo ufw allow 28960/tcp comment 'CoD2 RCON'
sudo ufw allow 20500:20510/udp comment 'CoD2 PunkBuster'
FirewallD (CentOS/RHEL/Fedora):
sudo firewall-cmd --permanent --add-port=28960/udp
sudo firewall-cmd --permanent --add-port=28960/tcp
sudo firewall-cmd --permanent --add-port=20500-20510/udp
sudo firewall-cmd --reload
iptables:
sudo iptables -A INPUT -p udp --dport 28960 -j ACCEPT
sudo iptables -A INPUT -p tcp --dport 28960 -j ACCEPT
sudo iptables -A INPUT -p udp --dport 20500:20510 -j ACCEPT
mkdir -p ~/cod2server
cd ~/cod2serverchmod +x cod2_lnxdedserver.cfg in the main directoryserver.cfg file in the main directoryCoD2MP_s.exe with appropriate parameters// Server Name
set sv_hostname "My Call of Duty 2 Server"
// Network Settings
set net_ip "0.0.0.0"
set net_port 28960
// Server Type (1=LAN, 2=Internet)
set dedicated 2
// Player Limits
set sv_maxclients 32
// RCON Password
set rcon_password "your_secure_password_here"
// Game Settings
set g_gametype "dm" // dm, tdm, sd, ctf, hq, bel
set sv_maxPing 350
set sv_minPing 0
// PunkBuster (0=off, 1=on)
set sv_punkbuster 1
// Map Rotation
set sv_mapRotation "gametype dm map mp_burgundy gametype tdm map mp_toujane gametype sd map mp_carentan"
// Password Protection (leave empty for public)
set g_password ""
// Friendly Fire
set scr_friendlyfire 1
// Kill Cam
set scr_killcam 1
// Game Log
set g_log "games_mp.log"
set g_logsync 1
// Voice Chat
set sv_voice 1
set voice_deadChat 0
set voice_global 0
// Anti-Lag
set sv_fps 20
// Downloads
set sv_allowDownload 1
| Parameter | Description | Example |
|---|---|---|
| +set dedicated | Server mode (1=LAN, 2=Internet) | +set dedicated 2 |
| +set net_ip | Bind to specific IP address | +set net_ip "0.0.0.0" |
| +set net_port | Server port (default: 28960) | +set net_port 28960 |
| +set fs_basepath | Base installation directory | +set fs_basepath "/home/user/cod2" |
| +set fs_homepath | Config and log directory | +set fs_homepath "/home/user/.callofduty2" |
| +set fs_game | Mod folder (if using mods) | +set fs_game "mods/mymod" |
| +set sv_punkbuster | Enable PunkBuster (0=off, 1=on) | +set sv_punkbuster 1 |
| +exec | Execute config file on startup | +exec server.cfg |
| +set rcon_password | RCON password for remote admin | +set rcon_password "secret123" |
| +set sv_maxclients | Maximum player slots | +set sv_maxclients 32 |
| +map_rotate | Start map rotation from server.cfg | +map_rotate |
./cod2_lnxded +set dedicated 2 +set net_ip "0.0.0.0" +set net_port 28960 +set sv_maxclients 32 +set sv_punkbuster 1 +exec server.cfg +map_rotate
CoD2MP_s.exe +set dedicated 2 +set net_ip "0.0.0.0" +set net_port 28960 +set sv_maxclients 32 +set sv_punkbuster 1 +exec server.cfg +map_rotate
Issue: Players cannot see the server in the in-game browser.
Solutions:
+set dedicated 2 is set (not 1 for LAN)ps aux | grep cod2Issue: Dedicated server crashes immediately after launch.
Solutions:
games_mp.log for error messagesserver.cfg syntax is correct (no typos)sudo apt-get install lib32gcc1chmod +x cod2_lnxdedIssue: Players cannot connect or timeout.
Solutions:
sv_maxPing setting (increase if players have high latency)sv_maxclients)set g_password ""Issue: Players experience significant lag.
Solutions:
sv_fps setting (recommended: 20)sv_maxclients if server is overloadedsv_maxPing to restrict high-ping playersIssue: Cannot connect via RCON.
Solutions:
rcon_password is set in server.cfg/rcon login password then /rcon commandCall of Duty 2 supports the following game modes:
Call of Duty 2 includes the following default multiplayer maps:
Popular server modifications compatible with Call of Duty 2:
sv_mapRotation variable with a specific syntax