From ab84b9f67c7a7f61e0c0a311afb47a1af4f5903f Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Fri, 1 Nov 2024 20:31:07 +0800 Subject: [PATCH 01/14] Add support for empty lists: instanceLabels=[],grouplabels=[] in commonlib.variables generation (#1352) --- .../common/variables/variables.libsonnet | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/common-lib/common/variables/variables.libsonnet b/common-lib/common/variables/variables.libsonnet index 9a1f65c73..1a8d255d7 100644 --- a/common-lib/common/variables/variables.libsonnet +++ b/common-lib/common/variables/variables.libsonnet @@ -59,14 +59,21 @@ local utils = import '../utils.libsonnet'; [root.datasources.prometheus] + variablesFromLabels(groupLabels, instanceLabels, filteringSelector, multiInstance=false), queriesSelectorAdvancedSyntax: - '%s' % [ - utils.labelsToPromQLSelectorAdvanced(groupLabels + instanceLabels), - ], + std.join( + ',', + std.filter(function(x) std.length(x) > 0, [ + filteringSelector, + utils.labelsToPromQLSelectorAdvanced(groupLabels + instanceLabels), + ]) + ), queriesSelector: - '%s,%s' % [ - filteringSelector, - utils.labelsToPromQLSelector(groupLabels + instanceLabels), - ], + std.join( + ',', + std.filter(function(x) std.length(x) > 0, [ + filteringSelector, + utils.labelsToPromQLSelector(groupLabels + instanceLabels), + ]) + ), } + if enableLokiLogs then self.withLokiLogs() else {}, From b4993cb78f43d2ea7d45275a445bbb814f57a358 Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Wed, 6 Nov 2024 20:40:31 +0800 Subject: [PATCH 02/14] windows: Use instance label for hostname in hostname panel (#1353) * windows: Use instance label for hostname in hostname panel * Fix NTP delay units (thanks to linter) * Add units to panels * Add none units to cpu count to pass linter * Update win mixin --- .../common/panels/cpu/stat/count.libsonnet | 3 +- .../mixin.libsonnet | 9 +-- windows-mixin/mixin.libsonnet | 6 +- windows-observ-lib/config.libsonnet | 42 ++++++++++++++ windows-observ-lib/main.libsonnet | 58 +++---------------- windows-observ-lib/mixin.libsonnet | 10 ++++ windows-observ-lib/panels.libsonnet | 35 ++++++----- 7 files changed, 85 insertions(+), 78 deletions(-) create mode 100644 windows-observ-lib/config.libsonnet create mode 100644 windows-observ-lib/mixin.libsonnet diff --git a/common-lib/common/panels/cpu/stat/count.libsonnet b/common-lib/common/panels/cpu/stat/count.libsonnet index 915060b49..4b9a9ed77 100644 --- a/common-lib/common/panels/cpu/stat/count.libsonnet +++ b/common-lib/common/panels/cpu/stat/count.libsonnet @@ -16,6 +16,7 @@ base { stylize(allLayers=true): (if allLayers then super.stylize() else {}) - + generic.info.stylize(allLayers=false), + + generic.info.stylize(allLayers=false) + + g.panel.stat.standardOptions.withUnit('none'), } diff --git a/windows-active-directory-mixin/mixin.libsonnet b/windows-active-directory-mixin/mixin.libsonnet index 23a9c558b..938a47671 100644 --- a/windows-active-directory-mixin/mixin.libsonnet +++ b/windows-active-directory-mixin/mixin.libsonnet @@ -3,16 +3,13 @@ local alerts = import './alerts/alerts.libsonnet'; local g = import './g.libsonnet'; local var = g.dashboard.variable; local activedirectorymixin = - windowsobservlib.new( - filteringSelector='job=~"integrations/windows_exporter"', - uid='active-directory', - groupLabels=['job'], - instanceLabels=['instance'], - ) + windowsobservlib.new() { config+: { enableADDashboard: true, + groupLabels: ['job'], + uid: 'active-directory', }, } diff --git a/windows-mixin/mixin.libsonnet b/windows-mixin/mixin.libsonnet index 2bae55c62..0aea86ab7 100644 --- a/windows-mixin/mixin.libsonnet +++ b/windows-mixin/mixin.libsonnet @@ -4,11 +4,7 @@ local winlib = import 'windows-observ-lib/main.libsonnet'; local config = (import 'config.libsonnet')._config; { local windows = - winlib.new( - dashboardNamePrefix=config.dashboardNamePrefix, - uid=config.uid, - filteringSelector=config.filteringSelector, - ) + winlib.new() + { config+: config, diff --git a/windows-observ-lib/config.libsonnet b/windows-observ-lib/config.libsonnet new file mode 100644 index 000000000..8ff0a6e0b --- /dev/null +++ b/windows-observ-lib/config.libsonnet @@ -0,0 +1,42 @@ +{ + // any modular library should include as inputs: + // 'dashboardNamePrefix' - Use as prefix for all Dashboards and (optional) rule groups + // 'filteringSelector' - Static selector to apply to ALL dashboard variables of type query, panel queries, alerts and recording rules. + // 'groupLabels' - one or more labels that can be used to identify 'group' of instances. In simple cases, can be 'job' or 'cluster'. + // 'instanceLabels' - one or more labels that can be used to identify single entity of instances. In simple cases, can be 'instance' or 'pod'. + // 'uid' - UID to prefix all dashboards original uids + groupLabels: ['job'], + instanceLabels: ['instance'], + filteringSelector: 'job=~".*windows.*"', + dashboardTags: ['windows'], + uid: 'windows', + dashboardNamePrefix: '', + + // optional + ignoreVolumes: 'HarddiskVolume.*', + alertsCPUThresholdWarning: '90', + alertMemoryUsageThresholdCritical: '90', + alertDiskUsageThresholdCritical: '90', + dashboardPeriod: 'now-1h', + dashboardTimezone: 'default', + dashboardRefresh: '1m', + + // optional Windows AD + alertsHighPendingReplicationOperations: 50, // count + alertsHighReplicationSyncRequestFailures: 0, // count + alertsHighPasswordChanges: 25, // count + alertsMetricsDownJobName: 'integrations/windows_exporter', + enableADDashboard: false, + + // logs lib related + enableLokiLogs: true, + extraLogLabels: ['channel', 'source', 'keywords', 'level'], + logsVolumeGroupBy: 'level', + showLogsVolume: true, + logsExtraFilters: + ||| + | label_format timestamp="{{__timestamp__}}" + | drop channel_extracted,source_extracted,computer_extracted,level_extracted,keywords_extracted + | line_format `{{ if eq "[[instance]]" ".*" }}{{ alignLeft 25 .instance}}|{{end}}{{alignLeft 12 .channel }}| {{ alignLeft 25 .source}}| {{ .message }}` + |||, +} diff --git a/windows-observ-lib/main.libsonnet b/windows-observ-lib/main.libsonnet index 1ee5a7a7a..df7145a01 100644 --- a/windows-observ-lib/main.libsonnet +++ b/windows-observ-lib/main.libsonnet @@ -1,4 +1,5 @@ local alerts = import './alerts.libsonnet'; +local config = import './config.libsonnet'; local dashboards = import './dashboards.libsonnet'; local datasources = import './datasources.libsonnet'; local g = import './g.libsonnet'; @@ -7,58 +8,10 @@ local targets = import './targets.libsonnet'; local commonlib = import 'common-lib/common/main.libsonnet'; { - new( - filteringSelector, - groupLabels=['job'], - instanceLabels=['instance'], - dashboardNamePrefix='', - dashboardTags=[uid], - uid, - ): { + new(): { local this = self, - config: { - // any modular library should include as inputs: - // 'dashboardNamePrefix' - Use as prefix for all Dashboards and (optional) rule groups - // 'filteringSelector' - Static selector to apply to ALL dashboard variables of type query, panel queries, alerts and recording rules. - // 'groupLabels' - one or more labels that can be used to identify 'group' of instances. In simple cases, can be 'job' or 'cluster'. - // 'instanceLabels' - one or more labels that can be used to identify single entity of instances. In simple cases, can be 'instance' or 'pod'. - // 'uid' - UID to prefix all dashboards original uids - groupLabels: groupLabels, - instanceLabels: instanceLabels, - filteringSelector: filteringSelector, - dashboardTags: dashboardTags, - uid: uid, - dashboardNamePrefix: dashboardNamePrefix, - - // optional - ignoreVolumes: 'HarddiskVolume.*', - alertsCPUThresholdWarning: '90', - alertMemoryUsageThresholdCritical: '90', - alertDiskUsageThresholdCritical: '90', - dashboardPeriod: 'now-1h', - dashboardTimezone: 'default', - dashboardRefresh: '1m', - - // optional Windows AD - alertsHighPendingReplicationOperations: 50, // count - alertsHighReplicationSyncRequestFailures: 0, // count - alertsHighPasswordChanges: 25, // count - alertsMetricsDownJobName: 'integrations/windows_exporter', - enableADDashboard: false, - - // logs lib related - enableLokiLogs: true, - extraLogLabels: ['channel', 'source', 'keywords', 'level'], - logsVolumeGroupBy: 'level', - showLogsVolume: true, - logsExtraFilters: - ||| - | label_format timestamp="{{__timestamp__}}" - | drop channel_extracted,source_extracted,computer_extracted,level_extracted,keywords_extracted - | line_format `{{ if eq "[[instance]]" ".*" }}{{ alignLeft 25 .instance}}|{{end}}{{alignLeft 12 .channel }}| {{ alignLeft 25 .source}}| {{ .message }}` - |||, - }, + config: config, grafana: { variables: commonlib.variables.new( filteringSelector=this.config.filteringSelector, @@ -74,7 +27,7 @@ local commonlib = import 'common-lib/common/main.libsonnet'; reboot: commonlib.annotations.reboot.new( title='Reboot', target=this.grafana.targets.reboot, - instanceLabels=std.join(',', instanceLabels), + instanceLabels=std.join(',', this.config.instanceLabels), ) + commonlib.annotations.base.withTagKeys(std.join(',', this.config.groupLabels + this.config.instanceLabels)), } @@ -124,5 +77,8 @@ local commonlib = import 'common-lib/common/main.libsonnet'; }, }, + withConfigMixin(config): { + config+: config, + }, } diff --git a/windows-observ-lib/mixin.libsonnet b/windows-observ-lib/mixin.libsonnet new file mode 100644 index 000000000..4e356b0a6 --- /dev/null +++ b/windows-observ-lib/mixin.libsonnet @@ -0,0 +1,10 @@ +local windowslib = import './main.libsonnet'; +{ + _config:: {}, + _windowsib:: + windowslib.new() + + windowslib.withConfigMixin(self._config), + grafanaDashboards+:: self._windowsib.grafana.dashboards, + prometheusAlerts+:: self._windowsib.prometheus.alerts, + prometheusRules+:: self._windowsib.prometheus.recordingRules, +} diff --git a/windows-observ-lib/panels.libsonnet b/windows-observ-lib/panels.libsonnet index 8170502fb..6b436c612 100644 --- a/windows-observ-lib/panels.libsonnet +++ b/windows-observ-lib/panels.libsonnet @@ -187,7 +187,8 @@ local utils = commonlib.utils; A high number of context switches or interrupts can indicate that the system is overloaded or that there are problems with specific devices or processes. ||| - ), + ) + + g.panel.timeSeries.standardOptions.withUnit('short'), systemExceptions: commonlib.panels.generic.timeSeries.base.new( 'System calls and exceptions', @@ -195,14 +196,16 @@ local utils = commonlib.utils; t.windowsSystemExceptions, t.windowsSystemCalls, ], - ), + ) + + g.panel.timeSeries.standardOptions.withUnit('short'), systemThreads: commonlib.panels.generic.timeSeries.base.new( 'System threads', targets=[ t.windowsSystemThreads, ], - ), + ) + + g.panel.timeSeries.standardOptions.withUnit('short'), timeNtpStatus: commonlib.panels.system.statusHistory.ntp.new( 'NTP status', @@ -224,7 +227,7 @@ local utils = commonlib.utils; Time offset: Absolute time offset between the system clock and the chosen time source, in seconds. ||| ) - + g.panel.timeSeries.standardOptions.withUnit('seconds') + + g.panel.timeSeries.standardOptions.withUnit('s') + g.panel.timeSeries.standardOptions.withNoValue('No data. Please check that "time" collector is enabled.'), cpuCount: commonlib.panels.cpu.stat.count.new(targets=[t.cpuCount]), cpuUsageTs: commonlib.panels.cpu.timeSeries.utilization.new(targets=[t.cpuUsage]), @@ -242,17 +245,19 @@ local utils = commonlib.utils; CPU usage by different modes. ||| ), - cpuQueue: commonlib.panels.generic.timeSeries.base.new( - 'CPU average queue size', - targets=[t.cpuQueue], - description=||| - The CPU average queue size in Windows, often referred to as the "Processor Queue Length" or "CPU Queue Length," is a metric that measures the number of threads or tasks waiting to be processed by the central processing unit (CPU) at a given moment. - It is an essential performance indicator that reflects the workload and responsiveness of the CPU. - When the CPU queue length is high, it indicates that there are more tasks in line for processing than the CPU can handle immediately. + cpuQueue: + commonlib.panels.generic.timeSeries.base.new( + 'CPU average queue size', + targets=[t.cpuQueue], + description=||| + The CPU average queue size in Windows, often referred to as the "Processor Queue Length" or "CPU Queue Length," is a metric that measures the number of threads or tasks waiting to be processed by the central processing unit (CPU) at a given moment. + It is an essential performance indicator that reflects the workload and responsiveness of the CPU. + When the CPU queue length is high, it indicates that there are more tasks in line for processing than the CPU can handle immediately. - This can lead to system slowdowns, decreased responsiveness, and potential performance issues. High CPU queue lengths are often associated with CPU saturation, where the CPU is struggling to keep up with the demands placed on it. - ||| - ), + This can lead to system slowdowns, decreased responsiveness, and potential performance issues. High CPU queue lengths are often associated with CPU saturation, where the CPU is struggling to keep up with the demands placed on it. + ||| + ) + + g.panel.timeSeries.standardOptions.withUnit('short'), memoryTotalBytes: commonlib.panels.memory.stat.total.new(targets=[t.memoryTotalBytes]), memoryPageTotalBytes: commonlib.panels.memory.stat.total.new( @@ -363,7 +368,7 @@ local utils = commonlib.utils; targets=[t.osInfo], description="System's hostname." ) - { options+: { reduceOptions+: { fields: '/^hostname$/' } } }, + { options+: { reduceOptions+: { fields: '/^instance$/' } } }, networkErrorsAndDroppedPerSec: commonlib.panels.network.timeSeries.errors.new( 'Network errors and dropped packets', From a8fc2139d881ae632a8c956eb9dd4b84b24f362e Mon Sep 17 00:00:00 2001 From: Ana Ivanov <38096095+anaivanov@users.noreply.github.com> Date: Thu, 7 Nov 2024 20:56:43 +0100 Subject: [PATCH 03/14] csp-mixin(gcp compute engine): Add alert for CPU (#1345) * csp-mixin(gcp compute engine): Add alert for CPU * split alerts in multiple files * importRules directly on mixing * use config prometheus for each provider * fix lint * fix alerts * remove alerts libsonnet file --------- Co-authored-by: yduartep --- csp-mixin/.lint | 6 ++++ csp-mixin/alerts.libsonnet | 52 ------------------------------- csp-mixin/alerts/azure-alerts.yml | 30 ++++++++++++++++++ csp-mixin/alerts/gcp-alerts.yml | 16 ++++++++++ csp-mixin/azureconfig.libsonnet | 8 +++++ csp-mixin/gcpconfig.libsonnet | 7 +++++ csp-mixin/main.libsonnet | 2 +- 7 files changed, 68 insertions(+), 53 deletions(-) delete mode 100644 csp-mixin/alerts.libsonnet create mode 100644 csp-mixin/alerts/azure-alerts.yml create mode 100644 csp-mixin/alerts/gcp-alerts.yml diff --git a/csp-mixin/.lint b/csp-mixin/.lint index 1d76545b9..3652e0e64 100644 --- a/csp-mixin/.lint +++ b/csp-mixin/.lint @@ -71,3 +71,9 @@ exclusions: panel-title-description-rule: entries: - dashboard: Azure Service Bus + - dashboard: GCP Compute Engine + - dashboard: Azure Virtual Machines + target-rate-interval-rule: + entries: + - dashboard: GCP Compute Engine + diff --git a/csp-mixin/alerts.libsonnet b/csp-mixin/alerts.libsonnet deleted file mode 100644 index b207ecef7..000000000 --- a/csp-mixin/alerts.libsonnet +++ /dev/null @@ -1,52 +0,0 @@ -{ - new(this): { - groups+: [ - { - name: this.config.uid, - rules: - [ - { - alert: 'AzureVMHighCpuUtilization', - expr: 'avg by (%s) (%s) > 85' % - [ - std.join(',', this.config.groupLabels + this.config.instanceLabels), - this.signals.azurevm.cpuUtilization.asRuleExpression(), - ], - 'for': '5m', - keep_firing_for: '10m', - labels: { - severity: 'critical', - service: 'Azure Virtual Machines', - namespace: 'cloud-provider-' + this.config.uid, - }, - annotations: { - summary: 'CPU utilization is too high', - description: 'The VM {{$labels.resourceName}} is under heavy load and may become unresponsive.', - dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e', - }, - }, - { - alert: 'AzureVMUnavailable', - expr: 'avg by (%s) (%s) != 1' % - [ - std.join(',', this.config.groupLabels + this.config.instanceLabels), - this.signals.azurevmOverview.vmAvailability.asRuleExpression(), - ], - 'for': '5m', - keep_firing_for: '10m', - labels: { - severity: 'critical', - service: 'Azure Virtual Machines', - namespace: 'cloud-provider-' + this.config.uid, - }, - annotations: { - summary: 'VM unavailable', - description: 'The VM {{$labels.resourceName}} is not functioning or crashed, which may require immediate action.', - dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e', - }, - }, - ], - }, - ], - }, -} diff --git a/csp-mixin/alerts/azure-alerts.yml b/csp-mixin/alerts/azure-alerts.yml new file mode 100644 index 000000000..ed3d73b04 --- /dev/null +++ b/csp-mixin/alerts/azure-alerts.yml @@ -0,0 +1,30 @@ +groups: + - name: azure + rules: + - alert: AzureVMHighCpuUtilization + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_compute_virtualmachines_percentage_cpu_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 85 + for: 5m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure Virtual Machines' + namespace: cloud-provider-azure + annotations: + summary: 'CPU utilization is too high.' + description: 'The VM {{ $labels.resourceName }} is under heavy load and may become unresponsive.' + dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e' + + - alert: AzureVMUnavailable + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_compute_virtualmachines_vmavailabilitymetric_average_count{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) != 1 + for: 5m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure Virtual Machines.' + namespace: cloud-provider-azure + annotations: + summary: 'VM unavailable.' + description: 'The VM {{ $labels.resourceName }} is not functioning or crashed, which may require immediate action.' + dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e' diff --git a/csp-mixin/alerts/gcp-alerts.yml b/csp-mixin/alerts/gcp-alerts.yml new file mode 100644 index 000000000..494e540fc --- /dev/null +++ b/csp-mixin/alerts/gcp-alerts.yml @@ -0,0 +1,16 @@ +groups: + - name: gcp + rules: + - alert: GcpCEHighCpuUtilization + expr: | + 100 * avg by (job,project_id,instance_name) (stackdriver_gce_instance_compute_googleapis_com_instance_cpu_utilization{job=~".+",project_id=~".+",instance_name=~".+"}) > 85 + for: 5m + keep_firing_for: 10m + labels: + severity: critical + service: 'Compute Engine' + namespace: cloud-provider-gcp + annotations: + summary: 'CPU utilization is too high.' + description: 'The VM {{ $labels.instance_name }} is under heavy load and may become unresponsive.' + dashboard_uid: 'f115fe73641347c43415535d77e2dc0f' diff --git a/csp-mixin/azureconfig.libsonnet b/csp-mixin/azureconfig.libsonnet index b16f3ec3b..510fbb11b 100644 --- a/csp-mixin/azureconfig.libsonnet +++ b/csp-mixin/azureconfig.libsonnet @@ -19,5 +19,13 @@ groupLabels: ['job', 'resourceGroup', 'subscriptionName'], instanceLabels: ['resourceName'], metricsSource: 'azuremonitor', + + local importRules(rules) = { + groups+: std.parseYaml(rules).groups, + }, + + prometheus: { + alerts: importRules(importstr 'alerts/azure-alerts.yml'), + }, }, } diff --git a/csp-mixin/gcpconfig.libsonnet b/csp-mixin/gcpconfig.libsonnet index fac342add..14084823d 100644 --- a/csp-mixin/gcpconfig.libsonnet +++ b/csp-mixin/gcpconfig.libsonnet @@ -19,5 +19,12 @@ groupLabels: ['job'], instanceLabels: ['bucket_name'], metricsSource: 'stackdriver', + local importRules(rules) = { + groups+: std.parseYaml(rules).groups, + }, + + prometheus: { + alerts: importRules(importstr 'alerts/gcp-alerts.yml'), + }, }, } diff --git a/csp-mixin/main.libsonnet b/csp-mixin/main.libsonnet index e5c247a62..c23155217 100644 --- a/csp-mixin/main.libsonnet +++ b/csp-mixin/main.libsonnet @@ -15,7 +15,7 @@ local commonlib = import 'common-lib/common/main.libsonnet'; dashboards: (import './dashboards.libsonnet').new(this), }, prometheus: { - alerts: (import './alerts.libsonnet').new(this), + alerts: this.config.prometheus.alerts, recordingRules: {}, }, asMonitoringMixin(): { From 69196e8e5f40dbaa76ee0b6ac770cdf6e7903038 Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Tue, 12 Nov 2024 21:20:57 +0800 Subject: [PATCH 04/14] Add current all to clickhouse-mixin (#1354) * Add current all to clickhouse-mixin * Add allValues --- clickhouse-mixin/dashboards/clickhouse-latency.libsonnet | 8 +++++--- clickhouse-mixin/dashboards/clickhouse-overview.libsonnet | 8 +++++--- clickhouse-mixin/dashboards/clickhouse-replica.libsonnet | 8 +++++--- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/clickhouse-mixin/dashboards/clickhouse-latency.libsonnet b/clickhouse-mixin/dashboards/clickhouse-latency.libsonnet index b715efc5a..1d6a9fcf0 100644 --- a/clickhouse-mixin/dashboards/clickhouse-latency.libsonnet +++ b/clickhouse-mixin/dashboards/clickhouse-latency.libsonnet @@ -458,7 +458,7 @@ local zooKeeperWaitTimePanel(matcher) = label='job', datasource=promDatasource, query='label_values(ClickHouseProfileEvents_DiskReadElapsedMicroseconds,job)', - current='', + current='all', refresh=2, includeAll=true, multi=true, @@ -470,7 +470,8 @@ local zooKeeperWaitTimePanel(matcher) = label='instance', datasource=promDatasource, query='label_values(ClickHouseProfileEvents_DiskReadElapsedMicroseconds{job=~"$job"}, instance)', - current='', + current='all', + allValues='.+', refresh=2, includeAll=true, sort=1 @@ -480,10 +481,11 @@ local zooKeeperWaitTimePanel(matcher) = promDatasource, 'label_values(ClickHouseProfileEvents_DiskReadElapsedMicroseconds{job=~"$job"}, cluster)', label='Cluster', + current='all', refresh=2, includeAll=true, multi=true, - allValues='', + allValues='.*', hide=if $._config.enableMultiCluster then '' else 'variable', sort=0 ), diff --git a/clickhouse-mixin/dashboards/clickhouse-overview.libsonnet b/clickhouse-mixin/dashboards/clickhouse-overview.libsonnet index 834fde473..3acb7cc99 100644 --- a/clickhouse-mixin/dashboards/clickhouse-overview.libsonnet +++ b/clickhouse-mixin/dashboards/clickhouse-overview.libsonnet @@ -747,7 +747,7 @@ local networkTransmittedPanel(matcher) = label='job', datasource='$prometheus_datasource', query='label_values(ClickHouseProfileEvents_DiskReadElapsedMicroseconds,job)', - current='', + current='all', refresh=2, includeAll=true, multi=true, @@ -759,7 +759,8 @@ local networkTransmittedPanel(matcher) = label='instance', datasource='$prometheus_datasource', query='label_values(ClickHouseProfileEvents_Query{job=~"$job"}, instance)', - current='', + current='all', + allValues='.+', refresh=2, includeAll=true, sort=1 @@ -769,10 +770,11 @@ local networkTransmittedPanel(matcher) = promDatasource, 'label_values(ClickHouseProfileEvents_Query{job=~"$job"}, cluster)', label='Cluster', + current='all', refresh=2, includeAll=true, multi=true, - allValues='', + allValues='.*', hide=if $._config.enableMultiCluster then '' else 'variable', sort=0 ), diff --git a/clickhouse-mixin/dashboards/clickhouse-replica.libsonnet b/clickhouse-mixin/dashboards/clickhouse-replica.libsonnet index 43c2825b8..97ec3cecd 100644 --- a/clickhouse-mixin/dashboards/clickhouse-replica.libsonnet +++ b/clickhouse-mixin/dashboards/clickhouse-replica.libsonnet @@ -639,7 +639,7 @@ local zooKeeperRequestsPanel(matcher) = label='job', datasource=promDatasource, query='label_values(ClickHouseMetrics_InterserverConnection,job)', - current='', + current='all', refresh=2, includeAll=true, multi=true, @@ -651,7 +651,8 @@ local zooKeeperRequestsPanel(matcher) = label='instance', datasource=promDatasource, query='label_values(ClickHouseMetrics_InterserverConnection{job=~"$job"}, instance)', - current='', + current='all', + allValues='.+', refresh=2, includeAll=true, sort=1 @@ -661,10 +662,11 @@ local zooKeeperRequestsPanel(matcher) = promDatasource, 'label_values(ClickHouseMetrics_InterserverConnection{job=~"$job"}, cluster)', label='Cluster', + current='all', refresh=2, includeAll=true, multi=true, - allValues='', + allValues='.*', hide=if $._config.enableMultiCluster then '' else 'variable', sort=0 ), From 5a6b86b475e427b2dbd9e4af0bcafbb6da0507a5 Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Tue, 12 Nov 2024 22:40:36 +0800 Subject: [PATCH 05/14] Add support for empty (filteringSelector='') (#1355) --- .../common/variables/variables.libsonnet | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/common-lib/common/variables/variables.libsonnet b/common-lib/common/variables/variables.libsonnet index 1a8d255d7..2e57534b1 100644 --- a/common-lib/common/variables/variables.libsonnet +++ b/common-lib/common/variables/variables.libsonnet @@ -10,15 +10,19 @@ local utils = import '../utils.libsonnet'; varMetric='up', enableLokiLogs=false, customAllValue='.+', - prometheusDatasourceName='datasource', - prometheusDatasourceLabel='Data source', + prometheusDatasourceName=if enableLokiLogs then 'prometheus_datasource' else 'datasource', + prometheusDatasourceLabel=if enableLokiLogs then 'Prometheus datasource' else 'Data source', ): { - local varMetricTemplate = - if std.type(varMetric) == 'array' - then '{__name__=~"%s",%%s}' % std.join('|', std.uniq(varMetric)) + local varMetricTemplate(varMetric, chainSelector) = + // check if chainSelector is not empty string (case when filtering selector is empty): + if std.type(varMetric) == 'array' && chainSelector != '' + then '{__name__=~"%s",%s}' % [std.join('|', std.uniq(varMetric)), chainSelector] + else if std.type(varMetric) == 'array' && chainSelector == '' + then '{__name__=~"%s"}' % std.join('|', std.uniq(varMetric)) else if std.type(varMetric) == 'string' - then '%s{%%s}' % varMetric + then '%s{%s}' % [varMetric, chainSelector] else error ('varMetric must be array or string'), + local root = self, local variablesFromLabels(groupLabels, instanceLabels, filteringSelector, multiInstance=true) = local chainVarProto(index, chainVar) = @@ -26,7 +30,7 @@ local utils = import '../utils.libsonnet'; + var.query.withDatasourceFromVariable(root.datasources.prometheus) + var.query.queryTypes.withLabelValues( chainVar.label, - varMetricTemplate % [chainVar.chainSelector], + varMetricTemplate(varMetric, chainVar.chainSelector), ) + var.query.generalOptions.withLabel(utils.toSentenceCase(chainVar.label)) + var.query.selectionOptions.withIncludeAll( @@ -43,7 +47,7 @@ local utils = import '../utils.libsonnet'; asc=true, caseInsensitive=false ); - std.mapWithIndex(chainVarProto, utils.chainLabels(groupLabels + instanceLabels, [filteringSelector])), + std.mapWithIndex(chainVarProto, utils.chainLabels(groupLabels + instanceLabels, if std.length(filteringSelector) > 0 then [filteringSelector] else [])), datasources: { prometheus: var.datasource.new(prometheusDatasourceName, 'prometheus') From da81b340bbb149e56bef63103d4b59de76590ce3 Mon Sep 17 00:00:00 2001 From: Yahima Duarte Date: Thu, 21 Nov 2024 15:37:12 +0100 Subject: [PATCH 06/14] add new azure sql database alerts (#1357) * add new azure sql database alerts * add database to summaries and alert name * sync threshold and lookback period with azure * Update csp-mixin/alerts/azure-alerts.yml Co-authored-by: Ana Ivanov <38096095+anaivanov@users.noreply.github.com> * update deadlock alert to include rate * fix lint * add rate to counter metrics --------- Co-authored-by: Ana Ivanov <38096095+anaivanov@users.noreply.github.com> --- csp-mixin/alerts/azure-alerts.yml | 130 +++++++++++++++++++++++++++++- 1 file changed, 128 insertions(+), 2 deletions(-) diff --git a/csp-mixin/alerts/azure-alerts.yml b/csp-mixin/alerts/azure-alerts.yml index ed3d73b04..058ee1f30 100644 --- a/csp-mixin/alerts/azure-alerts.yml +++ b/csp-mixin/alerts/azure-alerts.yml @@ -11,7 +11,7 @@ groups: service: 'Azure Virtual Machines' namespace: cloud-provider-azure annotations: - summary: 'CPU utilization is too high.' + summary: 'VM CPU utilization is too high.' description: 'The VM {{ $labels.resourceName }} is under heavy load and may become unresponsive.' dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e' @@ -22,9 +22,135 @@ groups: keep_firing_for: 10m labels: severity: critical - service: 'Azure Virtual Machines.' + service: 'Azure Virtual Machines' namespace: cloud-provider-azure annotations: summary: 'VM unavailable.' description: 'The VM {{ $labels.resourceName }} is not functioning or crashed, which may require immediate action.' dashboard_uid: '58f33c50e66c911b0ad8a25aa438a96e' + + - alert: AzureDatabaseHighDtuConsumption + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_dtu_consumption_percent_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 90 + for: 10m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database DTU consumption.' + description: 'Check active queries and optimize indexes or consider scaling up DTUs to handle load in {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighStorageUsage + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_storage_percent_maximum_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 95 + for: 15m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database Storage usage.' + description: 'Archive or delete old data, or scale up storage capacity in {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighDeadlockCount + expr: | + sum by (job,resourceGroup,subscriptionName,resourceName) (rate(azure_microsoft_sql_servers_databases_deadlock_total_count{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}[5m])) > 5 + for: 10m + keep_firing_for: 10m + labels: + severity: info + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database Deadlock count.' + description: 'Check {{ $labels.resourceName }} database logs for deadlock details and optimize affected queries.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighUserCpuUsage + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_cpu_percent_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 90 + for: 10m + keep_firing_for: 10m + labels: + severity: warning + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database User CPU usage.' + description: 'Identify high CPU queries on {{ $labels.resourceName }} database and optimize them.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighSystemFailedConnections + expr: | + sum by (job,resourceGroup,subscriptionName,resourceName) (rate(azure_microsoft_sql_servers_databases_connection_failed_total_count{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}[5m])) > 10 + for: 5m + keep_firing_for: 10m + labels: + severity: warning + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High number of database System Failed connections.' + description: 'Check network problems, firewall restrictions or high resource consumption affecting application access to the {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighUserFailedConnections + expr: | + sum by (job,resourceGroup,subscriptionName,resourceName) (rate(azure_microsoft_sql_servers_databases_connection_failed_user_error_total_count{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}[5m])) > 10 + for: 15m + keep_firing_for: 10m + labels: + severity: warning + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High number of database User Failed connections.' + description: 'Check for authentication problems, network configuration errors, firewall issues, or resource constraints, affecting database accessibility for users on database {{ $labels.resourceName }}.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighWorkerUsage + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_workers_percent_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 60 + for: 5m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database worker usage.' + description: 'Look for long execution queries, review the number of concurrent queries and requests being sent to the database or check if there are any blocking sessions or deadlocks into the {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseHighDataIoUsage + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_physical_data_read_percent_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 90 + for: 15m + keep_firing_for: 10m + labels: + severity: info + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'High database data IO usage.' + description: 'Review queries with high read or write activity, check if there are missing indexes or inefficient indexes that result in full table scans and assess the volume of transactions into the {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' + + - alert: AzureDatabaseLowTempdbLogSpace + expr: | + avg by (job,resourceGroup,subscriptionName,resourceName) (azure_microsoft_sql_servers_databases_tempdb_log_used_percent_average_percent{job=~".+",resourceGroup=~".+",subscriptionName=~".+",resourceName=~".+"}) > 60 + for: 5m + keep_firing_for: 10m + labels: + severity: critical + service: 'Azure SQL database' + namespace: cloud-provider-azure + annotations: + summary: 'Low database tempdb log space.' + description: 'Look for active sessions that might be using TempDB intensively, identify stored procedures or queries that create temporary tables or objects, and also look for long-running or memory-intensive queries that rely heavily on TempDB into the {{ $labels.resourceName }} database.' + dashboard_uid: '82c5b6cf30db5b601c5cc3f5d8d4284d' From 0f7e33519c1c2f1b98573fd8c26bfaaf0c2846d7 Mon Sep 17 00:00:00 2001 From: Muhammad Shahzeb Date: Fri, 22 Nov 2024 14:57:22 +0500 Subject: [PATCH 07/14] Update all value to .+ for logs lib (#1359) --- logs-lib/logs/variables.libsonnet | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/logs-lib/logs/variables.libsonnet b/logs-lib/logs/variables.libsonnet index 1f362c4e1..de3354874 100644 --- a/logs-lib/logs/variables.libsonnet +++ b/logs-lib/logs/variables.libsonnet @@ -21,7 +21,7 @@ function( ) + var.query.selectionOptions.withIncludeAll( value=true, - customAllValue='.*' + customAllValue='.+' ) + var.query.selectionOptions.withMulti() + var.query.refresh.onTime() From 51cad60013ea92f856a2ad9c3d676b0dd1fc0f3f Mon Sep 17 00:00:00 2001 From: Stefan Kurek Date: Fri, 22 Nov 2024 09:45:32 -0500 Subject: [PATCH 08/14] Fixes a number of issues to Solr Mixin. (#1360) Fixes issue with Resource Monitoring Dashboard where '~' was missing in query. Change custom allValues for solr_collection variable in Cluster Overview Dashboard which was causing an issue in panels when collection label was not present in metrics. Change custom allValues for solr_collection variable in Query Performance Dashboard which was causing issue in panels when collection label was not present in metrics. --- .../dashboards/apache-solr-cluster-overview.libsonnet | 2 +- .../dashboards/apache-solr-query-performance.libsonnet | 2 +- .../dashboards/apache-solr-resource-monitoring.libsonnet | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apache-solr-mixin/dashboards/apache-solr-cluster-overview.libsonnet b/apache-solr-mixin/dashboards/apache-solr-cluster-overview.libsonnet index 18737578d..2f6ab261b 100644 --- a/apache-solr-mixin/dashboards/apache-solr-cluster-overview.libsonnet +++ b/apache-solr-mixin/dashboards/apache-solr-cluster-overview.libsonnet @@ -1653,7 +1653,7 @@ local getMatcher(cfg) = '%(solrSelector)s, solr_cluster=~"$solr_cluster"' % cfg; refresh=2, includeAll=true, multi=true, - allValues='.+', + allValues='.*', sort=1 ), template.new( diff --git a/apache-solr-mixin/dashboards/apache-solr-query-performance.libsonnet b/apache-solr-mixin/dashboards/apache-solr-query-performance.libsonnet index d8de1087d..7e4d3a4af 100644 --- a/apache-solr-mixin/dashboards/apache-solr-query-performance.libsonnet +++ b/apache-solr-mixin/dashboards/apache-solr-query-performance.libsonnet @@ -1578,7 +1578,7 @@ local getMatcher(cfg) = '%(solrSelector)s, solr_cluster=~"$solr_cluster", base_u refresh=2, includeAll=true, multi=true, - allValues='.+', + allValues='.*', sort=1 ), template.new( diff --git a/apache-solr-mixin/dashboards/apache-solr-resource-monitoring.libsonnet b/apache-solr-mixin/dashboards/apache-solr-resource-monitoring.libsonnet index ad91ae1ce..2992bf0fe 100644 --- a/apache-solr-mixin/dashboards/apache-solr-resource-monitoring.libsonnet +++ b/apache-solr-mixin/dashboards/apache-solr-resource-monitoring.libsonnet @@ -1059,7 +1059,7 @@ local dispatchesPanel(matcher) = { }, }; -local getMatcher(cfg) = '%(solrSelector)s, solr_cluster="$solr_cluster", base_url=~"$base_url"' % cfg; +local getMatcher(cfg) = '%(solrSelector)s, solr_cluster=~"$solr_cluster", base_url=~"$base_url"' % cfg; { grafanaDashboards+:: { From 57b0b85dc1d7ed5e30c2e41f3bd26744b8aef519 Mon Sep 17 00:00:00 2001 From: Mark Date: Mon, 25 Nov 2024 15:25:14 -0500 Subject: [PATCH 09/14] static-exporter: Update httpd.conf file to include headers (#1361) * static-exporter: Update httpd.conf file to include headers Prometheus v3.0.0 has a stricter requirements on the headers that are returned from exporters. The static-exporter does not set any headers and causes scrapes to fail with the following error: ``` non-compliant scrape target sending blank Content-Type and no fallback_scrape_protocol specified for target ```` ``` This adds an httpd.conf file to mount to the container that includes a directive to add a header that solves this problem. To generate the httpd.conf file, I ran the following command: `docker run --rm httpd:2.4 cat /usr/local/apache2/conf/httpd.conf > my-httpd.conf` * Mount the httpdConfig to the filesystem * Include withSubPath mixin volumeMount mixin * Move httpConfig setup to a method so it's opt in * Add reference to name that can be called elsewhere * Update withHttpConfig() to accept a config that can be patched * Update configMap to have a prefix with the name and a suffix foir -httpd-config * Update README.md for static-exporter to add explicit instructions to update the httpd.conf * Update static-exporter/httpd.conf Co-authored-by: Jeroen Op 't Eynde --------- Co-authored-by: Zach Leslie Co-authored-by: Jeroen Op 't Eynde --- static-exporter/README.md | 19 ++ static-exporter/httpd.conf | 554 +++++++++++++++++++++++++++++++++ static-exporter/main.libsonnet | 14 + 3 files changed, 587 insertions(+) create mode 100644 static-exporter/httpd.conf diff --git a/static-exporter/README.md b/static-exporter/README.md index 2581c18dc..fbbee94a0 100644 --- a/static-exporter/README.md +++ b/static-exporter/README.md @@ -43,3 +43,22 @@ local static_exporter = import 'github.com/grafana/jsonnet-libs/static-expoter/m ]), } ``` + +## Updating httpd.conf + +There is a default httpd.conf that was added to this library. +It was generated by running the following: + +``` +docker run --rm httpd:2.4 cat /usr/local/apache2/conf/httpd.conf httpd.conf +``` + +If there is a downstream change that requires updating this config file, run the above command and then add the following snippet to the ` + Header set Content-Type: "text/plain; version=0.0.4" + +``` + +This change adds a Header to the requests that enables Prometheus 3.x to scrape the static exporter. \ No newline at end of file diff --git a/static-exporter/httpd.conf b/static-exporter/httpd.conf new file mode 100644 index 000000000..4f5f4306d --- /dev/null +++ b/static-exporter/httpd.conf @@ -0,0 +1,554 @@ +# +# This is the main Apache HTTP server configuration file. It contains the +# configuration directives that give the server its instructions. +# See for detailed information. +# In particular, see +# +# for a discussion of each configuration directive. +# +# Do NOT simply read the instructions in here without understanding +# what they do. They're here only as hints or reminders. If you are unsure +# consult the online docs. You have been warned. +# +# Configuration and logfile names: If the filenames you specify for many +# of the server's control files begin with "/" (or "drive:/" for Win32), the +# server will use that explicit path. If the filenames do *not* begin +# with "/", the value of ServerRoot is prepended -- so "logs/access_log" +# with ServerRoot set to "/usr/local/apache2" will be interpreted by the +# server as "/usr/local/apache2/logs/access_log", whereas "/logs/access_log" +# will be interpreted as '/logs/access_log'. + +# +# ServerRoot: The top of the directory tree under which the server's +# configuration, error, and log files are kept. +# +# Do not add a slash at the end of the directory path. If you point +# ServerRoot at a non-local disk, be sure to specify a local disk on the +# Mutex directive, if file-based mutexes are used. If you wish to share the +# same ServerRoot for multiple httpd daemons, you will need to change at +# least PidFile. +# +ServerRoot "/usr/local/apache2" + +# +# Mutex: Allows you to set the mutex mechanism and mutex file directory +# for individual mutexes, or change the global defaults +# +# Uncomment and change the directory if mutexes are file-based and the default +# mutex file directory is not on a local disk or is not appropriate for some +# other reason. +# +# Mutex default:logs + +# +# Listen: Allows you to bind Apache to specific IP addresses and/or +# ports, instead of the default. See also the +# directive. +# +# Change this to Listen on specific IP addresses as shown below to +# prevent Apache from glomming onto all bound IP addresses. +# +#Listen 12.34.56.78:80 +Listen 80 + +# +# Dynamic Shared Object (DSO) Support +# +# To be able to use the functionality of a module which was built as a DSO you +# have to place corresponding `LoadModule' lines at this location so the +# directives contained in it are actually available _before_ they are used. +# Statically compiled modules (those listed by `httpd -l') do not need +# to be loaded here. +# +# Example: +# LoadModule foo_module modules/mod_foo.so +# +LoadModule mpm_event_module modules/mod_mpm_event.so +#LoadModule mpm_prefork_module modules/mod_mpm_prefork.so +#LoadModule mpm_worker_module modules/mod_mpm_worker.so +LoadModule authn_file_module modules/mod_authn_file.so +#LoadModule authn_dbm_module modules/mod_authn_dbm.so +#LoadModule authn_anon_module modules/mod_authn_anon.so +#LoadModule authn_dbd_module modules/mod_authn_dbd.so +#LoadModule authn_socache_module modules/mod_authn_socache.so +LoadModule authn_core_module modules/mod_authn_core.so +LoadModule authz_host_module modules/mod_authz_host.so +LoadModule authz_groupfile_module modules/mod_authz_groupfile.so +LoadModule authz_user_module modules/mod_authz_user.so +#LoadModule authz_dbm_module modules/mod_authz_dbm.so +#LoadModule authz_owner_module modules/mod_authz_owner.so +#LoadModule authz_dbd_module modules/mod_authz_dbd.so +LoadModule authz_core_module modules/mod_authz_core.so +#LoadModule authnz_ldap_module modules/mod_authnz_ldap.so +#LoadModule authnz_fcgi_module modules/mod_authnz_fcgi.so +LoadModule access_compat_module modules/mod_access_compat.so +LoadModule auth_basic_module modules/mod_auth_basic.so +#LoadModule auth_form_module modules/mod_auth_form.so +#LoadModule auth_digest_module modules/mod_auth_digest.so +#LoadModule allowmethods_module modules/mod_allowmethods.so +#LoadModule isapi_module modules/mod_isapi.so +#LoadModule file_cache_module modules/mod_file_cache.so +#LoadModule cache_module modules/mod_cache.so +#LoadModule cache_disk_module modules/mod_cache_disk.so +#LoadModule cache_socache_module modules/mod_cache_socache.so +#LoadModule socache_shmcb_module modules/mod_socache_shmcb.so +#LoadModule socache_dbm_module modules/mod_socache_dbm.so +#LoadModule socache_memcache_module modules/mod_socache_memcache.so +#LoadModule socache_redis_module modules/mod_socache_redis.so +#LoadModule watchdog_module modules/mod_watchdog.so +#LoadModule macro_module modules/mod_macro.so +#LoadModule dbd_module modules/mod_dbd.so +#LoadModule bucketeer_module modules/mod_bucketeer.so +#LoadModule dumpio_module modules/mod_dumpio.so +#LoadModule echo_module modules/mod_echo.so +#LoadModule example_hooks_module modules/mod_example_hooks.so +#LoadModule case_filter_module modules/mod_case_filter.so +#LoadModule case_filter_in_module modules/mod_case_filter_in.so +#LoadModule example_ipc_module modules/mod_example_ipc.so +#LoadModule buffer_module modules/mod_buffer.so +#LoadModule data_module modules/mod_data.so +#LoadModule ratelimit_module modules/mod_ratelimit.so +LoadModule reqtimeout_module modules/mod_reqtimeout.so +#LoadModule ext_filter_module modules/mod_ext_filter.so +#LoadModule request_module modules/mod_request.so +#LoadModule include_module modules/mod_include.so +LoadModule filter_module modules/mod_filter.so +#LoadModule reflector_module modules/mod_reflector.so +#LoadModule substitute_module modules/mod_substitute.so +#LoadModule sed_module modules/mod_sed.so +#LoadModule charset_lite_module modules/mod_charset_lite.so +#LoadModule deflate_module modules/mod_deflate.so +#LoadModule xml2enc_module modules/mod_xml2enc.so +#LoadModule proxy_html_module modules/mod_proxy_html.so +#LoadModule brotli_module modules/mod_brotli.so +LoadModule mime_module modules/mod_mime.so +#LoadModule ldap_module modules/mod_ldap.so +LoadModule log_config_module modules/mod_log_config.so +#LoadModule log_debug_module modules/mod_log_debug.so +#LoadModule log_forensic_module modules/mod_log_forensic.so +#LoadModule logio_module modules/mod_logio.so +#LoadModule lua_module modules/mod_lua.so +LoadModule env_module modules/mod_env.so +#LoadModule mime_magic_module modules/mod_mime_magic.so +#LoadModule cern_meta_module modules/mod_cern_meta.so +#LoadModule expires_module modules/mod_expires.so +LoadModule headers_module modules/mod_headers.so +#LoadModule ident_module modules/mod_ident.so +#LoadModule usertrack_module modules/mod_usertrack.so +#LoadModule unique_id_module modules/mod_unique_id.so +LoadModule setenvif_module modules/mod_setenvif.so +LoadModule version_module modules/mod_version.so +#LoadModule remoteip_module modules/mod_remoteip.so +#LoadModule proxy_module modules/mod_proxy.so +#LoadModule proxy_connect_module modules/mod_proxy_connect.so +#LoadModule proxy_ftp_module modules/mod_proxy_ftp.so +#LoadModule proxy_http_module modules/mod_proxy_http.so +#LoadModule proxy_fcgi_module modules/mod_proxy_fcgi.so +#LoadModule proxy_scgi_module modules/mod_proxy_scgi.so +#LoadModule proxy_uwsgi_module modules/mod_proxy_uwsgi.so +#LoadModule proxy_fdpass_module modules/mod_proxy_fdpass.so +#LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so +#LoadModule proxy_ajp_module modules/mod_proxy_ajp.so +#LoadModule proxy_balancer_module modules/mod_proxy_balancer.so +#LoadModule proxy_express_module modules/mod_proxy_express.so +#LoadModule proxy_hcheck_module modules/mod_proxy_hcheck.so +#LoadModule session_module modules/mod_session.so +#LoadModule session_cookie_module modules/mod_session_cookie.so +#LoadModule session_crypto_module modules/mod_session_crypto.so +#LoadModule session_dbd_module modules/mod_session_dbd.so +#LoadModule slotmem_shm_module modules/mod_slotmem_shm.so +#LoadModule slotmem_plain_module modules/mod_slotmem_plain.so +#LoadModule ssl_module modules/mod_ssl.so +#LoadModule optional_hook_export_module modules/mod_optional_hook_export.so +#LoadModule optional_hook_import_module modules/mod_optional_hook_import.so +#LoadModule optional_fn_import_module modules/mod_optional_fn_import.so +#LoadModule optional_fn_export_module modules/mod_optional_fn_export.so +#LoadModule dialup_module modules/mod_dialup.so +#LoadModule http2_module modules/mod_http2.so +#LoadModule proxy_http2_module modules/mod_proxy_http2.so +#LoadModule md_module modules/mod_md.so +#LoadModule lbmethod_byrequests_module modules/mod_lbmethod_byrequests.so +#LoadModule lbmethod_bytraffic_module modules/mod_lbmethod_bytraffic.so +#LoadModule lbmethod_bybusyness_module modules/mod_lbmethod_bybusyness.so +#LoadModule lbmethod_heartbeat_module modules/mod_lbmethod_heartbeat.so +LoadModule unixd_module modules/mod_unixd.so +#LoadModule heartbeat_module modules/mod_heartbeat.so +#LoadModule heartmonitor_module modules/mod_heartmonitor.so +#LoadModule dav_module modules/mod_dav.so +LoadModule status_module modules/mod_status.so +LoadModule autoindex_module modules/mod_autoindex.so +#LoadModule asis_module modules/mod_asis.so +#LoadModule info_module modules/mod_info.so +#LoadModule suexec_module modules/mod_suexec.so + + #LoadModule cgid_module modules/mod_cgid.so + + + #LoadModule cgi_module modules/mod_cgi.so + +#LoadModule dav_fs_module modules/mod_dav_fs.so +#LoadModule dav_lock_module modules/mod_dav_lock.so +#LoadModule vhost_alias_module modules/mod_vhost_alias.so +#LoadModule negotiation_module modules/mod_negotiation.so +LoadModule dir_module modules/mod_dir.so +#LoadModule imagemap_module modules/mod_imagemap.so +#LoadModule actions_module modules/mod_actions.so +#LoadModule speling_module modules/mod_speling.so +#LoadModule userdir_module modules/mod_userdir.so +LoadModule alias_module modules/mod_alias.so +#LoadModule rewrite_module modules/mod_rewrite.so + + +# +# If you wish httpd to run as a different user or group, you must run +# httpd as root initially and it will switch. +# +# User/Group: The name (or #number) of the user/group to run httpd as. +# It is usually good practice to create a dedicated user and group for +# running httpd, as with most system services. +# +User www-data +Group www-data + + + +# 'Main' server configuration +# +# The directives in this section set up the values used by the 'main' +# server, which responds to any requests that aren't handled by a +# definition. These values also provide defaults for +# any containers you may define later in the file. +# +# All of these directives may appear inside containers, +# in which case these default settings will be overridden for the +# virtual host being defined. +# + +# +# ServerAdmin: Your address, where problems with the server should be +# e-mailed. This address appears on some server-generated pages, such +# as error documents. e.g. admin@your-domain.com +# +ServerAdmin you@example.com + +# +# ServerName gives the name and port that the server uses to identify itself. +# This can often be determined automatically, but we recommend you specify +# it explicitly to prevent problems during startup. +# +# If your host doesn't have a registered DNS name, enter its IP address here. +# +#ServerName www.example.com:80 + +# +# Deny access to the entirety of your server's filesystem. You must +# explicitly permit access to web content directories in other +# blocks below. +# + + AllowOverride none + Require all denied + + +# +# Note that from this point forward you must specifically allow +# particular features to be enabled - so if something's not working as +# you might expect, make sure that you have specifically enabled it +# below. +# + +# +# DocumentRoot: The directory out of which you will serve your +# documents. By default, all requests are taken from this directory, but +# symbolic links and aliases may be used to point to other locations. +# +DocumentRoot "/usr/local/apache2/htdocs" + + # + # Possible values for the Options directive are "None", "All", + # or any combination of: + # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews + # + # Note that "MultiViews" must be named *explicitly* --- "Options All" + # doesn't give it to you. + # + # The Options directive is both complicated and important. Please see + # http://httpd.apache.org/docs/2.4/mod/core.html#options + # for more information. + # + Options Indexes FollowSymLinks + + # + # AllowOverride controls what directives may be placed in .htaccess files. + # It can be "All", "None", or any combination of the keywords: + # AllowOverride FileInfo AuthConfig Limit + # + AllowOverride None + + # + # Controls who can get stuff from this server. + # + Require all granted + + Header set Content-Type "text/plain; version=0.0.4" + + + +# +# DirectoryIndex: sets the file that Apache will serve if a directory +# is requested. +# + + DirectoryIndex index.html + + +# +# The following lines prevent .htaccess and .htpasswd files from being +# viewed by Web clients. +# + + Require all denied + + +# +# ErrorLog: The location of the error log file. +# If you do not specify an ErrorLog directive within a +# container, error messages relating to that virtual host will be +# logged here. If you *do* define an error logfile for a +# container, that host's errors will be logged there and not here. +# +ErrorLog /proc/self/fd/2 + +# +# LogLevel: Control the number of messages logged to the error_log. +# Possible values include: debug, info, notice, warn, error, crit, +# alert, emerg. +# +LogLevel warn + + + # + # The following directives define some format nicknames for use with + # a CustomLog directive (see below). + # + LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined + LogFormat "%h %l %u %t \"%r\" %>s %b" common + + + # You need to enable mod_logio.c to use %I and %O + LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio + + + # + # The location and format of the access logfile (Common Logfile Format). + # If you do not define any access logfiles within a + # container, they will be logged here. Contrariwise, if you *do* + # define per- access logfiles, transactions will be + # logged therein and *not* in this file. + # + CustomLog /proc/self/fd/1 common + + # + # If you prefer a logfile with access, agent, and referer information + # (Combined Logfile Format) you can use the following directive. + # + #CustomLog "logs/access_log" combined + + + + # + # Redirect: Allows you to tell clients about documents that used to + # exist in your server's namespace, but do not anymore. The client + # will make a new request for the document at its new location. + # Example: + # Redirect permanent /foo http://www.example.com/bar + + # + # Alias: Maps web paths into filesystem paths and is used to + # access content that does not live under the DocumentRoot. + # Example: + # Alias /webpath /full/filesystem/path + # + # If you include a trailing / on /webpath then the server will + # require it to be present in the URL. You will also likely + # need to provide a section to allow access to + # the filesystem path. + + # + # ScriptAlias: This controls which directories contain server scripts. + # ScriptAliases are essentially the same as Aliases, except that + # documents in the target directory are treated as applications and + # run by the server when requested rather than as documents sent to the + # client. The same rules about trailing "/" apply to ScriptAlias + # directives as to Alias. + # + ScriptAlias /cgi-bin/ "/usr/local/apache2/cgi-bin/" + + + + + # + # ScriptSock: On threaded servers, designate the path to the UNIX + # socket used to communicate with the CGI daemon of mod_cgid. + # + #Scriptsock cgisock + + +# +# "/usr/local/apache2/cgi-bin" should be changed to whatever your ScriptAliased +# CGI directory exists, if you have that configured. +# + + AllowOverride None + Options None + Require all granted + + + + # + # Avoid passing HTTP_PROXY environment to CGI's on this or any proxied + # backend servers which have lingering "httpoxy" defects. + # 'Proxy' request header is undefined by the IETF, not listed by IANA + # + RequestHeader unset Proxy early + + + + # + # TypesConfig points to the file containing the list of mappings from + # filename extension to MIME-type. + # + TypesConfig conf/mime.types + + # + # AddType allows you to add to or override the MIME configuration + # file specified in TypesConfig for specific file types. + # + #AddType application/x-gzip .tgz + # + # AddEncoding allows you to have certain browsers uncompress + # information on the fly. Note: Not all browsers support this. + # + #AddEncoding x-compress .Z + #AddEncoding x-gzip .gz .tgz + # + # If the AddEncoding directives above are commented-out, then you + # probably should define those extensions to indicate media types: + # + AddType application/x-compress .Z + AddType application/x-gzip .gz .tgz + + # + # AddHandler allows you to map certain file extensions to "handlers": + # actions unrelated to filetype. These can be either built into the server + # or added with the Action directive (see below) + # + # To use CGI scripts outside of ScriptAliased directories: + # (You will also need to add "ExecCGI" to the "Options" directive.) + # + #AddHandler cgi-script .cgi + + # For type maps (negotiated resources): + #AddHandler type-map var + + # + # Filters allow you to process content before it is sent to the client. + # + # To parse .shtml files for server-side includes (SSI): + # (You will also need to add "Includes" to the "Options" directive.) + # + #AddType text/html .shtml + #AddOutputFilter INCLUDES .shtml + + +# +# The mod_mime_magic module allows the server to use various hints from the +# contents of the file itself to determine its type. The MIMEMagicFile +# directive tells the module where the hint definitions are located. +# +#MIMEMagicFile conf/magic + +# +# Customizable error responses come in three flavors: +# 1) plain text 2) local redirects 3) external redirects +# +# Some examples: +#ErrorDocument 500 "The server made a boo boo." +#ErrorDocument 404 /missing.html +#ErrorDocument 404 "/cgi-bin/missing_handler.pl" +#ErrorDocument 402 http://www.example.com/subscription_info.html +# + +# +# MaxRanges: Maximum number of Ranges in a request before +# returning the entire resource, or one of the special +# values 'default', 'none' or 'unlimited'. +# Default setting is to accept 200 Ranges. +#MaxRanges unlimited + +# +# EnableMMAP and EnableSendfile: On systems that support it, +# memory-mapping or the sendfile syscall may be used to deliver +# files. This usually improves server performance, but must +# be turned off when serving from networked-mounted +# filesystems or if support for these functions is otherwise +# broken on your system. +# Defaults: EnableMMAP On, EnableSendfile Off +# +#EnableMMAP off +#EnableSendfile on + +# Supplemental configuration +# +# The configuration files in the conf/extra/ directory can be +# included to add extra features or to modify the default configuration of +# the server, or you may simply copy their contents here and change as +# necessary. + +# Server-pool management (MPM specific) +#Include conf/extra/httpd-mpm.conf + +# Multi-language error messages +#Include conf/extra/httpd-multilang-errordoc.conf + +# Fancy directory listings +#Include conf/extra/httpd-autoindex.conf + +# Language settings +#Include conf/extra/httpd-languages.conf + +# User home directories +#Include conf/extra/httpd-userdir.conf + +# Real-time info on requests and configuration +#Include conf/extra/httpd-info.conf + +# Virtual hosts +#Include conf/extra/httpd-vhosts.conf + +# Local access to the Apache HTTP Server Manual +#Include conf/extra/httpd-manual.conf + +# Distributed authoring and versioning (WebDAV) +#Include conf/extra/httpd-dav.conf + +# Various default settings +#Include conf/extra/httpd-default.conf + +# Configure mod_proxy_html to understand HTML4/XHTML1 + +Include conf/extra/proxy-html.conf + + +# Secure (SSL/TLS) connections +#Include conf/extra/httpd-ssl.conf +# +# Note: The following must must be present to support +# starting without SSL on platforms with no /dev/random equivalent +# but a statically compiled-in mod_ssl. +# + +SSLRandomSeed startup builtin +SSLRandomSeed connect builtin + + diff --git a/static-exporter/main.libsonnet b/static-exporter/main.libsonnet index 229d9bc4e..78856c82a 100644 --- a/static-exporter/main.libsonnet +++ b/static-exporter/main.libsonnet @@ -2,6 +2,7 @@ local k = import 'ksonnet-util/kausal.libsonnet'; { new(name, image='httpd:2.4-alpine'):: { + name:: name, data:: { metrics: '' }, local configMap = k.core.v1.configMap, @@ -18,6 +19,7 @@ local k = import 'ksonnet-util/kausal.libsonnet'; , local deployment = k.apps.v1.deployment, + local volumeMount = k.core.v1.volumeMount, deployment: deployment.new(name, replicas=1, containers=[self.container]) + k.util.configMapVolumeMount(self.configmap, '/usr/local/apache2/htdocs'), @@ -46,6 +48,18 @@ local k = import 'ksonnet-util/kausal.libsonnet'; ), }), + withHttpConfig(config=(importstr 'httpd.conf')):: { + local configMap = k.core.v1.configMap, + local volumeMount = k.core.v1.volumeMount, + httpdConfig: + configMap.new(self.name + '-httpd-config') + + configMap.withData({ + 'httpd.conf': config, + }), + deployment+: + k.util.configMapVolumeMount(self.httpdConfig, '/usr/local/apache2/conf/httpd.conf', volumeMount.withSubPath('httpd.conf')), + }, + metric:: { new(name, description):: self.withName(name) From deb2c73728a12b089d5597b620454d0782ccec20 Mon Sep 17 00:00:00 2001 From: George Krajcsovits Date: Tue, 3 Dec 2024 10:07:45 +0100 Subject: [PATCH 10/14] utils: fix how we hide/show native histogram queries (#1362) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Due to https://github.com/prometheus/prometheus/pull/15245 the previous trick doesn't work for us to exclude/include all results from a PromQL query. Signed-off-by: György Krajcsovits --- mixin-utils/utils.libsonnet | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mixin-utils/utils.libsonnet b/mixin-utils/utils.libsonnet index f80fc681e..7eabb5f0f 100644 --- a/mixin-utils/utils.libsonnet +++ b/mixin-utils/utils.libsonnet @@ -180,10 +180,10 @@ local g = import 'grafana-builder/grafana.libsonnet'; // showClassicHistogramQuery wraps a query defined as map {classic: q, native: q}, and compares the classic query // to dashboard variable which should take -1 or +1 as values in order to hide or show the classic query. - showClassicHistogramQuery(query, dashboard_variable='latency_metrics'):: '%s < ($%s * +Inf)' % [query.classic, dashboard_variable], + showClassicHistogramQuery(query, dashboard_variable='latency_metrics'):: '(%s) and on() (vector($%s) == 1)' % [query.classic, dashboard_variable], // showNativeHistogramQuery wraps a query defined as map {classic: q, native: q}, and compares the native query // to dashboard variable which should take -1 or +1 as values in order to show or hide the native query. - showNativeHistogramQuery(query, dashboard_variable='latency_metrics'):: '%s < ($%s * -Inf)' % [query.native, dashboard_variable], + showNativeHistogramQuery(query, dashboard_variable='latency_metrics'):: '(%s) and on() (vector($%s) == -1)' % [query.native, dashboard_variable], histogramRules(metric, labels, interval='1m', record_native=false):: local vars = { From 767befa8fb46a07be516dec2777d7d89909a529d Mon Sep 17 00:00:00 2001 From: Emily <1282515+Dasomeone@users.noreply.github.com> Date: Wed, 4 Dec 2024 12:50:41 +0100 Subject: [PATCH 11/14] Update ceph overview dashboard stat panels to support Light Mode (#1358) * Update ceph overview dashboard stat panels to support Light Mode Also updates the schema for the dashboard to schemaversion 40, with some plugin syntax updates * Add empty jsonnetfile.json to satisfy CI requirements expecting dependencies --- ceph-mixin/dashboards/ceph-cluster.json | 857 +++++++++++++----------- ceph-mixin/jsonnetfile.json | 0 2 files changed, 454 insertions(+), 403 deletions(-) create mode 100644 ceph-mixin/jsonnetfile.json diff --git a/ceph-mixin/dashboards/ceph-cluster.json b/ceph-mixin/dashboards/ceph-cluster.json index 14aecbe85..f46043fb8 100644 --- a/ceph-mixin/dashboards/ceph-cluster.json +++ b/ceph-mixin/dashboards/ceph-cluster.json @@ -24,18 +24,12 @@ "description": "Ceph Cluster overview.\r ", "editable": true, "fiscalYearStartMonth": 0, - "gnetId": 2842, "graphTooltip": 0, - "id": 4, + "id": 782, "links": [], - "liveNow": false, "panels": [ { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -44,15 +38,6 @@ }, "id": 37, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "CLUSTER STATE", "type": "row" }, @@ -104,8 +89,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -117,13 +101,13 @@ }, "id": 21, "interval": "1m", - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "center", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -136,7 +120,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -152,6 +136,7 @@ "step": 300 } ], + "title": "", "transparent": true, "type": "stat" }, @@ -161,6 +146,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 1, "mappings": [ { @@ -182,8 +170,7 @@ } ] }, - "unit": "Bps", - "unitScale": true + "unit": "Bps" }, "overrides": [] }, @@ -194,13 +181,13 @@ "y": 1 }, "id": 92, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -213,7 +200,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -237,6 +224,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 1, "mappings": [ { @@ -258,8 +248,7 @@ } ] }, - "unit": "Bps", - "unitScale": true + "unit": "Bps" }, "overrides": [] }, @@ -270,13 +259,13 @@ "y": 1 }, "id": 93, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -289,7 +278,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -313,6 +302,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "mappings": [ { "options": { @@ -333,8 +325,7 @@ } ] }, - "unit": "decbytes", - "unitScale": true + "unit": "decbytes" }, "overrides": [] }, @@ -346,13 +337,13 @@ }, "id": 33, "interval": "1m", - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "area", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -365,7 +356,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -420,8 +411,7 @@ } ] }, - "unit": "percentunit", - "unitScale": true + "unit": "percentunit" }, "overrides": [] }, @@ -433,7 +423,6 @@ }, "id": 23, "interval": "1m", - "links": [], "maxDataPoints": 100, "options": { "minVizHeight": 75, @@ -451,7 +440,7 @@ "sizing": "auto", "text": {} }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -504,8 +493,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -516,13 +504,13 @@ "y": 1 }, "id": 48, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -535,7 +523,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -559,6 +547,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 1, "mappings": [ { @@ -580,8 +571,7 @@ } ] }, - "unit": "decbytes", - "unitScale": true + "unit": "decbytes" }, "overrides": [] }, @@ -592,13 +582,13 @@ "y": 1 }, "id": 99, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "delta" @@ -611,7 +601,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -635,6 +625,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 1, "mappings": [ { @@ -656,8 +649,7 @@ } ] }, - "unit": "decbytes", - "unitScale": true + "unit": "decbytes" }, "overrides": [] }, @@ -668,13 +660,13 @@ "y": 1 }, "id": 100, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "delta" @@ -687,7 +679,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -729,8 +721,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -741,13 +732,13 @@ "y": 4 }, "id": 75, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -760,7 +751,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -785,6 +776,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 2, "mappings": [ { @@ -806,8 +800,7 @@ } ] }, - "unit": "ops", - "unitScale": true + "unit": "ops" }, "overrides": [] }, @@ -818,13 +811,13 @@ "y": 4 }, "id": 97, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -837,7 +830,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -861,6 +854,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "decimals": 2, "mappings": [ { @@ -882,8 +878,7 @@ } ] }, - "unit": "ops", - "unitScale": true + "unit": "ops" }, "overrides": [] }, @@ -894,13 +889,13 @@ "y": 4 }, "id": 96, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -913,7 +908,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -937,6 +932,9 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, "mappings": [ { "options": { @@ -957,8 +955,7 @@ } ] }, - "unit": "decbytes", - "unitScale": true + "unit": "decbytes" }, "overrides": [] }, @@ -970,13 +967,13 @@ }, "id": 34, "interval": "1m", - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "area", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -989,7 +986,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1038,8 +1035,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -1050,13 +1046,13 @@ "y": 4 }, "id": 102, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1069,7 +1065,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1120,8 +1116,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1133,13 +1128,13 @@ }, "id": 14, "interval": "1m", - "links": [], "maxDataPoints": 100, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1152,7 +1147,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1173,10 +1168,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -1185,15 +1176,6 @@ }, "id": 38, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "OSD STATE", "type": "row" }, @@ -1231,8 +1213,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1243,13 +1224,13 @@ "y": 8 }, "id": 27, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1262,7 +1243,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1315,8 +1296,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1327,13 +1307,13 @@ "y": 8 }, "id": 29, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1346,7 +1326,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1395,8 +1375,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1407,13 +1386,13 @@ "y": 8 }, "id": 28, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1426,7 +1405,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1475,8 +1454,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1487,13 +1465,13 @@ "y": 8 }, "id": 26, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1506,7 +1484,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1559,8 +1537,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [] }, @@ -1571,13 +1548,13 @@ "y": 8 }, "id": 30, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1590,7 +1567,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1643,8 +1620,7 @@ } ] }, - "unit": "ms", - "unitScale": true + "unit": "ms" }, "overrides": [] }, @@ -1655,13 +1631,13 @@ "y": 8 }, "id": 31, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1674,7 +1650,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1727,8 +1703,7 @@ } ] }, - "unit": "ms", - "unitScale": true + "unit": "ms" }, "overrides": [] }, @@ -1739,13 +1714,13 @@ "y": 8 }, "id": 32, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1758,7 +1733,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1812,8 +1787,7 @@ } ] }, - "unit": "ms", - "unitScale": true + "unit": "ms" }, "overrides": [] }, @@ -1824,13 +1798,13 @@ "y": 8 }, "id": 51, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1843,7 +1817,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1895,8 +1869,7 @@ } ] }, - "unit": "ms", - "unitScale": true + "unit": "ms" }, "overrides": [] }, @@ -1907,13 +1880,13 @@ "y": 8 }, "id": 50, - "links": [], "maxDataPoints": 100, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1926,7 +1899,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -1946,10 +1919,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -1958,15 +1927,6 @@ }, "id": 53, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "Alerts", "type": "row" }, @@ -1980,6 +1940,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -2001,8 +1962,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [ { @@ -2033,7 +1993,6 @@ "y": 12 }, "id": 70, - "links": [], "options": { "cellHeight": "sm", "footer": { @@ -2046,7 +2005,7 @@ }, "showHeader": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2104,8 +2063,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [ { @@ -2136,7 +2094,6 @@ "y": 12 }, "id": 105, - "links": [], "options": { "cellHeight": "sm", "footer": { @@ -2149,7 +2106,7 @@ }, "showHeader": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2211,8 +2168,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [ { @@ -2243,7 +2199,6 @@ "y": 12 }, "id": 103, - "links": [], "options": { "cellHeight": "sm", "footer": { @@ -2256,7 +2211,7 @@ }, "showHeader": true }, - "pluginVersion": "10.3.1", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2286,10 +2241,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -2298,15 +2249,6 @@ }, "id": 108, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "Ceph Versions", "type": "row" }, @@ -2326,6 +2268,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -2366,8 +2309,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -2378,7 +2320,6 @@ "y": 19 }, "id": 110, - "links": [], "options": { "legend": { "calcs": [], @@ -2391,7 +2332,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2425,6 +2366,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -2465,8 +2407,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -2477,7 +2418,6 @@ "y": 19 }, "id": 111, - "links": [], "options": { "legend": { "calcs": [], @@ -2490,7 +2430,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2524,6 +2464,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -2564,8 +2505,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -2576,7 +2516,6 @@ "y": 19 }, "id": 112, - "links": [], "options": { "legend": { "calcs": [], @@ -2589,7 +2528,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2623,6 +2562,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -2663,8 +2603,7 @@ } ] }, - "unit": "short", - "unitScale": true + "unit": "short" }, "overrides": [] }, @@ -2675,7 +2614,6 @@ "y": 19 }, "id": 113, - "links": [], "options": { "legend": { "calcs": [], @@ -2688,7 +2626,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2708,10 +2646,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -2720,15 +2654,6 @@ }, "id": 39, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "CLUSTER", "type": "row" }, @@ -2748,6 +2673,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 40, "gradientMode": "none", @@ -2788,8 +2714,7 @@ } ] }, - "unit": "bytes", - "unitScale": true + "unit": "bytes" }, "overrides": [ { @@ -2914,8 +2839,6 @@ "y": 29 }, "id": 1, - "interval": "", - "links": [], "options": { "legend": { "calcs": [ @@ -2933,7 +2856,7 @@ "sort": "desc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -2991,6 +2914,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3031,8 +2955,7 @@ } ] }, - "unit": "none", - "unitScale": true + "unit": "none" }, "overrides": [ { @@ -3119,8 +3042,6 @@ "y": 29 }, "id": 3, - "interval": "", - "links": [], "options": { "legend": { "calcs": [ @@ -3138,7 +3059,7 @@ "sort": "desc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3184,6 +3105,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3224,8 +3146,7 @@ } ] }, - "unit": "decbytes", - "unitScale": true + "unit": "decbytes" }, "overrides": [] }, @@ -3236,8 +3157,6 @@ "y": 29 }, "id": 7, - "interval": "", - "links": [], "options": { "legend": { "calcs": [ @@ -3255,7 +3174,7 @@ "sort": "desc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3296,9 +3215,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3307,6 +3230,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3348,7 +3272,6 @@ "y": 37 }, "id": 78, - "links": [], "options": { "legend": { "calcs": [ @@ -3365,7 +3288,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3393,9 +3316,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3404,6 +3331,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3445,7 +3373,6 @@ "y": 37 }, "id": 114, - "links": [], "options": { "legend": { "calcs": [ @@ -3462,7 +3389,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3489,9 +3416,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3500,6 +3431,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3541,7 +3473,6 @@ "y": 37 }, "id": 79, - "links": [], "options": { "legend": { "calcs": [ @@ -3557,7 +3488,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3584,9 +3515,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3595,6 +3530,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3636,7 +3572,6 @@ "y": 45 }, "id": 80, - "links": [], "options": { "legend": { "calcs": [], @@ -3649,7 +3584,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3676,9 +3611,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3687,6 +3626,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3728,7 +3668,6 @@ "y": 45 }, "id": 81, - "links": [], "options": { "legend": { "calcs": [], @@ -3741,7 +3680,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3768,9 +3707,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3779,6 +3722,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -3819,7 +3763,6 @@ "y": 45 }, "id": 106, - "links": [], "options": { "legend": { "calcs": [], @@ -3832,7 +3775,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -3862,10 +3805,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -3874,15 +3813,6 @@ }, "id": 41, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "OBJECTS", "type": "row" }, @@ -3896,9 +3826,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -3907,6 +3841,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 2, "pointSize": 5, @@ -3963,7 +3898,6 @@ "y": 55 }, "id": 18, - "links": [], "options": { "legend": { "calcs": [], @@ -3976,7 +3910,7 @@ "sort": "asc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4004,9 +3938,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -4015,6 +3953,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 2, "pointSize": 5, @@ -4072,7 +4011,6 @@ "y": 55 }, "id": 19, - "links": [], "options": { "legend": { "calcs": [ @@ -4087,7 +4025,7 @@ "sort": "asc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4349,9 +4287,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -4360,6 +4302,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 2, "pointSize": 5, @@ -4417,7 +4360,6 @@ "y": 55 }, "id": 20, - "links": [], "options": { "legend": { "calcs": [ @@ -4433,7 +4375,7 @@ "sort": "asc" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4485,9 +4427,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -4496,6 +4442,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 2, "pointSize": 5, @@ -4537,7 +4484,6 @@ "y": 61 }, "id": 15, - "links": [], "options": { "legend": { "calcs": [], @@ -4550,7 +4496,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4570,10 +4516,6 @@ }, { "collapsed": false, - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, "gridPos": { "h": 1, "w": 24, @@ -4582,46 +4524,84 @@ }, "id": 40, "panels": [], - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "$datasource" - }, - "refId": "A" - } - ], "title": "LATENCY", "type": "row" }, { - "cards": {}, - "color": { - "cardColor": "#b4ff00", - "colorScale": "sqrt", - "colorScheme": "interpolateOranges", - "exponent": 0.5, - "mode": "opacity" - }, - "dataFormat": "timeseries", "datasource": { "uid": "$datasource" }, + "fieldConfig": { + "defaults": { + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "scaleDistribution": { + "type": "linear" + } + } + }, + "overrides": [] + }, "gridPos": { "h": 8, "w": 12, "x": 0, "y": 68 }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, "id": 83, - "legend": { - "show": true + "options": { + "calculate": true, + "calculation": { + "yBuckets": { + "mode": "count", + "scale": { + "log": 2, + "type": "log" + }, + "value": "1" + } + }, + "cellGap": 2, + "cellValues": {}, + "color": { + "exponent": 0.5, + "fill": "#b4ff00", + "mode": "opacity", + "reverse": false, + "scale": "exponential", + "scheme": "Oranges", + "steps": 128 + }, + "exemplars": { + "color": "rgba(255,0,255,0.7)" + }, + "filterValues": { + "le": 1e-9 + }, + "legend": { + "show": true + }, + "rowsFrame": { + "layout": "auto" + }, + "showValue": "never", + "tooltip": { + "mode": "single", + "showColorScale": false, + "yHistogram": false + }, + "yAxis": { + "axisPlacement": "left", + "min": "0", + "reverse": false, + "unit": "ms" + } }, - "links": [], - "reverseYBuckets": false, + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4637,53 +4617,82 @@ } ], "title": "OSD Apply Latency Distribution", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "xBucketSize": "", - "yAxis": { - "format": "ms", - "logBase": 2, - "min": "0", - "show": true, - "splitFactor": 1 - }, - "yBucketBound": "auto", - "yBucketSize": 10 + "type": "heatmap" }, { - "cards": {}, - "color": { - "cardColor": "#65c5db", - "colorScale": "sqrt", - "colorScheme": "interpolateOranges", - "exponent": 0.5, - "mode": "opacity" - }, - "dataFormat": "timeseries", "datasource": { "uid": "$datasource" }, + "fieldConfig": { + "defaults": { + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "scaleDistribution": { + "type": "linear" + } + } + }, + "overrides": [] + }, "gridPos": { "h": 8, "w": 12, "x": 12, "y": 68 }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, "id": 84, - "legend": { - "show": true + "options": { + "calculate": true, + "calculation": { + "yBuckets": { + "mode": "count", + "scale": { + "log": 2, + "type": "log" + } + } + }, + "cellGap": 2, + "cellValues": {}, + "color": { + "exponent": 0.5, + "fill": "#65c5db", + "mode": "opacity", + "reverse": false, + "scale": "exponential", + "scheme": "Oranges", + "steps": 128 + }, + "exemplars": { + "color": "rgba(255,0,255,0.7)" + }, + "filterValues": { + "le": 1e-9 + }, + "legend": { + "show": true + }, + "rowsFrame": { + "layout": "auto" + }, + "showValue": "never", + "tooltip": { + "mode": "single", + "showColorScale": false, + "yHistogram": false + }, + "yAxis": { + "axisPlacement": "left", + "min": "0", + "reverse": false, + "unit": "ms" + } }, - "links": [], - "reverseYBuckets": false, + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4698,51 +4707,83 @@ } ], "title": "OSD Commit Latency Distribution", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "xBucketSize": "", - "yAxis": { - "format": "ms", - "logBase": 2, - "min": "0", - "show": true - }, - "yBucketBound": "auto" + "type": "heatmap" }, { - "cards": {}, - "color": { - "cardColor": "#806eb7", - "colorScale": "sqrt", - "colorScheme": "interpolateOranges", - "exponent": 0.5, - "mode": "opacity" - }, - "dataFormat": "timeseries", "datasource": { "uid": "$datasource" }, + "fieldConfig": { + "defaults": { + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "scaleDistribution": { + "type": "linear" + } + } + }, + "overrides": [] + }, "gridPos": { "h": 8, "w": 12, "x": 0, "y": 76 }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, "id": 85, - "legend": { - "show": true + "options": { + "calculate": true, + "calculation": { + "yBuckets": { + "mode": "count", + "scale": { + "log": 2, + "type": "log" + } + } + }, + "cellGap": 2, + "cellValues": {}, + "color": { + "exponent": 0.5, + "fill": "#806eb7", + "mode": "opacity", + "reverse": false, + "scale": "exponential", + "scheme": "Oranges", + "steps": 128 + }, + "exemplars": { + "color": "rgba(255,0,255,0.7)" + }, + "filterValues": { + "le": 1e-9 + }, + "legend": { + "show": true + }, + "rowsFrame": { + "layout": "auto" + }, + "showValue": "never", + "tooltip": { + "mode": "single", + "showColorScale": false, + "yHistogram": false + }, + "yAxis": { + "axisPlacement": "left", + "decimals": 2, + "min": "0", + "reverse": false, + "unit": "ms" + } }, - "links": [], - "reverseYBuckets": false, + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4757,52 +4798,83 @@ } ], "title": "OSD Read Op Latency Distribution", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "xBucketSize": "", - "yAxis": { - "decimals": 2, - "format": "ms", - "logBase": 2, - "min": "0", - "show": true - }, - "yBucketBound": "auto" + "type": "heatmap" }, { - "cards": {}, - "color": { - "cardColor": "#f9934e", - "colorScale": "sqrt", - "colorScheme": "interpolateOranges", - "exponent": 0.5, - "mode": "opacity" - }, - "dataFormat": "timeseries", "datasource": { "uid": "$datasource" }, + "fieldConfig": { + "defaults": { + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "scaleDistribution": { + "type": "linear" + } + } + }, + "overrides": [] + }, "gridPos": { "h": 8, "w": 12, "x": 12, "y": 76 }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, "id": 86, - "legend": { - "show": true + "options": { + "calculate": true, + "calculation": { + "yBuckets": { + "mode": "count", + "scale": { + "log": 2, + "type": "log" + } + } + }, + "cellGap": 2, + "cellValues": {}, + "color": { + "exponent": 0.5, + "fill": "#f9934e", + "mode": "opacity", + "reverse": false, + "scale": "exponential", + "scheme": "Oranges", + "steps": 128 + }, + "exemplars": { + "color": "rgba(255,0,255,0.7)" + }, + "filterValues": { + "le": 1e-9 + }, + "legend": { + "show": true + }, + "rowsFrame": { + "layout": "auto" + }, + "showValue": "never", + "tooltip": { + "mode": "single", + "showColorScale": false, + "yHistogram": false + }, + "yAxis": { + "axisPlacement": "left", + "decimals": 2, + "min": "0", + "reverse": false, + "unit": "ms" + } }, - "links": [], - "reverseYBuckets": false, + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4819,23 +4891,7 @@ } ], "title": "OSD Write Op Latency Distribution", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "xBucketSize": "", - "yAxis": { - "decimals": 2, - "format": "ms", - "logBase": 2, - "min": "0", - "show": true - }, - "yBucketBound": "auto" + "type": "heatmap" }, { "datasource": { @@ -4847,9 +4903,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -4858,6 +4918,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -4898,7 +4959,6 @@ "y": 84 }, "id": 44, - "links": [], "options": { "legend": { "calcs": [], @@ -4911,7 +4971,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -4949,9 +5009,13 @@ "mode": "palette-classic" }, "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -4960,6 +5024,7 @@ "tooltip": false, "viz": false }, + "insertNulls": false, "lineInterpolation": "linear", "lineWidth": 1, "pointSize": 5, @@ -5000,7 +5065,6 @@ "y": 84 }, "id": 35, - "links": [], "options": { "legend": { "calcs": [ @@ -5016,7 +5080,7 @@ "sort": "none" } }, - "pluginVersion": "8.4.6", + "pluginVersion": "11.4.0-78678", "targets": [ { "datasource": { @@ -5049,8 +5113,9 @@ "type": "timeseries" } ], + "preload": false, "refresh": "30s", - "schemaVersion": 39, + "schemaVersion": 40, "tags": [ "ceph-integration" ], @@ -5058,38 +5123,29 @@ "list": [ { "current": { - "selected": false, "text": "default", "value": "default" }, - "hide": 0, "includeAll": false, "label": "Data source", - "multi": false, "name": "datasource", "options": [], "query": "prometheus", "refresh": 1, "regex": "(?!grafanacloud-usage|grafanacloud-ml-metrics).+", - "skipUrlSync": false, "type": "datasource" }, { - "allValue": "", "current": { - "isNone": true, - "selected": false, - "text": "None", + "text": "", "value": "" }, "datasource": { "uid": "$datasource" }, "definition": "label_values(ceph_cluster)", - "hide": 0, "includeAll": false, "label": "Cluster", - "multi": false, "name": "ceph_cluster", "options": [], "query": { @@ -5098,12 +5154,7 @@ }, "refresh": 2, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -5139,6 +5190,6 @@ "timezone": "browser", "title": "Ceph - Cluster", "uid": "Dxkv6rnnz", - "version": 3, + "version": 2, "weekStart": "" } \ No newline at end of file diff --git a/ceph-mixin/jsonnetfile.json b/ceph-mixin/jsonnetfile.json new file mode 100644 index 000000000..e69de29bb From 878883856a7a5c40803809e8806f414b15e8c37e Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Tue, 10 Dec 2024 01:19:03 +0800 Subject: [PATCH 12/14] Fix 'mixtool lint' in commonlib/logslib (#1366) --- common-lib/common/variables/variables.libsonnet | 2 +- logs-lib/logs/targets.libsonnet | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/common-lib/common/variables/variables.libsonnet b/common-lib/common/variables/variables.libsonnet index 2e57534b1..951bd94e5 100644 --- a/common-lib/common/variables/variables.libsonnet +++ b/common-lib/common/variables/variables.libsonnet @@ -11,7 +11,7 @@ local utils = import '../utils.libsonnet'; enableLokiLogs=false, customAllValue='.+', prometheusDatasourceName=if enableLokiLogs then 'prometheus_datasource' else 'datasource', - prometheusDatasourceLabel=if enableLokiLogs then 'Prometheus datasource' else 'Data source', + prometheusDatasourceLabel=if enableLokiLogs then 'Prometheus data source' else 'Data source', ): { local varMetricTemplate(varMetric, chainSelector) = // check if chainSelector is not empty string (case when filtering selector is empty): diff --git a/logs-lib/logs/targets.libsonnet b/logs-lib/logs/targets.libsonnet index 4be78130e..9e86aeea0 100644 --- a/logs-lib/logs/targets.libsonnet +++ b/logs-lib/logs/targets.libsonnet @@ -30,7 +30,7 @@ function( sum by (%s) (count_over_time({%s} |~ "$regex_search" %s - [$__interval])) + [$__auto])) ||| % [ logsVolumeGroupBy, variables.queriesSelector, From 0481187306ddd6e033bc548cf136309c0818c47a Mon Sep 17 00:00:00 2001 From: v-zhuravlev Date: Tue, 10 Dec 2024 15:46:23 +0800 Subject: [PATCH 13/14] WIP: Mixin lint fixes (#1367) * Fix mixin lint issues * Fix zookeeper lint * Add newline * Bump mixtool * Bump go in ci --- .github/workflows/build.yml | 4 +- .github/workflows/lint-mixins.yml | 4 +- Makefile | 2 +- common-lib/common/signal/utils.libsonnet | 1 - jvm-observ-lib/.lint | 17 ++---- jvm-observ-lib/panels.libsonnet | 7 +++ jvm-observ-lib/signals/gc.libsonnet | 2 +- kafka-observ-lib/.lint | 70 ++++++++++++++++++++++++ kafka-observ-lib/panels/topic.libsonnet | 1 + memcached-mixin/dashboards.libsonnet | 3 +- process-observ-lib/.lint | 4 ++ windows-mixin/.lint | 20 +++---- windows-observ-lib/.lint | 11 ++++ zookeeper-observ-lib/.lint | 13 +++++ zookeeper-observ-lib/config.libsonnet | 2 +- 15 files changed, 128 insertions(+), 33 deletions(-) create mode 100644 kafka-observ-lib/.lint create mode 100644 windows-observ-lib/.lint create mode 100644 zookeeper-observ-lib/.lint diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0e7f33ab5..d7f86e007 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,7 +18,7 @@ jobs: - name: Setup Go uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2 with: - go-version: 1.18 + go-version: 1.23 - name: Install CI dependencies run: make install-ci-deps - name: Lint and Format @@ -33,7 +33,7 @@ jobs: - name: Setup Go uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2 with: - go-version: 1.18 + go-version: 1.23 - name: Install CI dependencies run: make install-ci-deps - name: Run Tests diff --git a/.github/workflows/lint-mixins.yml b/.github/workflows/lint-mixins.yml index ae6ad24f7..f5393de47 100644 --- a/.github/workflows/lint-mixins.yml +++ b/.github/workflows/lint-mixins.yml @@ -25,7 +25,7 @@ jobs: - name: Setup Go uses: actions/setup-go@v5 with: - go-version: 1.18 + go-version: 1.23 - name: Install CI dependencies run: make install-ci-deps @@ -68,7 +68,7 @@ jobs: - name: Setup Go uses: actions/setup-go@v5 with: - go-version: 1.18 + go-version: 1.23 - name: Install CI dependencies run: make install-ci-deps diff --git a/Makefile b/Makefile index fe2b99331..22eb86874 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ install-ci-deps: go install github.com/google/go-jsonnet/cmd/jsonnet@v0.20.0 go install github.com/google/go-jsonnet/cmd/jsonnetfmt@v0.20.0 go install github.com/google/go-jsonnet/cmd/jsonnet-lint@v0.20.0 - go install github.com/monitoring-mixins/mixtool/cmd/mixtool@a9e78b0942a4186162bf170efde7b4b3167d31a4 + go install github.com/monitoring-mixins/mixtool/cmd/mixtool@a8984473edc33da685bd5f2138eab9cf6a0ff2b7 go install github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb@v0.5.1 fmt: diff --git a/common-lib/common/signal/utils.libsonnet b/common-lib/common/signal/utils.libsonnet index cc169e494..e9a300eef 100644 --- a/common-lib/common/signal/utils.libsonnet +++ b/common-lib/common/signal/utils.libsonnet @@ -53,7 +53,6 @@ if unit == 'seconds' || unit == 's' then 'percent' else if unit == 'requests' then 'rps' else if unit == 'packets' then 'pps' - else if unit == 'short' then '/s' else unit ) else unit, diff --git a/jvm-observ-lib/.lint b/jvm-observ-lib/.lint index 91f57653f..eabfdd70e 100644 --- a/jvm-observ-lib/.lint +++ b/jvm-observ-lib/.lint @@ -1,13 +1,8 @@ exclusions: - panel-title-description-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" + panel-datasource-rule: + entries: + - panel: GC duration + - panel: Allocated/promoted panel-units-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-datasource-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-instance-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-job-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-on-time-change-reload-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" + entries: + - panel: Process files open diff --git a/jvm-observ-lib/panels.libsonnet b/jvm-observ-lib/panels.libsonnet index cbeaf55b3..7ff29543c 100644 --- a/jvm-observ-lib/panels.libsonnet +++ b/jvm-observ-lib/panels.libsonnet @@ -71,6 +71,7 @@ local commonlib = import 'common-lib/common/main.libsonnet'; gcDuration: g.panel.timeSeries.new('GC duration') + + g.panel.timeSeries.panelOptions.withDescription('Major and minor garbage collections') + commonlib.panels.generic.timeSeries.base.stylize() + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + signals.gc.collectionsTimeAvg.asPanelMixin() @@ -79,6 +80,12 @@ local commonlib = import 'common-lib/common/main.libsonnet'; promotedAllocated: g.panel.timeSeries.new('Allocated/promoted') + + g.panel.timeSeries.panelOptions.withDescription( + ||| + 'Allocated' is the size increase of the young generation memory pool after one GC and before the next. It reflects minor GC. + 'Promoted' is the size increase of the old generation memory pool after GC. It reflects full GC. + ||| + ) + commonlib.panels.memory.timeSeries.usageBytes.stylize() + signals.gc.memAllocatedBytes.asPanelMixin() + signals.gc.memAllocated.asPanelMixin() diff --git a/jvm-observ-lib/signals/gc.libsonnet b/jvm-observ-lib/signals/gc.libsonnet index dde4d70ad..23ba5a0a1 100644 --- a/jvm-observ-lib/signals/gc.libsonnet +++ b/jvm-observ-lib/signals/gc.libsonnet @@ -22,7 +22,7 @@ function(this) //gc collections: { name: 'Garbage collections', - description: 'Major and minor garbage collection', + description: 'Major and minor garbage collections', type: 'counter', unit: 'ops', optional: true, diff --git a/kafka-observ-lib/.lint b/kafka-observ-lib/.lint new file mode 100644 index 000000000..9f448de90 --- /dev/null +++ b/kafka-observ-lib/.lint @@ -0,0 +1,70 @@ +exclusions: + panel-units-rule: + entries: + - panel: Process files open + + target-instance-rule: + reason: Instance selector is intentionally dropped in these panels as they represent whole cluster. + entries: + - dashboard: ZooKeeper overview + panel: Current zookeeper role + - dashboard: Kafka overview + panel: Current role + - dashboard: Kafka overview + panel: Active kafka controllers + - dashboard: Kafka overview + panel: Brokers count + - dashboard: Kafka overview + panel: Brokers count + - dashboard: Kafka overview + panel: Cluster network throughput + - dashboard: Kafka overview + panel: Cluster messages throughput + - dashboard: Kafka topic overview + panel-datasource-rule: + entries: + - panel: GC duration + - panel: Allocated/promoted + - panel: Cluster network throughput + - panel: Cluster messages throughpu + - panel: Broker network throughput + - panel: Broker messages throughput + - panel: Producer ($instance) + - panel: Fetch-follower ($instance) + - panel: Fetch-consumer ($instance) + - panel: Cluster network throughput + dashboard: Kafka overview + - panel: Cluster messages throughput + dashboard: Kafka overview + - panel: Broker network throughput + dashboard: Kafka overview + - panel: Broker messages throughput + dashboard: Kafka overview + - panel: Consumer group overview + dashboard: Kafka topic overview + - panel: Topic overview + dashboard: Kafka topic overview + + panel-title-description-rule: + entries: + - panel: Cluster network throughput + dashboard: Kafka overview + - panel: Cluster messages throughput + dashboard: Kafka overview + - panel: Broker network throughput + dashboard: Kafka overview + - panel: Broker messages throughput + dashboard: Kafka overview + - panel: Consumer group overview + dashboard: Kafka topic overview + template-instance-rule: + reason: kafka_cluster is used intead + entries: + - dashboard: Kafka topic overview + + target-job-rule: + reason: kafka_cluster is used intead + template-job-rule: + reason: kafka_cluster is used intead + + diff --git a/kafka-observ-lib/panels/topic.libsonnet b/kafka-observ-lib/panels/topic.libsonnet index d0d685ae6..6218be07b 100644 --- a/kafka-observ-lib/panels/topic.libsonnet +++ b/kafka-observ-lib/panels/topic.libsonnet @@ -15,6 +15,7 @@ local commonlib = import 'common-lib/common/main.libsonnet'; // Requirements for this table's data topicTable: signals.topic.topicLogStartOffset.asTable(name='Topic overview', format='time_series') + + g.panel.table.panelOptions.withDescription('Kafka active topics overview. ') + signals.topic.topicLogEndOffset.asTableColumn(format='time_series') + signals.topic.topicMessagesPerSecByPartition.asTableColumn(format='time_series') + signals.topic.topicLogSize.asTableColumn(format='time_series') diff --git a/memcached-mixin/dashboards.libsonnet b/memcached-mixin/dashboards.libsonnet index 23389fe1e..5356f408c 100644 --- a/memcached-mixin/dashboards.libsonnet +++ b/memcached-mixin/dashboards.libsonnet @@ -118,6 +118,7 @@ local g = (import 'grafana-builder/grafana.libsonnet'); 'Value #B': { alias: 'Uptime', type: 'number', unit: 'dtdurations' }, }) ) - ), + ) + { editable: false }, }, } diff --git a/process-observ-lib/.lint b/process-observ-lib/.lint index e69de29bb..d45eb99ad 100644 --- a/process-observ-lib/.lint +++ b/process-observ-lib/.lint @@ -0,0 +1,4 @@ +exclusions: + panel-units-rule: + entries: + - panel: Process files open diff --git a/windows-mixin/.lint b/windows-mixin/.lint index 46b67229d..6f948fdcb 100644 --- a/windows-mixin/.lint +++ b/windows-mixin/.lint @@ -1,17 +1,11 @@ exclusions: panel-units-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-datasource-rule: - reason: "Based on new convention we are using variable names prometheus_datasource and loki_datasource where as linter expects 'datasource'" + entries: + - panel: Disk average queue + - panel: CPU count template-instance-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - template-on-time-change-reload-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - target-instance-rule: - reason: "Failing with new dashboard linter. TODO: Investigate and remove the warning exclusion" - target-job-rule: - reason: "mixtool upgrade made this rule stricter. TODO: Fix errors and remove the warning exclusion" - target-promql-rule: - reason: "Linter does not support all LogQL queries and gives ivalid PromQL query error" + reason: "These dashboards are designed to be single instance" entries: - - dashboard: "Windows logs" + - dashboard: Windows overview + - dashboard: Windows CPU and system + - dashboard: Windows disks and filesystems diff --git a/windows-observ-lib/.lint b/windows-observ-lib/.lint new file mode 100644 index 000000000..6f948fdcb --- /dev/null +++ b/windows-observ-lib/.lint @@ -0,0 +1,11 @@ +exclusions: + panel-units-rule: + entries: + - panel: Disk average queue + - panel: CPU count + template-instance-rule: + reason: "These dashboards are designed to be single instance" + entries: + - dashboard: Windows overview + - dashboard: Windows CPU and system + - dashboard: Windows disks and filesystems diff --git a/zookeeper-observ-lib/.lint b/zookeeper-observ-lib/.lint new file mode 100644 index 000000000..67c799f25 --- /dev/null +++ b/zookeeper-observ-lib/.lint @@ -0,0 +1,13 @@ +exclusions: + panel-units-rule: + entries: + - panel: Process files open + panel-datasource-rule: + entries: + - panel: GC duration + - panel: Allocated/promoted + target-instance-rule: + reason: Instance selector is intentionally dropped in these panels as they represent whole cluster. + entries: + - dashboard: ZooKeeper overview + panel: Current zookeeper role diff --git a/zookeeper-observ-lib/config.libsonnet b/zookeeper-observ-lib/config.libsonnet index 0e0ca81ee..0e65a2ca1 100644 --- a/zookeeper-observ-lib/config.libsonnet +++ b/zookeeper-observ-lib/config.libsonnet @@ -1,7 +1,7 @@ { local this = self, filteringSelector: 'job!=""', - groupLabels: ['cluster'], + groupLabels: ['job'], instanceLabels: ['instance'], uid: 'zookeeper', dashboardNamePrefix: '', From 560e36160bc45ba18cfb38f476327eee258cf752 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan-Otto=20Kr=C3=B6pke?= Date: Tue, 10 Dec 2024 08:54:57 +0100 Subject: [PATCH 14/14] Update panels.libsonnet (#1364) Co-authored-by: v-zhuravlev --- windows-observ-lib/panels.libsonnet | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/windows-observ-lib/panels.libsonnet b/windows-observ-lib/panels.libsonnet index 6b436c612..e27bdb760 100644 --- a/windows-observ-lib/panels.libsonnet +++ b/windows-observ-lib/panels.libsonnet @@ -72,7 +72,7 @@ local utils = commonlib.utils; + table.standardOptions.withOverridesMixin([ fieldOverride.byRegexp.new('Product|^Hostname$') + fieldOverride.byRegexp.withProperty('custom.filterable', true), - fieldOverride.byName.new('Instance') + fieldOverride.byName.new(utils.toSentenceCase(instanceLabel)) + fieldOverride.byName.withProperty('custom.filterable', true) + fieldOverride.byName.withProperty('links', [ {