Prometheus Persistence Volume(Kubernetes)

32 views
Skip to first unread message

prabin...@gmail.com

unread,
Sep 21, 2020, 3:27:36 AM9/21/20
to Prometheus Developers
Memory Consumed by prometheus is keep on increasing day by day . Though Number of  Targets are same.
What is is the persistence volume of prometheus , or how we can evaluate the same and limit our memory consumtion.

Bjoern Rabenstein

unread,
Sep 23, 2020, 10:57:50 AM9/23/20
to prabin...@gmail.com, Prometheus Developers
On 21.09.20 00:27, prabin...@gmail.com wrote:
> Memory Consumed by prometheus is keep on increasing day by day . Though Number
> of Targets are same.

Yes, Prometheus uses as much RAM as possible for mmap'ing, making your
queries faster.

> What is is the persistence volume of prometheus , or how we can evaluate the
> same and limit our memory consumtion.

You don't have to. When the OS needs the RAM, it will simply take it
away from Prometheus.

There is a certain amount of memory that Prometheus needs to exist. If
you don't have enough for that, it will OOM.

You can look at
https://www.robustperception.io/how-much-ram-does-prometheus-2-x-need-for-cardinality-and-ingestion
, although a lot has been optimized over the last 1.5 years since that
article was published.

--
Björn Rabenstein
[PGP-ID] 0x851C3DA17D748D03
[email] bjo...@rabenste.in

prabin...@gmail.com

unread,
Sep 24, 2020, 3:46:07 AM9/24/20
to Prometheus Developers
Thanks for your reply
Is there any way to know the maximum persistence volume , as we need to fix a resource quota for prometheus in kubernetes.

Tim Schwenke

unread,
Sep 28, 2020, 9:22:14 AM9/28/20
to Prometheus Developers
I can recommend you to run Cadvisor. This will give you a whole set of CPU metrics that enable you to have a more detailed insight. You will probably notice that the memory cache is the one that just keeps increasing, especially after a bunch of queries. 
Reply all
Reply to author
Forward
0 new messages