> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vortexiq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# MySQL audit profile, Vortex IQ

> What the Vortex IQ MySQL health audit checks: MySQL: keep queries fast, replicas honest, and storage safe

**[Nerve Centre KPIs](/nerve-centre/kpi-cards/mysql) · [Audit Profile](/nerve-centre/kpi-cards/mysql/audit) · [Sentiment Settings](/nerve-centre/kpi-cards/mysql/sentiment)**

MySQL-specific health audit for production 5.7 / 8.0 instances. Answers six questions: (1) is access correctly scoped and is performance\_schema actually readable; (2) is the instance reachable with a healthy connection pool and low aborted-connect noise; (3) is query latency within band and is the slow-query digest list under control; (4) are replicas streaming with both threads running and Seconds\_Behind\_Source inside threshold; (5) is disk and buffer-pool capacity healthy; (6) is a recent durable backup in place. Cross-channel area joins query and pool pressure to commerce-sibling checkout traffic to size live revenue at risk.

## What this audit checks

### Authentication & access

* Connection succeeds over the configured connection\_string with SSL mode honoured on managed endpoints (RDS / Aurora / PlanetScale / Cloud SQL)
* Audit user holds SELECT on performance\_schema plus REPLICATION CLIENT and PROCESS (else replication and digest checks degrade to skipped)
* performance\_schema is enabled (SHOW VARIABLES LIKE 'performance\_schema') so events\_statements\_summary\_by\_digest returns rows
* sys schema installed for friendlier digest labels; warn when absent

### Connection & availability

* Instance reachable and SHOW GLOBAL STATUS returns within timeout; Uptime > 0 confirms no recent unplanned restart
* Connection pool saturation (Threads\_connected / max\_connections) below threshold with headroom for traffic bursts
* Aborted\_connects over 24h below threshold (spikes signal wrong creds, network drops, or max\_connect\_errors hit)
* Threads\_running not pinned high relative to Threads\_connected (sign of query pile-up / stalls)

### Query performance

* Query latency p95 (derived from events\_statements\_summary\_by\_digest AVG\_TIMER\_WAIT) within threshold
* Slow-query rate (Slow\_queries delta / Questions delta from SHOW GLOBAL STATUS) below threshold over a 15m window
* Top-10 slow digests reviewed; no new digest entering the list with high rows\_examined / rows\_returned ratio
* InnoDB deadlocks (SHOW ENGINE INNODB STATUS) at zero over the last 5m

### Replication & lag

* Both Replica\_IO\_Running and Replica\_SQL\_Running are Yes on every replica (SHOW REPLICA STATUS / SHOW SLAVE STATUS on \< 8.0.22)
* Seconds\_Behind\_Source within lag threshold and not null on any active replica
* Active replica count matches expected topology; no replica in BROKEN or STOPPED state
* Binlog backlog ahead of the slowest replica position below threshold (growing backlog = replica falling behind)

### Storage & capacity

* Database disk usage percent below threshold with runway before the volume fills
* InnoDB buffer pool hit rate (1 - Innodb\_buffer\_pool\_reads / Innodb\_buffer\_pool\_read\_requests) above threshold
* InnoDB dirty pages percent below threshold to avoid checkpoint pressure and write storms
* InnoDB free pages above the floor (> 1% of total pages) so the pool is not starved

### Backups & durability

* Last successful backup age (mysqldump / Percona XtraBackup / RDS snapshot) within freshness threshold
* binlog\_expire\_logs\_seconds / expire\_logs\_days set so point-in-time recovery has a usable window
* Binary logging enabled (log\_bin = ON) where PITR or replication is required
* innodb\_flush\_log\_at\_trx\_commit = 1 and sync\_binlog = 1 for durable-by-default writes (warn on relaxed settings)

### Cross-channel: revenue protection

* QPS spike with no matching order spike (sibling = bigcommerce/shopify/adobe orders\_per\_15m flat while mysql.qps surges = bot / scraper load)
* Pool saturation during traffic burst (sibling = commerce checkout volume rising while Threads\_connected / max\_connections crosses threshold = lost orders)
* Slow queries co-occurring with checkout drop (mysql.slow\_query in same 5m window as sibling.checkout\_step\_completion\_rate falling > 5pp)
* Inventory-table row drift vs ecom inventory count (mysql merchant-owned schema row count vs sibling.product\_inventory by sku = oversell risk)

## Severity thresholds

| Signal                  | Warn | Critical |
| ----------------------- | ---- | -------- |
| `connection_error_rate` | 0.5  | 1        |
| `query_p95_ms`          | 200  | 500      |
| `replication_lag_sec`   | 10   | 30       |
| `disk_usage_pct`        | 80   | 90       |
| `slow_query_count`      | 5    | 20       |

## Data sources

* `GET mysql://{host}:{port}/{database} :: SHOW VARIABLES` - Instance config: version, max\_connections, performance\_schema, buffer-pool size, binlog settings
* `GET mysql://{host}:{port}/{database} :: SHOW GLOBAL STATUS` - Live counters: Questions, Slow\_queries, Threads\_connected/running, Aborted\_connects, Uptime, InnoDB buffer-pool reads
* `GET mysql://{host}:{port}/{database} :: performance_schema.events_statements_summary_by_digest` - Per-digest latency (p50/p95/p99), rows\_examined, rows\_returned for slow-query analysis
* `GET mysql://{host}:{port}/{database} :: performance_schema.processlist` - Live connection / thread inventory and pool occupancy by app\_name
* `GET mysql://{host}:{port}/{database} :: SHOW REPLICA STATUS` - Replica thread state and Seconds\_Behind\_Source (SHOW SLAVE STATUS on \< 8.0.22)
* `GET mysql://{host}:{port}/{database} :: SHOW ENGINE INNODB STATUS` - InnoDB deadlocks, buffer-pool dirty/free pages, checkpoint pressure
