Performance Optimization and Debugging
Master application performance monitoring, tracing, and debugging techniques to identify bottlenecks and optimize system efficiency.
Articles in Performance Optimization and Debugging
-
How to debug C/C++ → gdb
Master C/C++ debugging with GDB using process IDs. Learn step-by-step how to attach GDB to running processes, debug applications effectively, and troubleshoot issues.
-
How to view slab/cache → slabtop
Learn how to monitor Linux kernel slab cache with slabtop command. Complete guide covering installation, usage, interpretation, and troubleshooting for system administrators.
-
How to tweak kernel params → sysctl -a; sysctl -w net.ipv4.ip_forward=1
Learn to tweak Linux kernel parameters using sysctl commands. Complete guide covering sysctl -a, temporary/permanent changes, IP forwarding, and optimization.
-
How to show CPU/mem stats → vmstat, mpstat, pidstat, dstat
Master Linux system monitoring with vmstat, mpstat, pidstat, and dstat. Complete guide with examples, troubleshooting, and best practices for CPU/memory analysis.
-
How to watch bandwidth per iface → iftop or nload
Learn how to monitor network bandwidth per interface using iftop and nload tools. Complete guide with installation, usage, examples, and troubleshooting tips.
-
How to watch I/O usage → iotop
Learn how to monitor disk I/O usage with iotop command. Complete guide covering installation, usage, options, and troubleshooting for Linux system administrators.
-
How to profile perf counters → perf stat
; perf record ...; perf report Master Linux performance profiling with perf counters. Learn perf stat, perf record, and perf report commands with practical examples and troubleshooting tips.
-
How to trace library calls → ltrace
Learn how to trace library calls using ltrace command. Complete guide with examples, troubleshooting, and best practices for debugging applications effectively.
-
How to trace syscalls → strace -p
; strace -o out.txt Learn how to trace system calls using strace command with process IDs and output files. Master debugging techniques for Linux system monitoring and troubleshooting.
-
How to see who uses a file → fuser -v
Learn how to use the fuser command with -v option to identify which processes and users are accessing files in Linux. Complete guide with examples and troubleshooting.
-
How to list open files/ports → lsof; lsof -i :443
Master the lsof command to list open files and ports on Linux/Unix systems. Learn syntax, practical examples, troubleshooting, and advanced techniques for system monitoring.
-
How to map process memory → pmap
Learn how to map and analyze process memory using pmap command. Complete guide with examples, troubleshooting, and advanced techniques for system administrators.
-
How to kill by pattern → pkill
Master the pkill command to terminate processes by pattern matching. Learn syntax, options, examples, and best practices for efficient Linux process management.
-
How to find PIDs by name → pgrep
Learn how to find process IDs by name using pgrep command. Complete guide with examples, advanced options, troubleshooting tips for Linux system administrators.
-
How to show per‑process tree → pstree -p
Learn how to use pstree -p command to display process trees with PIDs. Complete guide with examples, troubleshooting, and advanced techniques for system monitoring.