Make necessary configurations in Kibana to synchronize Elasticsearch alerts to Prometheus so you can use Prometheus to monitor and analyze key performance metrics for Elasticsearch clusters in real time.
Prometheus is an open-source monitoring system with a dimensional data model, flexible query language, efficient time series database and modern alerting approach.
Only Elasticsearch 7.10.2 clusters (with an image version no earlier than 7.10.2_24.3.3_x.x.x) support alert synchronization to Prometheus.
Parameter |
Description |
|---|---|
Name |
User-defined destination name |
Type |
Select PROMETHEUS. |
Settings |
Enter the Pushgateway address of the Prometheus monitor server.
|


Parameter |
Description |
|---|---|
Monitor name |
User-defined monitor name |
Monitor state |
Monitoring status. You are advised to keep this function enabled. |
Method of definition |
Select a method to define monitoring. You are advised to use Define using extraction query.
|
Index |
Index to be monitored |
Time field |
When Define using visual graph is selected, select a time field and define counting parameters such as count. |
Frequency |
Select the monitoring frequency and set the monitoring interval. The options include:
|
Parameter |
Description |
|
|---|---|---|
Define trigger |
Trigger name |
User-defined trigger name. |
Severity level |
Sensitivity of the trigger, that is, how many alerts need to be triggered before an alert is actually sent. 1 indicates the highest sensitivity. |
|
Trigger condition |
Trigger condition. An alert is triggered when the trigger condition is met. NOTE:
You are advised to set a trigger condition that can almost always be triggered so that the queried metrics will always be synchronized to the Pushgateway. |
|
Configure actions |
Action name |
Name of the triggered action. |
Destination |
Select the destination created in 5. |
|
Message |
Defines the body of the message to be published, which must use the JSON format. See the following for an example. {
"metricsName":"hits_total_value", //Prometheus metric name
"metricsLabel": {"label_key1":"label_value1","label_key2":"label_value2"}, //Prometheus labels
"metricsValue":{{ctx.results.0.hits.total.value}}, //Prometheus metric values
"jobName":"job_name" //Prometheus monitor task name
"metricsHelp":"***" //Metric explanation. Optional.
}
|
|
Action throttling |
Message sending interval. It limits the number of notification messages that can be sent over a specified period. For example, if this parameter is set to 10 minutes, Prometheus sends only one alert notification in the next 10 minutes even if the trigger condition is met multiple times. After 10 minutes, Prometheus sends another alert notification if the trigger condition is met again. |
|

As shown in Figure 4, Prometheus can receive a triggered message, meaning the trigger is set successfully.