observability: add sample prometheus rule alert definitions#34
Merged
rjarry merged 1 commit intoopenstack-k8s-operators:mainfrom Feb 9, 2026
Merged
Conversation
34debd4 to
6be46ff
Compare
rjarry
requested changes
Feb 9, 2026
rules/sample_ovs_pmd_alerts.yaml
Outdated
| description: | | ||
| PMD thread cpu {{ $labels.cpu }} (numa {{ $labels.numa }}) has more than 200 | ||
| non-voluntary context switches in the last 5 minutes. High context switching | ||
| indicates the PMD is being preempted; this can cause packet loss and degraded |
Contributor
There was a problem hiding this comment.
s/loss/drop/
Packets are never "lost", they are dropped because the system cannot process them fast enough.
rules/README.md
Outdated
| @@ -0,0 +1,56 @@ | |||
| # Prometheus rules for OVS metrics | |||
|
|
|||
| This directory contains **spec-only** [PrometheusRule](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/) fragments for metrics exposed by openstack-network-exporter (OVS/OVN). Prepend one of the headers below to get a full manifest you can apply. | |||
Contributor
There was a problem hiding this comment.
wrap lines to 80 columns please
rules/README.md
Outdated
Comment on lines
43
to
56
| ## Applying rules | ||
|
|
||
| 1. Create a full manifest: paste one of the headers above, then the contents of the sample file (from `spec:` onward). | ||
| 2. Apply in the namespace that your Prometheus's `ruleNamespaceSelector` watches (e.g. `openstack` for RHOSO): | ||
|
|
||
| ```bash | ||
| oc apply -f your-complete-rule.yaml -n openstack | ||
| ``` | ||
|
|
||
| 3. Verify (OpenStack/RHOSO): | ||
|
|
||
| ```bash | ||
| oc get prometheusrules.monitoring.rhobs -n openstack | ||
| ``` |
Contributor
There was a problem hiding this comment.
How can I apply these rules if I don't have openstack?
Add PrometheusRule alert examples based on metrics exposed by openstack-network-exporter. Include README with CRD headers to be used in deployments. Signed-off-by: Abhiram R N <abhiramrn@gmail.com>
6be46ff to
e042656
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add PrometheusRule alert examples based on metrics exposed by openstack-network-exporter.
Include README with CRD headers to be used in deployments.