简体   繁体   English

弹性搜索集群

[英]Elasticsearch cluster

I have ES cluster with 5 machines.我有 5 台机器的 ES 集群。 One of that machines is always using more resources than other for instance now i see that average load is CPU 7%, Memory 65,其中一台机器总是比其他机器使用更多的资源,例如现在我看到平均负载是 CPU 7%,内存 65,

But i have node4 which is strange because it using 30% of CPU and 86% of memory.但是我有 node4,这很奇怪,因为它使用了 30% 的 CPU 和 86% 的内存。

Machines are totally the same, configuration the same only node4 is only data node.机器完全一样,配置一样只有node4只是数据节点。 And when I compare node4 with other in marvel they are doing almost the same tasks..当我在 Marvel 中将 node4 与其他节点进行比较时,它们所做的任务几乎相同。

Any suggestion how to debug and see why its using more than other?有什么建议如何调试并查看为什么它比其他使用更多?

PS.附注。 Reason why i care because few times my cluster dies because of node4, I did some improvements in app, but still i want to understand what is going on with node4.我之所以关心是因为我的集群很少因为 node4 而死,我在应用程序中做了一些改进,但我仍然想了解 node4 发生了什么。

Two things about your cluster:关于集群的两件事:

  • This is wrong: "all requests are sent to master (node1, node2)"!这是错误的:“所有请求都发送到master(node1,node2)”! You should send the requests in round robin fashion to all the nodes holding data, otherwise you 'll have nodes that simply do more work than others您应该以循环方式将请求发送到所有保存数据的节点,否则您将拥有比其他节点做更多工作的节点
  • You are wasting memory and overall resources by having a lot of small shards... You should consider moving to 1 primary and 1 replica for your indices.由于拥有大量小分片,您正在浪费内存和整体资源......您应该考虑将索引移至 1 个主副本和 1 个副本。 The default (5 primaries, 1 replica) is too much.默认值(5 个主要,1 个副本)太多了。 Your indices are way too small to have 5 shards.您的索引太小,无法包含 5 个分片。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM