# PMM disc space usage

**URL:** <https://forums.percona.com/t/pmm-disc-space-usage/5095>\
**Category:** PMM 1.x\
**Created:** [September 20, 2016, 8:23am UTC](https://forums.percona.com/t/pmm-disc-space-usage/5095 "2016-09-20T08:23:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![johnberanek](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/johnberanek/32/1137_2.png) [@johnberanek](https://forums.percona.com/u/johnberanek)\
**Post date:** [September 20, 2016, 8:23am UTC](https://forums.percona.com/t/pmm-disc-space-usage/5095/1 "2016-09-20T08:23:26Z")

</div>

Just installed an instance of PMM as a trial, monitoring 3 Percona XtraDB Cluster nodes.

After just 48 hours of statistics gathered, the Prometheus data storage has reached 9.7GiB. So, ~35GiB of storage to monitor just 3 MySQL servers for a week?

Seems a little excessive to me…

---

<div class="post-metadata">

**Author:** ![weber](https://avatars.discourse-cdn.com/v4/letter/w/da6949/32.png) [@weber](https://forums.percona.com/u/weber)\
**Post date:** [September 20, 2016, 11:44am UTC](https://forums.percona.com/t/pmm-disc-space-usage/5095/2 "2016-09-20T11:44:45Z")

</div>

It’s 1s resolution by default and maximum statistics if all metrics are available.

Also there could be other factors.  
For example, depending from number of tables - it can be a lot, and disabling per table stats (re-adding mysql:metrics with --disable-tablestats flag) will decrease disk usage dramatically.

If you don’t need 1s resolution you can set 5s [URL=“[Percona Monitoring and Management](https://www.percona.com/doc/percona-monitoring-and-management/faq.html#what-resolution-is-used-for-metrics)”][https://www.percona.com/doc/percona-...ed-for-metrics[/URL]](https://www.percona.com/doc/percona-...ed-for-metrics%5B/URL%5D)

If 30 days retention is too much for disk space you can lower it [URL=“[Percona Monitoring and Management](https://www.percona.com/doc/percona-monitoring-and-management/faq.html#how-to-control-data-retention-for-prometheus)”][https://www.percona.com/doc/percona-...for-prometheus[/URL]](https://www.percona.com/doc/percona-...for-prometheus%5B/URL%5D)

To be sure this is all metrics, I would ask you to measure by running:  
docker exec -ti pmm-server du -sh /opt/prometheus/data

---

<div class="post-metadata">

**Author:** ![johnberanek](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/johnberanek/32/1137_2.png) [@johnberanek](https://forums.percona.com/u/johnberanek)\
**Post date:** [September 21, 2016, 3:12am UTC](https://forums.percona.com/t/pmm-disc-space-usage/5095/3 "2016-09-21T03:12:17Z")

</div>

Thank you for your quick response.

As for number of tables, each of the cluster nodes has 620 tables, so a reasonable number I guess…

```auto

$ docker exec -ti pmm-server du -sh /opt/prometheus/data [9:38:42]
11G /opt/prometheus/data

```

I’m a bit of a Docker novice, do I need to create a new pmm-server container to set the environment options?

---

<div class="post-metadata">

**Author:** ![weber](https://avatars.discourse-cdn.com/v4/letter/w/da6949/32.png) [@weber](https://forums.percona.com/u/weber)\
**Post date:** [September 21, 2016, 9:56am UTC](https://forums.percona.com/t/pmm-disc-space-usage/5095/4 "2016-09-21T09:56:39Z")

</div>

Yes, you need to re-create pmm-server container to pass other env variables, you can preserve the data one…

Also there is an option to change chunk encoding for metric storage which claims 50% saving in cost of 20% CPU overhead.  
However, we have not made any tests yet but will do soon.
