We use cookies on this website. To find out more about cookies and how they are used on this website, see our Privacy Policy.
By clicking ‘Continue’, you hereby agree with our use of cookies.

{{vmH.selected.familySearch.replace("EonStor ", "")}} Maintenance Guide

{{vmH.selected.familySearch.replace("EonStor ", "")}} User Guide

Maintenance Guide

Configuring a Prometheus Rule

KS / KS 5000U / KSi 5024U

Prometheus rules are a set of expressions used to define alert conditions or recording rules, including alerting rules and recording rules. These rules are written according to Prometheus' query language PromQL by defining specific PromQL statements to match specific monitoring indicators (such as CPU usage, remaining memory, etc.). You can configure alarm triggering conditions based on application requirements to trigger alarms or record data.

  • Alerting Rules: Set rules alarm based on system resources and application performance. For example, trigger an alert when the CPU usage exceeds a certain threshold, the disk space is insufficient, or the network latency exceeds the configured threshold.
  • Recording Rules: Store complex query results as new time series data, which can reduce query load and improve performance.
Note:

To create a Prometheus rule, you can only add recording rules or alerting rules in a Prometheus rule.

Procedure

  1. Go to EonKube > Monitoring > Advanced > PrometheusRules.
  2. Click Create.
  3. Specify the following settings:
    • Namespace: Choose a namespace.
    • Name: Specify an identifying name for this rule.
    • (Optional) Description: If needed, specify the description.
  4. Go to Rule Group 1 and specify the group information:
    • Group Name: Specify an identifying name for this group.
    • Override Group Interval: Specify the time interval. The default is 60 seconds.
  5. (Optional) To add a recording rule, go to Recording Rules section and click Add Record to specify the rule information:
    • Time series name: Specify the name of the time series. It must be a valid metric name.
    • PromQL Expression: Prometheus will evaluate the current value of this PromQL expression every evaluation cycle and record the results as a new set of time series with the metric name specified by "record".
    • Labels: Check the key-value pairs. To add more labels, click Add Label.
  6. (Optional) To add an alerting rule, go to Alerting Rules section and click Add Alert to specify the rule information:
    • Alert Name: Specify an identifying name for this alert. It must be a valid tag value.
    • Wait to fire for: Specify the duration. The default is 0 seconds. When the warning trigger time reaches the specified length, the alert is triggered. When the alarm is not triggered for a long enough time, it is considered pending.
    • PromQL Expression: Prometheus will evaluate the current value of this PromQL expression every evaluation cycle and results in time series. These series will become pending/firing alerts.
    • Labels: Check the key-value pairs. To add more labels, click Add Label.
    • Annotations: If needed, click to add more information about this alerting rule, including the Summary / Message / Description / Runbook URL of an alert. A runbook is a set of files on how to handle warnings. Annotation values can be templated.
  7. Click Create.