---
title: "Requirements and overhead | Database Observability documentation"
description: "System requirements and performance overhead for Database Observability."
---

# Requirements and overhead

Review system requirements, database permissions, and performance impact before setting up Database Observability. This page covers what you need to run Alloy, what access your monitoring user requires, and how much overhead to expect on your databases.

## System requirements

### Grafana Cloud

Expand table

| Requirement | Details                                                                            |
|-------------|------------------------------------------------------------------------------------|
| Account     | Grafana Cloud account with Editor or Admin role                                    |
| Stack       | Access to Grafana Cloud Mimir (metrics) and Grafana Cloud Loki (logs) data sources |
| Permissions | Ability to view and create dashboards                                              |

### Grafana Alloy

Expand table

| Requirement     | Details                                     |
|-----------------|---------------------------------------------|
| Version         | Grafana Alloy `1.15.0` or later             |
| Network         | Outbound access to Grafana Cloud endpoints  |
| Database access | Network connectivity to monitored databases |

### PostgreSQL requirements

Expand table

| Requirement          | Minimum version | Notes                                                     |
|----------------------|-----------------|-----------------------------------------------------------|
| PostgreSQL           | 14              | PostgreSQL 13 and earlier are not supported               |
| `pg_stat_statements` | Required        | Extension must be installed and enabled; requires restart |
| Monitoring user      | Required        | User with `pg_monitor` and `pg_read_all_stats` roles      |

For detailed configuration and permission setup, refer to [Set up PostgreSQL](/docs/grafana-cloud/monitor-applications/database-observability/set-up/postgres/).

### MySQL requirements

Expand table

| Requirement          | Minimum version | Notes                                                                                      |
|----------------------|-----------------|--------------------------------------------------------------------------------------------|
| MySQL                | 8.0             | MySQL 5.7 and earlier are not supported                                                    |
| MariaDB              | Not supported   | `Performance Schema` implementation differs from MySQL                                     |
| `Performance Schema` | Required        | Enabled by default in MySQL 8.0+                                                           |
| Monitoring user      | Required        | User with `PROCESS`, `REPLICATION CLIENT`, and `SELECT` privileges on `performance_schema` |

For detailed configuration and permission setup, refer to [Set up MySQL](/docs/grafana-cloud/monitor-applications/database-observability/set-up/mysql/).

## Performance overhead

Database Observability is designed to minimize impact on your production databases. Understanding the overhead helps you make informed decisions about collection intervals and features.

### Database query overhead

The monitoring queries executed by Alloy are lightweight read operations:

Expand table

| Query type                 | Database   | Notes                           |
|----------------------------|------------|---------------------------------|
| `pg_stat_statements`       | PostgreSQL | Reads cached statistics         |
| `pg_stat_activity`         | PostgreSQL | Reads active session info       |
| `Performance Schema`       | MySQL      | Reads cached statistics         |
| Query samples (MySQL)      | MySQL      | Captures running queries        |
| Query samples (PostgreSQL) | PostgreSQL | Captures running queries        |
| Schema details             | Both       | Cached, reads metadata          |
| Explain plans              | Both       | Runs EXPLAIN on sampled queries |

**Explain plan considerations:**

Explain plans execute `EXPLAIN` (not `EXPLAIN ANALYZE`) on sampled queries. This operation:

- Does not execute the query
- Uses cached statistics to estimate costs
- Has minimal overhead for most queries
- Can be disabled if needed via collector configuration

### Reduce overhead

If you need to reduce monitoring overhead:

1. **Increase collection intervals**: Change `collect_interval` from 1 minute to 5 minutes
2. **Reduce explain plan sampling**: Set `explain_plans.per_collect_ratio` to `0.5` or lower
3. **Exclude schemas**: Use `exclude_schemas` (MySQL) or `exclude_databases` (PostgreSQL) to skip non-critical databases

## Checklist before setup

Before proceeding with setup, verify:

- Grafana Cloud account is active with appropriate permissions
- Database version meets minimum requirements
- Required extensions/features are enabled (`pg_stat_statements`, `Performance Schema`)
- Network connectivity exists between Alloy location and databases
- Network connectivity exists between Alloy location and Grafana Cloud
- Monitoring user credentials are ready
- Database team is aware of monitoring overhead expectations

## Related documentation

- [Set up PostgreSQL](/docs/grafana-cloud/monitor-applications/database-observability/set-up/postgres/): Complete PostgreSQL setup guide
- [Set up MySQL](/docs/grafana-cloud/monitor-applications/database-observability/set-up/mysql/): Complete MySQL setup guide
