Diagnoses PostgreSQL performance issues using pg_stat_statements, pg_stat_activity, and the pgbadger log analyzer. Identifies slow queries, lock contention, and bloat via pgstattuple extension.
Scanned 6/8/2026
Install via CLI
openskills install agentskillexchange/skills---
name: "PostgreSQL Diagnostic Runbook"
slug: "postgresql-diagnostic-runbook"
description: "Diagnoses PostgreSQL performance issues using pg_stat_statements, pg_stat_activity, and the pgbadger log analyzer. Identifies slow queries, lock contention, and bloat via pgstattuple extension."
github_stars: 13127
verification: "security_reviewed"
source: "https://github.com/brianc/node-postgres"
category: "Runbooks & Diagnostics"
framework: "ChatGPT Agents"
tool_ecosystem:
github_repo: "brianc/node-postgres"
github_stars: 13127
npm_package: "pg"
npm_weekly_downloads: 23169914
---
# PostgreSQL Diagnostic Runbook
Diagnoses PostgreSQL performance issues using pg_stat_statements, pg_stat_activity, and the pgbadger log analyzer. Identifies slow queries, lock contention, and bloat via pgstattuple extension.
## Installation
Use the upstream install or setup path that matches your environment:
- npm install pg
- From your workspace root run yarn and then yarn lerna bootstrap
- Run yarn test to run all the tests.
Requirements and caveats from upstream:
- # node-postgres
- 
- Non-blocking PostgreSQL client for Node.js. Pure JavaScript and optional native libpq bindings.
Basic usage or getting-started notes:
- ## Documentation
- Each package in this repo should have its own readme more focused on how to develop/contribute. For overall documentation on the project and the related modules managed by this repo please see:
- ### Features
- Source: https://github.com/brianc/node-postgres
- Extracted from upstream docs: https://raw.githubusercontent.com/brianc/node-postgres/HEAD/README.md
## Source
- [Agent Skill Exchange](https://agentskillexchange.com/skills/postgresql-diagnostic-runbook/)
No comments yet. Be the first to comment!
Ultra-compressed communication mode. Cuts token usage ~75% by speaking like caveman while keeping full technical accuracy. Supports intensity levels: lite, full (default), ultra, wenyan-lite, wenyan-full, wenyan-ultra. Use when user says "caveman mode", "talk like caveman", "use caveman", "less tokens", "be brief", or invokes /caveman. Also auto-triggers when token efficiency is requested.