Run PMM Server with Docker volumes (Recommended)¶
Docker volumes provide the recommended storage configuration for PMM Server in production environments.
Volumes offer better isolation, portability, and compatibility with Docker’s ecosystem compared to host directory storage.
Installation steps¶
To deploy PMM Server using Docker volumes:
-
Pull the latest PMM Server image:
docker pull percona/pmm-server:3 -
Create a dedicated Docker volume:
docker volume create pmm-data -
Run PMM Server with the volume configured:
docker run --detach --restart always \ --publish 443:8443 \ --volume pmm-data:/srv \ --network=pmm-network \ --name pmm-server \ percona/pmm-server:3 -
Set a secure password for the default
adminuser. You can do this either at startup using environment variables, or after startup using a helper script:-
At startup (add to the
docker runcommand in step 3):--env GF_SECURITY_ADMIN_PASSWORD="your_secure_password" -
After startup:
docker exec -t pmm-server change-admin-password your_secure_password
-
-
Access the PMM web interface at
https://localhostin a web browser. If you are accessing the Docker host remotely, replacelocalhostwith your server’s IP address or hostname.
Additional configuration options¶
You can further customize your PMM Server deployment with:
-
Environment variables to configure metrics retention, resolution, and features:
docker run --detach --restart always \ --publish 443:8443 \ --env PMM_DATA_RETENTION=336h \ --env PMM_METRICS_RESOLUTION=5s \ --volume pmm-data:/srv \ --name pmm-server \ percona/pmm-server:3Set
PMM_DATA_RETENTIONin hours, as a multiple of24h, such as720hfor 30 days. The minimum is24h. If you use days, such as30d, PMM Server won’t start. -
Port mapping to expose PMM Server on a different port:
docker run ... --publish 8443:8443 ... percona/pmm-server:3
For a complete list of configuration options, see the full list of environment variables.
Next steps¶
- Install PMM Client to start monitoring your database instances
- Set up backups to protect your monitoring data
- Configure SSL certificates for secure communications