9951 explained code solutions for 126 technologies


elasticsearchHow can I troubleshoot an Elasticsearch cluster with a yellow status?


  1. First, determine which nodes in the cluster are in a yellow status. This can be done by running the following command:
GET /_cluster/health

The output of the command will show the status of each node in the cluster.

  1. If the yellow status is due to a single node, then investigate the node to determine the cause of the issue. This can be done by running the following command to get the node stats:
GET /_nodes/<node_id>/stats
  1. If the yellow status is due to multiple nodes, then check the cluster settings to make sure they are correct. This can be done by running the following command:
GET /_cluster/settings
  1. Check the cluster logs for errors or warnings that may be related to the yellow status. This can be done by running the following command:
GET /_cluster/logs
  1. Check the cluster state to see if there are any shards that are in an unassigned state. This can be done by running the following command:
GET /_cluster/state
  1. Check the network settings of the nodes in the cluster to make sure they are configured correctly.

  2. Finally, if all else fails, restart the cluster and see if the yellow status persists. This can be done by running the following command:

POST /_cluster/restart

Relevant Links

Edit this code on GitHub