Solr 不尝试使用SASL进行身份验证(未知错误)

Solr 不尝试使用SASL进行身份验证(未知错误),solr,apache-zookeeper,Solr,Apache Zookeeper,我试图在ec2上设置zookeeper两个实例。如给定和所示。 我正在尝试运行zookeeper,但失败,出现错误: 命令:bin/zkCli.sh-server localhost:2181 > 2015-03-15 00:22:35,644 [myid:] - INFO [main:ZooKeeper@438] - Initiating client connection, connectString=localhost:2181 sessionTimeout=30000 watch

我试图在ec2上设置zookeeper两个实例。如给定和所示。 我正在尝试运行zookeeper,但失败,出现错误: 命令:
bin/zkCli.sh-server localhost:2181

> 2015-03-15 00:22:35,644 [myid:] - INFO  [main:ZooKeeper@438] - Initiating client connection, connectString=localhost:2181 sessionTimeout=30000 watcher=org.apache.zookeeper.ZooKeeperMain$MyWatcher@3ff0efca
Welcome to ZooKeeper!
2015-03-15 00:22:35,671 [myid:] - INFO  [main-SendThread(localhost:2181):ClientCnxn$SendThread@975] - Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error)
JLine support is enabled
2015-03-15 00:22:35,677 [myid:] - WARN  [main-SendThread(localhost:2181):ClientCnxn$SendThread@1102] - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect
java.net.ConnectException: Connection refused
        at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
        at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:739)
        at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:361)
        at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1081)
[zk: localhost:2181(CONNECTING) 0] 2015-03-15 00:22:36,796 [myid:] - INFO  [main-SendThread(localhost:2181):ClientCnxn$SendThread@975] - Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error)
2015-03-15 00:22:36,797 [myid:] - WARN  [main-SendThread(localhost:2181):ClientCnxn$SendThread@1102] - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect
动物园。如下面所示

tickTime=2000
initLimit=10
syncLimit=5
dataDir=/var/lib/zookeeper
clientPort=2181
server.1=localhost:2888:3888
server.2=<My ec2 private IPs>:2889:3889
tickTime=2000
初始极限=10
syncLimit=5
dataDir=/var/lib/zookeer
clientPort=2181
server.1=localhost:2888:3888
服务器2=:2889:3889
此外,我还在两个ec2实例上创建了myId文件-
/var/lib/zookeeper/myId

我还试图编辑/ect/hosts文件,但仍然面临相同的问题。 还有,如何通过1个命令启动两个zookeeper实例

注意:如果我尝试使用
bin/zkCli.sh start
命令,服务器将成功启动


提前谢谢

查看zk log zookeeper.out,如果存在连接限制错误,请将以下内容配置到zoo.cfg

# the maximum number of client connections.
# increase this if you need to handle more clients
maxClientCnxns=60

这是暂时的错误,对于我来说,一段时间后,它消失了:-

这是我的zoo.conf文件:-

Dir=../data
clientPort=2181
tickTime=2000
initLimit=5

当我忘记
运行%ZOOKEEPER\u HOME%\bin\zkserver.cmd


通过运行,问题已得到解决。

在服务器上更正此属性。属性

默认设置为localhost将其更改为与zookeeper服务器启动ip和端口匹配


zookeeper.connect=0.0.0.0:2181

您确定可以在端口2181上访问zk吗<代码>打开到服务器localhost的套接字连接/127.0.0.1:2181听起来像是zk的连接问题。尝试运行
telnet localhost 2181
并发布输出。在这里。@slayedbylucifer我已经使用
bin/zkCli.sh start
启动了zk,然后尝试
telnet localhost 2181
给出的消息是
telnet:connect to address 127.0.0.1:连接被拒绝
Cool。。。这就是问题所在。您的ZK不接受端口2181上的任何连接。检查你的ZK设置。。。在对任何进一步的问题进行故障排除之前,您应该确保您不能获得
telnet:connect to address 127.0.0.1:Connection-densed
。Zoo.cfg文件的clientPort=2181,是否还有其他需要配置的内容发布命令的输出
netstat-punta | grep 2181