From 210fc6286b41d948cffab5869b9bc06201b1dab6 Mon Sep 17 00:00:00 2001 From: Skalador Date: Sat, 11 May 2024 20:01:38 +0200 Subject: [PATCH] Update docs --- docs/examples.md | 2 +- docs/subcmds/alert.md | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/examples.md b/docs/examples.md index 9c5720cd..bd816150 100644 --- a/docs/examples.md +++ b/docs/examples.md @@ -24,7 +24,7 @@ $ omc etcd status ``` - Retrive the prometheus alerts in `firing` or `pending` state: ``` -$ omc alert rule -s firing,pending -o wide +$ omc prometheus alertrule -s firing,pending -o wide GROUP RULE STATE AGE ALERTS ACTIVE SINCE cluster-version UpdateAvailable firing 11s 1 27 Jan 22 14:32 UTC logging_fluentd.alerts FluentdQueueLengthIncreasing pending 27s 1 29 Jan 22 11:48 UTC diff --git a/docs/subcmds/alert.md b/docs/subcmds/alert.md index 7fd5f1cb..eca4afbf 100644 --- a/docs/subcmds/alert.md +++ b/docs/subcmds/alert.md @@ -4,7 +4,7 @@ It allows to retrieve the alerting rules [1](https:/ ## `groups` Retrieve `PrometheusRules` grouped by component: ```yaml -omc alert groups +omc prometheus alertgroup insights -oyaml ``` 1. :man_raising_hand: I'm a code annotation! I can contain `code`, __formatted @@ -12,6 +12,7 @@ omc alert groups
OUTPUT + ```yaml data: groups: @@ -88,7 +89,7 @@ status: success ## `rules` PrometheusRules present in the cluster; it's possible to filter them, as an example by the status, if we are interested only for the `firing` ones we can execute: ``` -$ omc alert rules -s firing +$ omc prometheus alertrules -s firing RULE STATE AGE ALERTS ACTIVE SINCE ClusterNotUpgradeable firing 10s 1 10 Jan 23 10:20 UTC UpdateAvailable firing 17s 1 22 Jan 23 04:59 UTC @@ -103,8 +104,9 @@ CsvAbnormalFailedOver2Min firing 21s 1 12 Jan 23 10:14 UTC
Get AlertingRules by group name + ``` -$ omc alert rule --group etcd +$ omc prometheus alertrule --group etcd RULE STATE AGE ALERTS ACTIVE SINCE etcdMembersDown inactive 9s 0 ---- etcdNoLeader inactive 9s 0 ----