Prometheus query alert if average memory/CPU utilization is trending up

656 Views Asked by At

​​The actual requirement is if CPU/memory increases​(trending up) continuously due to a memory leak and finally one day container may blast and recreate right due to memory/CPU exhausted ​Before blasting the container user should monitor the status by the alerts

1.increasing continuously without decreasing for period of time --> Alert should raise
2.increasing and decreasing for period of time --> Alert should not raise

Both points should include in single expression in the Prometheus rule​ for both CPU/Memory in single expression

My goal is to monitor container memory/cpu for a continuous increase over time and alert only if there are no decreases within a specified period

0

There are 0 best solutions below