AI Hints
Home›Elasticsearch Tutorial›Monitoring, Mistakes and OpenSearch
Elasticsearch · Lesson 112 of 120

Monitoring

Is it healthy?.

⏱ 2 min read▶ Video at 1:45:39🎓 Free
Watch this lesson in the Elasticsearch courseWatch on YouTube ↗Full Elasticsearch course

A healthy cluster is boring, and that's good. A few quick requests tell you the health, how big each index is, and how hard each node is working.

  • Health
  • Index sizes
  • Node load

The cat APIs

Cat health shows the color and shard counts. Cat indices lists each index, with documents and size. Cat nodes shows memory, CPU and disk use. Run it. A quick, readable view of the whole cluster.

Dev Tools Consoletext
GET _cat/health?v&h=status,node.total,shards,unassign

GET _cat/indices/products,orders?v&h=index,health,docs.count,store.size&s=index

GET _cat/nodes?v&h=name,heap.percent,cpu,disk.used_percent
Output
# GET _cat/health 200 OK
status node.total shards unassign
yellow          1      4        2

# GET _cat/indices/products,orders 200 OK
index    health docs.count store.size
orders   yellow       2000    216.8kb
products yellow         49     25.2kb

# GET _cat/nodes 200 OK
name   heap.percent cpu disk.used_percent
node-1           15   5             32.94
Also uses _load
catalog orders

What to watch

Watch the health color. Keep heap use under about seventy five percent. Keep disk use under the watermarks, about eighty five percent, or shards stop moving. And watch search latency. Kibana stack monitoring shows all of this as charts.

keyvalue
Healthgreen
Heap< ~75%
Disk< 85% watermark
Latencysearch & indexing

Summary

The cat APIs and cluster health give a quick view, and Kibana monitoring shows it over time. Next, common mistakes to avoid.

Key takeaways
  • _cat/health
  • _cat/indices
  • _cat/nodes
Next up: Common Mistakes — learn from others