mcpField
N
nginx-c-module-debug

nginx-c-module-debug

github.com/pproencaDevelopment218249 installsUpdated 11w ago
Repository

About nginx-c-module-debug

A debugging reference skill for developers diagnosing nginx C modules. Its 45 prioritized rules cover crashes, memory faults, request-flow tracing, logging, dynamic tracing, and debugging builds.

Key features

  1. 0145 rules across eight categories
  2. 02Crash and signal diagnosis
  3. 03Memory bug detection
  4. 04GDB and core dump analysis
  5. 05Request-flow tracing
  6. 06Logging, probes, and sanitizer setup

Use cases

  1. 01Investigating nginx worker crashes
  2. 02Diagnosing leaks and memory corruption
  3. 03Tracing request phases and filter chains
  4. 04Setting up GDB or sanitizer-based debugging

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/pproenca/dot-skills --skill nginx-c-module-debug

After installing, type/nginx-c-module-debugin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

metadata.json
assets/templates/
_template.md
references/
_sections.md
build-asan-configure.md
build-debug-flags.md
build-debug-palloc.md
build-single-process.md
build-valgrind-suppressions.md
crash-double-free-finalize.md
crash-error-page-redirect.md
crash-null-deref-pattern.md
crash-segfault-signature.md
crash-stack-overflow.md
crash-worker-exit-log.md
dbglog-debug-connection.md
dbglog-debug-mask.md
dbglog-format-ngx-str.md
dbglog-log-action-string.md
dbglog-memory-buffer.md
gdb-attach-worker.md
gdb-backtrace-read.md
gdb-coredump-setup.md
gdb-inspect-request.md
gdb-memory-buffer-extract.md
gdb-watchpoint-corruption.md
memdbg-buffer-overrun.md
memdbg-cleanup-handler-leak.md
memdbg-pool-leak-pattern.md
memdbg-slab-corruption.md
memdbg-temp-pool-misuse.md

Details

From the project README

nginx.org C Module Debugging Best Practices

Comprehensive debugging guide for nginx C modules, derived from the official nginx development documentation and production debugging experience. Contains 45 rules across 8 categories, prioritized by impact to guide systematic diagnosis of crashes, memory bugs, and behavioral issues in nginx modules.

Companion skills: This skill complements nginx-c-modules (correctness) and nginx-c-module-perf-reliability (performance). This skill covers debugging and diagnosis.

When to Apply

Reference these guidelines when:

  • Diagnosing nginx worker crashes (segfaults, SIGABRT, SIGSEGV)
  • Finding memory bugs (use-after-free, leaks, pool corruption, buffer overruns)
  • Setting up GDB and core dump analysis for nginx
  • Tracing request flow through phases, subrequests, and filter chains
  • Instrumenting nginx modules with debug logging and dynamic tracing tools

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Crash Diagnosis & SignalsCRITICALcrash-
2Memory Bug DetectionCRITICALmemdbg-
3GDB & Core Dump AnalysisHIGHgdb-
4Request Flow TracingHIGHtrace-
5Debug Logging PatternsMEDIUM-HIGHdbglog-
6State & Lifecycle DebuggingMEDIUMstate-
7Dynamic Tracing ToolsMEDIUMprobe-
8Build & Sanitizer ConfigurationLOW-MEDIUMbuild-

Quick Reference

1. Crash Diagnosis & Signals (CRITICAL)
2. Memory Bug Detection (CRITICAL)
3. GDB & Core Dump Analysis (HIGH)
4. Request Flow Tracing (HIGH)
5. Debug Logging Patterns (MEDIUM-HIGH)
6. State & Lifecycle Debugging (MEDIUM)
7. Dynamic Tracing Tools (MEDIUM)
8. Build & Sanitizer Configuration (LOW-MEDIUM)

How to Use

Read individual reference files for detailed explanations and code examples:

Reference Files

FileDescription
references/_sections.mdCategory definitions and ordering
assets/templates/_template.mdTemplate for new rules
metadata.jsonVersion and reference information

Comments

Markdown supported