Error encountered when installing ElasticSearch on linux

Official website address: ES official website

1. You cannot use the root user to create a new user authorization for operation

Otherwise there will be an error:


Exception in thread "main" java.lang.RuntimeException: don't run elasticsearch as root

2. Start to access 404 and some errors

Solution modification: vim config/elasticsearch.yml added 

network.host: 0.0.0.0
#centerOS7原因启动报错
bootstrap.memory_lock: false
bootstrap.system_call_filter: false
#增加了0.0.0.0出现错误  加入
cluster.initial_master_nodes: ["node-1", "node-2"]

 

3、启动ElasticSearch报错[1]: max file descriptors [4096] for elasticsearch process is too low


修改 etc/security/limits.conf

sudo vi /etc/security/limits.conf
在文件最后面加上

* soft nofile 65536
* hard nofile 65536
* soft nproc 4096
* hard nproc 4096
注:*后面有空格

修改 /etc/sysctl.conf

sudo vi /etc/sysctl.conf
在文件最后面加上

vm.max_map_count=262144
配置重新生效

sysctl -p

4、ERROR: [3] max number of threads [1024] for user [elsearch] is too low, increase to at least [4096]

修改limits.d目录下的配置文件:

vi /etc/security/limits.d/90-nproc.conf

改为4096

* soft    nproc     4096

 

Guess you like

Origin blog.csdn.net/qq_39313596/article/details/107513482