OS Debugging & Capstone
High CPU, high memory, hangs, too many open files: the diagnosis playbook, and the capstone — explain a 50,000-connection server layer by layer, then diagnose what was injected.
High CPU, high memory, a hang and “too many open files” are the four symptoms the OS shows you; each hides three or four different causes with different fixes, and each cause has one observation — user vs system time, RSS vs virtual, `D` vs `S` state, what the descriptors are — that tells it apart from its neighbours.
Explain, layer by layer, how a Node.js, Python or C++ server holds 50,000 open connections — process, threads or event loop, sockets, descriptors, per-connection memory, the scheduler, system calls, the kernel network stack, buffers, the I/O model and CPU — then diagnose the five faults the simulator injects.