Elasticsearch安装遇到报错

Elasticsearch安装遇到报错

1.不能以root用户运行

报错信息

[root@node4 elasticsearch-2.2.0]# bin/elasticsearch
Exception in thread "main" java.lang.RuntimeException: don't run elasticsearch as root.
    at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:93)
    at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:144)
    at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:285)
    at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:35)
Refer to the log for complete error details.

解决方案,添加用户

[root@node1 home]# useradd bigdata
[root@node1 home]# chown -R bigdata:bigdata elasticsearch-2.2.0/

2 .java.net.NoRouteToHostException: No route to host

报错信息

[bigdata@node4 elasticsearch-2.2.0]$ bin/elasticsearch
[2018-06-17 18:28:47,543][WARN ][bootstrap                ] unable to install syscall filter: seccomp unavailable: requires kernel 3.5+ with CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER compiled in
[2018-06-17 18:28:48,102][INFO ][node                     ] [node-4] version[2.2.0], pid[1323], build[8ff36d1/2016-01-27T13:32:39Z]
[2018-06-17 18:28:48,102][INFO ][node                     ] [node-4] initializing ...
[2018-06-17 18:28:49,009][INFO ][plugins                  ] [node-4] modules [lang-groovy, lang-expression], plugins [], sites []
[2018-06-17 18:28:49,061][INFO ][env                      ] [node-4] using [1] data paths, mounts [[/ (/dev/mapper/vg_node1-lv_root)]], net usable_space [5.9gb], net total_space [8.3gb], spins? [possibly], types [ext4]
[2018-06-17 18:28:49,061][INFO ][env                      ] [node-4] heap size [1015.6mb], compressed ordinary object pointers [true]
[2018-06-17 18:28:51,676][INFO ][node                     ] [node-4] initialized
[2018-06-17 18:28:51,676][INFO ][node                     ] [node-4] starting ...
[2018-06-17 18:28:51,789][INFO ][transport                ] [node-4] publish_address {192.168.174.24:9300}, bound_addresses {192.168.174.24:9300}
[2018-06-17 18:28:51,803][INFO ][discovery                ] [node-4] myelastic/YEwvJL1XR06lpJZ09SPzQQ
[2018-06-17 18:28:51,841][WARN ][transport.netty          ] [node-4] exception caught on transport layer [[id: 0x91d722f9]], closing connection
java.net.NoRouteToHostException: No route to host
    at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
    at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:739)
    at org.jboss.netty.channel.socket.nio.NioClientBoss.connect(NioClientBoss.java:152)
    at org.jboss.netty.channel.socket.nio.NioClientBoss.processSelectedKeys(NioClientBoss.java:105)
    at org.jboss.netty.channel.socket.nio.NioClientBoss.process(NioClientBoss.java:79)
    at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:337)
    at org.jboss.netty.channel.socket.nio.NioClientBoss.run(NioClientBoss.java:42)
    at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
    at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:745)

检查发现,端口没开放,关闭防火墙

[root@node4 elasticsearch-2.2.0]# service iptables stop
iptables: Setting chains to policy ACCEPT: filter          [  OK  ]
iptables: Flushing firewall rules:                         [  OK  ]
iptables: Unloading modules:                               [  OK  ]

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值