在vi config/elasticsearch.yml 中的network下添加如下內容:
network.host: 0.0.0.0
vi /etc/sysctl.conf中增加:
vm.max_map_count=655360
接着執行 sysctl -p
vi /etc/security/limits.conf中(brian為es的啟動賬戶)
brian soft nofile 65536 brian hard nofile 131072 * soft nofile 2048 * hard nofile 131072
kill掉所有es的進程,重啟就行了。再不好就重啟服務器(不建議,個人的到可以)
注意,不能是root賬戶啟動。