Prometheus log retention policy configuration not working

Solution Verified - Updated -

Issue

  • Prometheus pods not retaining logs as per the set configuration in the configmap user-workload-monitoring-config and cluster-monitoring-config available under respective namespaces openshift-user-workload-monitoring and openshift-monitoring:
apiVersion: v1
kind: ConfigMap
metadata:
  name: <name>
  namespace: <namespace>
data:
  config.yaml: |
    prometheus: 
      retention: 2h 

Environment

  • Red Hat OpenShift Container Platform (RHOCP)
    • 4.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content