Bug 2072805
| Summary: | Observe > Dashboards: $__range variables cause PromQL query errors | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Andrew Pickering <anpicker> |
| Component: | Monitoring | Assignee: | Andrew Pickering <anpicker> |
| Status: | CLOSED ERRATA | QA Contact: | Junqi Zhao <juzhao> |
| Severity: | low | Docs Contact: | |
| Priority: | low | ||
| Version: | 4.11 | CC: | amuller, anpicker, aos-bugs, juzhao |
| Target Milestone: | --- | ||
| Target Release: | 4.11.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | No Doc Update | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2022-08-10 11:04:00 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Andrew Pickering
2022-04-07 02:12:42 UTC
tested with 4.11.0-0.nightly-2022-04-16-163450 and used the attached dashboard file, create configmap under openshift-config-managed, dashboard name: testing
definition:
*******************
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": true,
"title": "HTTP Request Total",
"titleSize": "h6",
"type": "row"
},
{
"aliasColors": {
},
"bars": true,
"dashLength": 10,
"dashes": false,
"datasource": "$datasource",
"fill": 2,
"fillGradient": 0,
"gridPos": {
"h": 9,
"w": 12,
"x": 0,
"y": 1
},
"id": 3,
"legend": {
"alignAsTable": true,
"avg": false,
"current": true,
"hideEmpty": true,
"hideZero": true,
"max": false,
"min": false,
"rightSide": true,
"show": true,
"sideWidth": null,
"sort": "current",
"sortDesc": true,
"total": false,
"values": true
},
"lines": false,
"linewidth": 1,
"links": [
],
"minSpan": 24,
"nullPointMode": "null",
"paceLength": 10,
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"repeat": null,
"seriesOverrides": [
],
"spaceLength": 10,
"span": 24,
"stack": false,
"steppedLine": false,
"targets": [
{
"expr": "(topk(5, sum(rate(http_requests_total[$__range])) by (instance)))",
"format": "time_series",
"legendFormat": "{{instance}}",
"refId": "A"
}
],
*******************
go to "Observe -> Dashboards", choose dashboard testing, select any value from "Time Range" drop-down list, for example "Last 15 minutes", "HTTP Request Total" section, click Inspect, prometheus expr is: (topk(5, sum(rate(http_requests_total[900s])) by (instance)))
$__range is parsed right, 15*60=900s
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Important: OpenShift Container Platform 4.11.0 bug fix and security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2022:5069 |