config system setting for elasticsearch
2019-03-26 15:03 divl 阅读(221) 评论(0) 编辑 收藏 举报1. disable swapping. swap 分区会导致garbage collections 花费太多时间,elasticsearch 响应变慢。
方法1:swapoff -a 方法2:vi /etc/security/limits.conf 设置vm.swappiness=1 方法3:设置bootstrap.memory_lock: true ,此方法需给用户分配权限, vi /etc/security/limits.conf。设置 elasticsearch hard memlock unlimited elasticsearch soft memlock unlimited
2. 修改文件描述符限制
vi /etc/security/limits.conf elasticsearch hard nofile 65536 elasticsearch soft nofile 65536 ##此值决定能打开的文件数
3. elasticsearch 使用mmapfs indices。修改系统mmap counts。
vi /etc/sysctl.conf vm.max_map_count=262144
4. use a number of thread pool for different operation
vi /etc/security/limits.conf elasticsearch hard nproc 4096 elasticsearch soft nproc 4096
5.