Configuring monitoring in Kibana
editConfiguring monitoring in Kibana
editIf you enable the collection of monitoring data in your cluster, you can optionally collect metrics about Kibana.
The following method involves sending the metrics to the production cluster, which ultimately routes them to the monitoring cluster. For an alternative method, see Monitoring Kibana with Metricbeat.
To learn about monitoring in general, see Monitoring the Elastic Stack.
-
Enable the collection of monitoring data in Elastic Stack. Set
xpack.monitoring.collection.enabled
totrue
on the production cluster.For example, you can use the following APIs to review and change this setting:
GET _cluster/settings PUT _cluster/settings { "persistent": { "xpack.monitoring.collection.enabled": true } }
For more information, see Monitoring settings in Elasticsearch and Cluster update settings.
-
Verify that
xpack.monitoring.enabled
andxpack.monitoring.kibana.collection.enabled
are set totrue
in thekibana.yml
file. These are the default values. For more information, see Monitoring settings in Kibana. -
Identify where to send monitoring data. Kibana automatically sends metrics to the Elasticsearch cluster specified in the
elasticsearch.url
setting in thekibana.yml
file. This property has a default value ofhttp://localhost:9200
.In production environments, we strongly recommend using a separate cluster (referred to as the monitoring cluster) to store the data. Using a separate monitoring cluster prevents production cluster outages from impacting your ability to access your monitoring data. It also prevents monitoring activities from impacting the performance of your production cluster.
If X-Pack security is enabled on the production cluster, use an HTTPS URL such as
https://<your_production_cluster>:9200
in this setting. -
If X-Pack security is enabled on the production cluster:
-
Verify that there is a
valid user ID and password in the
elasticsearch.username
andelasticsearch.password
settings in thekibana.yml
file. These values are used when Kibana sends monitoring data to the production cluster. -
Configure Kibana to encrypt communications between the Kibana server and the production cluster. This set up involves generating a server certificate and setting
server.ssl.*
andelasticsearch.ssl.certificateAuthorities
settings in thekibana.yml
file on the Kibana server. For example:server.ssl.key: /path/to/your/server.key server.ssl.certificate: /path/to/your/server.crt
If you are using your own certificate authority to sign certificates, specify the location of the PEM file in the
kibana.yml
file:elasticsearch.ssl.certificateAuthorities: /path/to/your/cacert.pem
For more information, see Configuring Security.
-
Verify that there is a
valid user ID and password in the
- Start Kibana.
- View the monitoring data in Kibana.