Receiving Gateway Time-out when running a Prometheus query
Issue
-
When running a heavy query to get metrics out of Prometheus, like for example "
topk(20, count by (__name__, job)({__name__=~".+"}))", which counts how many time series each metric has and gets the top20, the "Gateway Time-out" message is shown in the OpenShift web console or in the client:requests.exceptions.HTTPError: 504 Server Error: Gateway Time-out for url: https://prometheus-k8s-openshift-monitoring.apps.xxxxx.local/api/v1/query_range?query=sum%28container_memory_rss[...]
Environment
- Red Hat OpenShift Container Platform (RHOCP)
- 3.11
- 4
- Prometheus
- OpenShift metrics
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.