ERROR: bootstrap checks failed
max file descriptors [1024] for elasticsearch process is too low, increase to at least [65536]
处理方案
[root@node1 ~]# vi /etc/security/limits.conf
# /etc/security/limits.conf
hadoop soft nofile 65536
hadoop hard nofile 65536
[root@node1 ~]# sysctl -p
[hadoop@node1 ~]$ ulimit -Hn
![](/qrcode.jpg)
65536
Last login: Sat Feb 25 12:45:11 2017
[root@node1 ~]# su - hadoop
[hadoop@node1 ~]$ cd /opt/es5.0/elasticsearch-5.1.2
[hadoop@node1 elasticsearch-5.1.2]$ cd bin/
[hadoop@node1 bin]$ sh ../../init_env.sh
../../init_env.sh: line 9: ulimit: open files: cannot modify limit: Operation not permitted
[hadoop@node1 bin]$ cat ../../init_env.sh
#!/bin/bash
# add by gaojingsong
# init env
JAVA_HOME=/opt/es5.0/jdk1.8.0_111
PATH=$PATH:$JAVA_HOME/bin
export JAVA_HOME PATH
ulimit -n 262144
[hadoop@node1 bin]$ ulimit -n 262144
-bash: ulimit: open files: cannot modify limit: Operation not permitted
[hadoop@node1 bin]$ ./elasticsearch
[2017-02-25T12:48:32,075][WARN ][o.e.b.JNANatives ] unable to install syscall filter:
java.lang.UnsupportedOperationException: seccomp unavailable: requires kernel 3.5+ with CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER compiled in
at org.elasticsearch.bootstrap.Seccomp.linuxImpl(Seccomp.java:349) ~[elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Seccomp.init(Seccomp.java:630) ~[elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.JNANatives.trySeccomp(JNANatives.java:215) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Natives.trySeccomp(Natives.java:99) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:105) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:176) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:306) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:121) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:112) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.Command.main(Command.java:88) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:89) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:82) [elasticsearch-5.1.2.jar:5.1.2]
[2017-02-25T12:48:48,723][INFO ][o.e.n.Node ] [node-1] initializing ...
[2017-02-25T12:48:52,278][INFO ][o.e.e.NodeEnvironment ] [node-1] using [1] data paths, mounts [[/ (/dev/hdc2)]], net usable_space [7.5gb], net total_space [17.1gb], spins? [possibly], types [ext3]
[2017-02-25T12:48:52,279][INFO ][o.e.e.NodeEnvironment ] [node-1] heap size [1.9gb], compressed ordinary object pointers [true]
[2017-02-25T12:48:52,283][INFO ][o.e.n.Node ] [node-1] node name [node-1], node ID [EdHbn3S_Sxm4Cwz0pMxwRQ]
[2017-02-25T12:48:52,461][INFO ][o.e.n.Node ] [node-1] version[5.1.2], pid[3640], build[c8c4c16/2017-01-11T20:18:39.146Z], OS[Linux/2.6.18-128.el5/amd64], JVM[Oracle Corporation/Java HotSpot(TM) 64-Bit Server VM/1.8.0_111/25.111-b14]
[2017-02-25T12:49:16,001][INFO ][o.e.p.PluginsService ] [node-1] loaded module [aggs-matrix-stats]
[2017-02-25T12:49:16,001][INFO ][o.e.p.PluginsService ] [node-1] loaded module [ingest-common]
[2017-02-25T12:49:16,002][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-expression]
[2017-02-25T12:49:16,002][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-groovy]
[2017-02-25T12:49:16,003][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-mustache]
[2017-02-25T12:49:16,004][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-painless]
[2017-02-25T12:49:16,005][INFO ][o.e.p.PluginsService ] [node-1] loaded module [percolator]
[2017-02-25T12:49:16,006][INFO ][o.e.p.PluginsService ] [node-1] loaded module [reindex]
[2017-02-25T12:49:16,006][INFO ][o.e.p.PluginsService ] [node-1] loaded module [transport-netty3]
[2017-02-25T12:49:16,007][INFO ][o.e.p.PluginsService ] [node-1] loaded module [transport-netty4]
[2017-02-25T12:49:16,008][INFO ][o.e.p.PluginsService ] [node-1] no plugins loaded
[2017-02-25T12:50:37,721][INFO ][o.e.n.Node ] [node-1] initialized
[2017-02-25T12:50:37,722][INFO ][o.e.n.Node ] [node-1] starting ...
[2017-02-25T12:50:43,667][INFO ][o.e.t.TransportService ] [node-1] publish_address {192.168.1.104:9300}, bound_addresses {192.168.1.104:9300}
[2017-02-25T12:50:43,956][INFO ][o.e.b.BootstrapCheck ] [node-1] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks
ERROR: bootstrap checks failed
max file descriptors [1024] for elasticsearch process is too low, increase to at least [65536]
[2017-02-25T12:50:44,001][INFO ][o.e.n.Node ] [node-1] stopping ...
[2017-02-25T12:50:45,189][INFO ][o.e.n.Node ] [node-1] stopped
[2017-02-25T12:50:45,189][INFO ][o.e.n.Node ] [node-1] closing ...
[2017-02-25T12:50:45,974][INFO ][o.e.n.Node ] [node-1] closed
[hadoop@node1 bin]$ ulimit -Hn
1024
处理方案:
[root@node1 ~]# vi /etc/security/limits.conf
# /etc/security/limits.conf
hadoop soft nofile 65536
hadoop hard nofile 65536
[root@node1 ~]# sysctl -p
[hadoop@node1 ~]$ ulimit -Hn
65536
[hadoop@node1 ~]$
[hadoop@node1 bin]$ exit
logout
[root@node1 ~]# su - hadoop
[hadoop@node1 ~]$ cd /opt/es5.0/elasticsearch-5.1.2/bin/
[hadoop@node1 bin]$ ./elasticsearch
[2017-02-25T12:57:44,717][WARN ][o.e.b.JNANatives ] unable to install syscall filter:
java.lang.UnsupportedOperationException: seccomp unavailable: requires kernel 3.5+ with CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER compiled in
at org.elasticsearch.bootstrap.Seccomp.linuxImpl(Seccomp.java:349) ~[elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Seccomp.init(Seccomp.java:630) ~[elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.JNANatives.trySeccomp(JNANatives.java:215) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Natives.trySeccomp(Natives.java:99) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:105) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:176) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:306) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:121) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:112) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.cli.Command.main(Command.java:88) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:89) [elasticsearch-5.1.2.jar:5.1.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:82) [elasticsearch-5.1.2.jar:5.1.2]
[2017-02-25T12:57:49,258][INFO ][o.e.n.Node ] [node-1] initializing ...
[2017-02-25T12:57:49,893][INFO ][o.e.e.NodeEnvironment ] [node-1] using [1] data paths, mounts [[/ (/dev/hdc2)]], net usable_space [7.5gb], net total_space [17.1gb], spins? [possibly], types [ext3]
[2017-02-25T12:57:49,894][INFO ][o.e.e.NodeEnvironment ] [node-1] heap size [1.9gb], compressed ordinary object pointers [true]
[2017-02-25T12:57:49,902][INFO ][o.e.n.Node ] [node-1] node name [node-1], node ID [EdHbn3S_Sxm4Cwz0pMxwRQ]
[2017-02-25T12:57:50,010][INFO ][o.e.n.Node ] [node-1] version[5.1.2], pid[3837], build[c8c4c16/2017-01-11T20:18:39.146Z], OS[Linux/2.6.18-128.el5/amd64], JVM[Oracle Corporation/Java HotSpot(TM) 64-Bit Server VM/1.8.0_111/25.111-b14]
[2017-02-25T12:58:04,978][INFO ][o.e.p.PluginsService ] [node-1] loaded module [aggs-matrix-stats]
[2017-02-25T12:58:04,980][INFO ][o.e.p.PluginsService ] [node-1] loaded module [ingest-common]
[2017-02-25T12:58:04,981][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-expression]
[2017-02-25T12:58:04,982][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-groovy]
[2017-02-25T12:58:04,983][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-mustache]
[2017-02-25T12:58:04,984][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-painless]
[2017-02-25T12:58:04,992][INFO ][o.e.p.PluginsService ] [node-1] loaded module [percolator]
[2017-02-25T12:58:04,996][INFO ][o.e.p.PluginsService ] [node-1] loaded module [reindex]
[2017-02-25T12:58:04,997][INFO ][o.e.p.PluginsService ] [node-1] loaded module [transport-netty3]
[2017-02-25T12:58:04,998][INFO ][o.e.p.PluginsService ] [node-1] loaded module [transport-netty4]
[2017-02-25T12:58:04,999][INFO ][o.e.p.PluginsService ] [node-1] no plugins loaded
[2017-02-25T12:59:42,643][INFO ][o.e.n.Node ] [node-1] initialized
[2017-02-25T12:59:42,644][INFO ][o.e.n.Node ] [node-1] starting ...
[2017-02-25T12:59:43,710][INFO ][o.e.t.TransportService ] [node-1] publish_address {192.168.1.104:9300}, bound_addresses {192.168.1.104:9300}
[2017-02-25T12:59:43,755][INFO ][o.e.b.BootstrapCheck ] [node-1] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks
[2017-02-25T12:59:47,780][WARN ][o.e.m.j.JvmGcMonitorService] [node-1] [gc][young][2][7] duration [3.7s], collections [1]/[3.9s], total [3.7s]/[8.4s], memory [83.6mb]->[27.7mb]/[1.9gb], all_pools {[young] [58.9mb]->[340.8kb]/[66.5mb]}{[survivor] [8.3mb]->[8.3mb]/[8.3mb]}{[old] [16.3mb]->[19.4mb]/[1.9gb]}
[2017-02-25T12:59:47,794][WARN ][o.e.m.j.JvmGcMonitorService] [node-1] [gc][2] overhead, spent [3.7s] collecting in the last [3.9s]
[2017-02-25T12:59:52,205][INFO ][o.e.c.s.ClusterService ] [node-1] new_master {node-1}{EdHbn3S_Sxm4Cwz0pMxwRQ}{X8YXs6i8SoyGLG2PUvhrVg}{192.168.1.104}{192.168.1.104:9300}, reason: zen-disco-elected-as-master ([0] nodes joined)
[2017-02-25T12:59:52,716][INFO ][o.e.g.GatewayService ] [node-1] recovered [0] indices into cluster_state
[2017-02-25T12:59:52,912][INFO ][o.e.h.HttpServer ] [node-1] publish_address {192.168.1.104:9200}, bound_addresses {192.168.1.104:9200}
[2017-02-25T12:59:52,912][INFO ][o.e.n.Node ] [node-1] started