primers

It is often said that more than half of the memory is allocated to the ES cache. How to check the size of the ES cache? (dry goods | read Elasticsearch heap memory)

practice

Environment introduction

CPU: Intel Xeon E5-2620 v2 (24) @ 2.600GHz
Memory: 128GB
OS: CentOS Linux release 7.9.2009
ES: 7.10.0

ES API view

  • See the help
GET _cat/nodes? help
  • Check the heap memory usage
GET _cat/nodes? v&h=ip,name,heap.*
IP name heap.current heap.percent heap.max 192.168.1.219 node-1 17.2GB 57 30GB
  • Check the machine memory usage
GET _cat/nodes? v&h=ip,name,ram.*
IP name ram. Current ram. Percent ram. Max 192.168.31.219 node-1 78.8GB 63 125.6GB

Linux Tools View

  • Htop view (11259 is the ES process ID)
htop -p 11259

  • Hcache view
./hcache -top 3

  • You can also specify a PID view
./hcache -pid 11259

This article from the
qbit snap