What problem does it solve?
Investigating MySQL or MariaDB incidents requires jumping between ad-hoc SQL commands to understand schemas, find slow queries, and check replication health. This Skill provides a structured, schema-first workflow with safe read-only scripts so you can diagnose database problems quickly without risking data modification.
Core Features & Use Cases
- Schema Discovery: List all tables with size and engine stats, then describe columns, indexes, and foreign keys before writing queries.
- Safe Query Execution: Run read-only SQL (SELECT, SHOW, EXPLAIN, DESCRIBE) with automatic row limits and built-in blocking of DML/DDL statements.
- Health Diagnostics: Inspect the processlist for long-running queries, check InnoDB engine status for deadlocks and lock waits, and monitor replication lag with a computed health status.
- Use Case: During an incident where the app reports slow database responses, run show_processlist.py to find long-running queries, then get_table_locks.py to identify lock contention blocking transactions.
Quick Start
Ask the agent to list the tables in the MySQL database and check for any long-running queries or lock contention.