Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cherry-pick: Update the prometheus rules used by the test #1217

Merged
merged 1 commit into from
Aug 17, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 45 additions & 4 deletions drivers/storage/portworx/testspec/prometheusRule.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ spec:
description: Portworx storage on {{$labels.instance}} is over 80% used
for more than 5 minutes.
summary: Portworx storage on {{$labels.instance}} is at {{$value}}% used.
expr: 100 * (px_cluster_disk_utilized_bytes / px_cluster_disk_total_bytes)
> 80
expr: 100 * (px_cluster_disk_utilized_bytes / px_cluster_disk_total_bytes) > 80
for: 5m
labels:
issue: Portworx storage usage on {{$labels.instance}} is critical.
Expand All @@ -93,8 +92,7 @@ spec:
description: Portworx storage on {{$labels.instance}} is over 70% used
for more than 5 minutes.
summary: Portworx storage on {{$labels.instance}} is at {{$value}}% used.
expr: 100 * (px_cluster_disk_utilized_bytes / px_cluster_disk_total_bytes)
> 70
expr: 100 * (px_cluster_disk_utilized_bytes / px_cluster_disk_total_bytes) > 70
for: 5m
labels:
issue: Portworx storage usage on {{$labels.instance}} is high.
Expand Down Expand Up @@ -263,3 +261,46 @@ spec:
resource_name: "{{$labels.volumeid}}"
scrape_target_type: portworx-node
scrape_target_name: "{{$labels.node}}"
- name: Portworx License Alerts
rules:
- alert: PortworxLicenseExpiry
# Tuneable license-expiry alert, reported by each node individually, works for both regular and floating licenses.
# - note: if #days drops into negative, the license has already expired
expr: px_node_status_license_expiry < 5
labels:
issue: Portworx license (or license lease) expiring.
severity: warning
resource_type: portworx-node
resource_name: "{{$labels.node}}"
scrape_target_type: portworx-node
scrape_target_name: "{{$labels.node}}"
annotations:
summary: Portworx license (or license lease) expiring in {{$value}} days.
description: Portworx node {{$labels.node}} of cluster {{$labels.cluster}} reports
its license (or license lease) expiring in {{$value}} days.
- alert: PortworxLicenseServerDown
expr: px_alerts_licenseserverdown > 0
labels:
severity: warning
issue: Portworx license server is unreachable
resource_type: portworx-node
resource_name: "{{$labels.node}}"
scrape_target_type: portworx-node
scrape_target_name: "{{$labels.node}}"
annotations:
summary: Portworx instance {{$labels.instance}} is not able to reach the license server.
description: Portworx license server is unreachable. Please check license
server health and connection to license server.
- alert: PortworxLicenseSetupError
expr: px_alerts_floatinglicensesetuperror > 0
labels:
issue: Error setting up Portworx license
severity: critical
resource_type: portworx-node
resource_name: "{{$labels.node}}"
scrape_target_type: portworx-node
scrape_target_name: "{{$labels.node}}"
annotations:
summary: Failed to set up Portworx license on {{$labels.instance}}.
description: Failed to set up Portworx license on {{$labels.instance}}.
Please check licenses and/or license server.
Loading