Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

mysql-aiops

БесплатноБез исполняемых скриптовНе проверен

Use this skill whenever the user needs to operate or troubleshoot a MySQL 8.x or MariaDB 10.6+ server as a DBA — a one-shot server health overview (version +…

zw008от zw0081 824 установки в других каталогах

Об этом скилле

MySQL AIops

Audit availability: Real writes require a durable audit intent. Reads and previews can continue if audit storage fails; check the warning and audit health before relying on their audit trail.

Disclaimer: Community-maintained open-source project, not affiliated with, endorsed by, or sponsored by Oracle Corporation or the MariaDB Foundation. "MySQL" and "MariaDB" trademarks belong to their owners. Source at github.com/AIops-tools/MySQL-AIops under the MIT license.

Governed MySQL / MariaDB DBA operations — 35 MCP tools, every one wrapped with the bundled @governed_tool harness: a local unified audit log under ~/.mysql-aiops/, token/runaway budget guard, undo-token recording, and descriptive risk-tier labels. The account password is stored encrypted (~/.mysql-aiops/secrets.enc, Fernet + scrypt) — never plaintext on disk.

Standalone: the governance harness is bundled in the package (mysql_aiops.governance) — mysql-aiops has no external skill-family dependency. Behaviour is covered by a mock-based test suite; docs/VERIFICATION.md is the checklist for a live run against a real MySQL / MariaDB server.

What This Skill Does

Domain Tools Count Read or Write
Overview server health snapshot (version+flavor, connections, replica role) 1 1 read
Server version+flavor, variables, status, databases, engines, connection stats 6 6 read
Activity sessions, long-running queries, transactions, lock waits 4 4 read
Queries top-N statement digests, EXPLAIN FORMAT=JSON 2 2 read
Indexes unused, redundant/duplicate, cardinality stats 3 3 read
Tables sizes, data_free fragmentation, engine/row-format status 3 3 read
Replication replica status/lag, binlog/GTID 2 2 read
Analysis (flagship) slow-query RCA, lock-wait & deadlock RCA, replication-lag RCA, fragmentation 4 4 read
Writes kill-session, kill-query, drop-index 3 3 write (high)
optimize, analyze-table, create-index, SET GLOBAL, reset-stats 5 5 write (medium)
Undo undo list, undo apply 2 1 read / 1 write

The flagship analyses accept injected records for pure/offline analysis, or pull live from a configured target. top_queries / slow_query_rca require performance_schema=ON; the read account should have PROCESS, REPLICATION CLIENT and SELECT on performance_schema.

Quick Install

uv tool install mysql-aiops
mysql-aiops init       # interactive wizard: connection + encrypted password
mysql-aiops doctor     # connectivity + flavor + performance_schema + replica role

Or as an OpenClaw plugin, which installs this skill and its MCP server together:

openclaw plugins install clawhub:@zw008/mysql-aiops
openclaw skills info mysql-aiops          # expect: Visible to model: yes

Needs uvx on PATH: the MCP server is fetched with uv, pinned to this release.

When to Use This Skill

  • Triage a server (overview): version + flavor, uptime, connection headroom, sessions by command, longest query, most fragmented table, replica role
  • Root-cause a slow query (analyze slow-query / slow_query_rca): the worst statement digest + EXPLAIN → cited cause and action (full scan, lock-time dominant, tmp-disk spill, N+1)
  • Untangle a lock pile-up or deadlock (analyze lock-waits / lock_wait_rca): the wait-for tree with the root blocker named + the last deadlock parsed from SHOW ENGINE INNODB STATUS
  • Diagnose replication (analyze replication / replication_lag_rca): IO/SQL thread state, Seconds_Behind_Source, error fields → cause + action
  • Decide what to OPTIMIZE (analyze fragmentation / fragmentation_analysis): tables ranked by reclaimable data_free
  • Find unused / redundant indexes; check table sizes and engines; inspect binlog/GTID state
  • Kill a session or its query, OPTIMIZE/ANALYZE a table, create/drop an index (reversible), or SET GLOBAL a variable — all with dry-run + double-confirm

Do NOT use for PostgreSQL — use postgres-aiops. Do NOT use when the target is OT/industrial equipment (use industrial-aiops), a hypervisor, a storage appliance, a backup product, or a container cluster.

Related Skills — Skill Routing

If the user wants… Use
MySQL / MariaDB DBA-ops: slow queries, lock waits, replication, fragmentation mysql-aiops (this skill)
PostgreSQL DBA-ops postgres-aiops
OT / industrial edge (Modbus, OPC-UA, PLC, PROFINET) the industrial-aiops line
Hypervisor VM lifecycle (power, snapshot, migrate) a hypervisor ops skill
Container/cluster lifecycle a cluster ops skill

Common Workflows

1. "The application is slow" — from complaint to a working index

  1. mysql-aiops doctor → connectivity, detected flavor, and whether `performance_schem
Полный SKILL.md на ClawHub

Установить mysql-aiops в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Bash

FAQ

Что делает скилл mysql-aiops?

Use this skill whenever the user needs to operate or troubleshoot a MySQL 8.x or MariaDB 10.6+ server as a DBA — a one-shot server health overview (version + flavor, connection headroom, replica role); server reads (global variables, status counters, databases, storage engines); activity (sessions/processlist, long-running queries, open InnoDB transactions, lock waits); query stats (performance_schema statement-digest top-N, EXPLAIN FORMAT=JSON); index health (unused indexes, redundant/duplicate indexes, cardinality); table health (sizes, data_free fragmentation, engine/row-format status); replication (replica IO/SQL thread state and lag, binlog/GTID status); four flagship analyses — slow-query RCA (worst digest + EXPLAIN → cited cause/action incl. full-scan and lock-time-dominant classification), InnoDB lock-wait & deadlock chain RCA (wait-for tree, root blocker, last deadlock parsed from SHOW ENGINE INNODB STATUS), replication lag RCA (thread state/error fields → cause+action), and table fragmentation analysis (data_free → OPTIMIZE candidates); and guarded writes (kill a session or query, OPTIMIZE/ANALYZE TABLE, create/drop an index, SET GLOBAL a variable, reset digest stats). Always use this skill for "mysql health check", "why is this query slow", "top queries by time", "EXPLAIN this", "table fragmentation", "which indexes are unused", "redundant index", "who is blocking whom", "deadlock", "kill the session holding the lock", "replication lag", "replica stopped", "seconds behind master/source", "OPTIMIZE this table", "create/drop an index", or "SET GLOBAL max_connections" when the context is a MySQL or MariaDB database. Do NOT use for PostgreSQL — use postgres-aiops. Do NOT use when the target is OT / industrial equipment (use industrial-aiops), a hypervisor, a storage appliance, a backup product, or a container/cluster orchestrator (negative routing hints only). Common MySQL/MariaDB DBA operations with a built-in governance harness (audit, policy, token budget,

Как установить скилл mysql-aiops?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл mysql-aiops запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить mysql-aiops с