How to Debug a CS 1.6 Server That Crashes with No Error

March 12, 2026 Daemon666 8 min read 13 Aufrufe

A server that crashes and simply disappears — no console error, no log line, the process gone — is the hardest kind to fix because there is nothing to paste into a search box. The trick is to stop guessing and generate real evidence: turn on the engine's debug crash log, then narrow the cause by bisecting your add-ons. This is the process that actually finds it.

1. Capture a backtrace with -debug (Linux)

The Linux dedicated server launcher, hlds_run, has a built-in crash handler. Start it with -debug and, when the game binary crashes, it writes a gdb backtrace to debug.log in the server directory:

./hlds_run -debug -game cstrike +map de_dust2 +maxplayers 20

After a crash, open debug.log. The bottom of the file holds the crash time, the signal (usually SIGSEGV, a segmentation fault), and a stack trace. Even if the symbols are partial, the trace usually names the module at fault — the engine itself, metamod, or an AMXX module — which points you at the right area immediately.

2. Enable core dumps for a deeper look

If debug.log is not enough, allow the OS to write a core file before launching:

ulimit -c unlimited
./hlds_run -debug -game cstrike +map de_dust2

A core file appears after the crash. Load it in gdb against the game binary to read the full stack:

gdb ./hlds_linux core
(gdb) bt full

You do not need to be a C++ programmer — you are looking for the first recognisable name in the trace (a module .so, a plugin) to know where to point the bisection.

3. Read the AMXX and Metamod logs

Before bisecting, check the logs that do get written. AMXX logs run-time errors per map under addons/amxmodx/logs/, and Metamod issues show in the main server log. A plugin throwing a Run time error just before the crash is your prime suspect. Confirm what actually loaded:

meta list
amxx plugins

Anything marked bad load or a module that failed is a lead. See plugins.ini load order for reading that output.

4. Bisect the plugins

Silent crashes are very often a single misbehaving AMXX plugin or Metamod module. Narrow it by halving:

  1. Comment out the bottom half of plugins.ini (prefix lines with ;), change map, and see if it still crashes.
  2. If it stops, the culprit was in the disabled half — re-enable half of that, repeat.
  3. If it still crashes, the fault is in the enabled half (or in Metamod / a module, not a plugin). Move to disabling Metamod modules in metamod's plugins.ini.

A handful of map changes isolates one line. Run that suspect plugin in debug mode to get a precise trace:

myplugin.amxx debug

5. Rule out the obvious triggers

If the crash correlates with an event, the cause is narrower than a random fault:

  • Crashes on a specific map — a corrupt or oversized .bsp, or a plugin that trips on that map's entities. Test the map alone.
  • Crashes on map change only — a plugin's map-end handler, or a bad mapcycle entry pointing at a missing map.
  • Crashes under player load — a memory or rate issue; watch it fill up and note the count at which it dies.
  • Crashes at a fixed time — a cron-like task or a scheduled plugin action.

Troubleshooting

  • No debug.log appears — you launched the binary directly instead of through hlds_run -debug. The crash handler lives in the launcher script.
  • No core fileulimit -c is 0 in that shell, or the working directory is not writable. Set ulimit -c unlimited in the same session that launches the server.
  • Backtrace is all ?? — stripped binaries; you still get the module boundaries, which is enough to bisect. Focus on which .so appears.
  • Disabling all plugins stops the crash — it is an add-on, not the engine. Bisect back in.
  • Crash persists with everything disabled — engine, mod DLL, or OS. Consider moving to ReHLDS, which is more stable and better instrumented than legacy HLDS.

Verification

Once you suspect a specific plugin or module, remove only that one, restart, and run the server through the exact conditions that killed it before — the same map, the same player load, the same map change. If it survives a full cycle that previously crashed it reliably, you have your culprit. Re-enable everything else to confirm the rest is innocent, then either update or replace the offending add-on. Keep -debug on until you have gone a full day without a crash.

Mitwirkende: Daemon666 ✦
Teilen: