ERROR: [1] bootstrap checks failed [1]: max virtual memory areas vm.max_map_count [65530] is too low
生活随笔
收集整理的這篇文章主要介紹了
ERROR: [1] bootstrap checks failed [1]: max virtual memory areas vm.max_map_count [65530] is too low
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
今天在運行ElasticSearch集群的時候,發現報了下面的錯誤,
{"type": "deprecation", "timestamp": "2022-01-26T07:58:54,866Z", "level": "WARN", "component": "o.e.d.c.s.Settings", "cluster.name": "my-es", "node.name": "es-master-3", "message": "[discovery.zen.ping.unicast.hosts] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version." } {"type": "deprecation", "timestamp": "2022-01-26T07:58:54,882Z", "level": "WARN", "component": "o.e.d.c.s.Settings", "cluster.name": "my-es", "node.name": "es-master-3", "message": "[discovery.zen.minimum_master_nodes] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version." } {"type": "server", "timestamp": "2022-01-26T07:59:05,217Z", "level": "INFO", "component": "o.e.x.s.a.s.FileRolesStore", "cluster.name": "my-es", "node.name": "es-master-3", "message": "parsed [0] roles from file [/usr/share/elasticsearch/config/roles.yml]" } {"type": "server", "timestamp": "2022-01-26T07:59:08,561Z", "level": "INFO", "component": "o.e.x.m.p.l.CppLogMessageHandler", "cluster.name": "my-es", "node.name": "es-master-3", "message": "[controller/87] [Main.cc@110] controller (64 bit): Version 7.6.2 (Build e06ef9d86d5332) Copyright (c) 2020 Elasticsearch BV" } {"type": "server", "timestamp": "2022-01-26T07:59:13,427Z", "level": "DEBUG", "component": "o.e.a.ActionModule", "cluster.name": "my-es", "node.name": "es-master-3", "message": "Using REST wrapper from plugin org.elasticsearch.xpack.security.Security" } {"type": "server", "timestamp": "2022-01-26T07:59:15,164Z", "level": "INFO", "component": "o.e.d.DiscoveryModule", "cluster.name": "my-es", "node.name": "es-master-3", "message": "using discovery type [zen] and seed hosts providers [settings]" } {"type": "server", "timestamp": "2022-01-26T07:59:22,616Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "initialized" } {"type": "server", "timestamp": "2022-01-26T07:59:22,617Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "starting ..." } {"type": "server", "timestamp": "2022-01-26T07:59:24,821Z", "level": "INFO", "component": "o.e.t.TransportService", "cluster.name": "my-es", "node.name": "es-master-3", "message": "publish_address {172.18.12.23:9303}, bound_addresses {[::]:9303}" } {"type": "server", "timestamp": "2022-01-26T07:59:26,236Z", "level": "INFO", "component": "o.e.b.BootstrapChecks", "cluster.name": "my-es", "node.name": "es-master-3", "message": "bound or publishing to a non-loopback address, enforcing bootstrap checks" } ERROR: [1] bootstrap checks failed [1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144] ERROR: Elasticsearch did not exit normally - check the logs at /usr/share/elasticsearch/logs/my-es.log {"type": "server", "timestamp": "2022-01-26T07:59:26,277Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "stopping ..." } {"type": "server", "timestamp": "2022-01-26T07:59:26,327Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "stopped" } {"type": "server", "timestamp": "2022-01-26T07:59:26,328Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "closing ..." } {"type": "server", "timestamp": "2022-01-26T07:59:26,435Z", "level": "INFO", "component": "o.e.n.Node", "cluster.name": "my-es", "node.name": "es-master-3", "message": "closed" } {"type": "server", "timestamp": "2022-01-26T07:59:26,438Z", "level": "INFO", "component": "o.e.x.m.p.NativeController", "cluster.name": "my-es", "node.name": "es-master-3", "message": "Native controller process has stopped - no new native processes can be started" }大致看了一下,是因為ElasticSearch運行的時候最小內存消耗要達到262144,所以,如果是在自己的虛擬機運行,可以臨時調整vm.max_map_count的大小,max_map_count文件包含限制一個進程可以擁有的VMA(虛擬內存區域)的數量,臨時調整的語句如下:
sysctl -w vm.max_map_count=262144
調整之后再運行es集群就不會有問題了。
如果想永久修改vm.max_map_count的大小,則可以使用如下命令:
echo vm.max_map_count=262144>> /etc/sysctl.conf sysctl -p
總結
以上是生活随笔為你收集整理的ERROR: [1] bootstrap checks failed [1]: max virtual memory areas vm.max_map_count [65530] is too low的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 微信公众号缓存严重的问题
- 下一篇: 烽火HG680L_S905L-3B_线刷