今天在启动elasticsearch的过程中发现启动报错,报错内容如下:
[1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
[2]: system call filters failed to install; check the logs and fix your configuration or disable system call filters at your own risk
第一点,从字面理解,最大虚拟内存区域vm.max_map_count这个参数配置太低,至少需要262144,所以需改这个参数,方法有如下两种:
sudo sysctl -w vm.max_map_count=262144
或者
修改文件/etc/sysctl.conf 中的vm.max_map_count=262144
现在来看看第二点,这是在因为Centos6不支持SecComp,而elasticsearch默认bootstrap.system_call_filter为true进行检测,所以导致检测失败,失败后直接导致ES不能启动,在elasticsearch.yml中配置bootstrap.system_call_filter为false
bootstrap.memory_lock: false
bootstrap.system_call_filter: false
到此问题解决