Your ban files are full of entries, but banned players walk right back in after a restart. The reason surprises people: the CS 1.6 engine does not automatically read the ban files at startup. It writes them, but it only loads them if you explicitly exec them — and the default server.cfg often does not. This covers which file holds what, and the exact lines that make bans load on boot.
1. Know which file holds which ban
There are two independent engine ban lists, saved to two files:
| Ban type | Added with | Saved with | File |
|---|---|---|---|
| SteamID | banid | writeid | banned.cfg (some builds banned_user.cfg) |
| IP | addip | writeip | listip.cfg |
The two are separate. Clearing or loading one does nothing to the other — a point covered in IP bans vs SteamID bans. Note the SteamID filename varies by engine build, which is exactly why the wrong exec line silently loads nothing.
2. Confirm the files exist and where
The files live in the game directory, cstrike/ — the same folder as server.cfg, not the Half-Life root and not a subfolder. List them:
ls -l cstrike/banned.cfg cstrike/banned_user.cfg cstrike/listip.cfg
Whichever SteamID file is non-empty is the one your build writes to. That is the one you must exec. If none exist yet, the engine creates them the first time you run writeid / writeip, so ban one test account and save it before assuming the files are simply missing — an empty directory just means nothing has been written and saved yet, not that the feature is broken.
3. Add the exec lines to server.cfg
The engine reads these lists only when told to. Add the matching lines to the top of server.cfg so they load on every boot:
exec listip.cfg exec banned.cfg
If your build wrote to banned_user.cfg, exec that name instead:
exec listip.cfg exec banned_user.cfg
Match the filename to whichever file step 2 showed as populated. An exec of a name the engine never wrote to loads an empty list and the bans stay dormant.
4. Reload them without a restart
You do not have to reboot to apply the lists — run the same execs live from rcon or the console:
exec banned.cfg exec listip.cfg
Then confirm the lists are populated in memory:
listid listip
listid prints every loaded SteamID ban, listip every IP ban. If they are populated after the exec, the file is fine and the only missing piece was the startup exec.
5. Where in server.cfg to put the exec
Order matters a little. Put the exec lines near the top of server.cfg, before any plugin-related configuration, so the engine's ban lists are populated early in the boot. It does no harm to exec them late, but keeping them at the top makes the intent obvious to the next admin who reads the file and avoids a window where the server is up but the ban list is not yet loaded. If you manage bans through a plugin ban system as well, be aware that the plugin may maintain its own list and re-sync it into the engine on map change — in that setup the engine files and the plugin's store must agree, or a ban you removed from one reappears from the other. For a single-server box using only the engine lists, two exec lines at the top of server.cfg are the whole solution.
6. Keep the files backed up
The ban files are plain text and easy to lose in a redeploy. Include banned.cfg, banned_user.cfg and listip.cfg in whatever you back up, as covered in backing up configs, bans and stats, so a fresh install does not silently wipe months of bans.
Common errors
- Bans present in the file but not enforced after boot — no
execline inserver.cfg. Add it. - exec runs but listid stays empty — you exec the wrong filename; your build uses the other one. Exec the populated file.
- File is empty despite banning — you never ran
writeid/writeipto save; see bans not persisting. - Loads on Windows, not on Linux — filename case. Linux is case-sensitive; match
banned.cfgexactly. - server.cfg itself is not running — then no exec fires at all; see server.cfg not executing.
Verification
Add the exec lines, restart the server, and immediately run listid and listip in the console. Both should list the entries from your files. Then reconnect a banned test SteamID — it must be refused at connect. If the lists are populated after a cold boot without you touching anything, the engine is loading the files and the bans are durable. If listid is empty after boot, the exec is missing or pointed at the wrong filename.









