Member since
08-08-2017
1652
Posts
30
Kudos Received
11
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 2082 | 06-15-2020 05:23 AM | |
| 17296 | 01-30-2020 08:04 PM | |
| 2244 | 07-07-2019 09:06 PM | |
| 8662 | 01-27-2018 10:17 PM | |
| 4899 | 12-31-2017 10:12 PM |
01-01-2019
11:54 AM
by the way , if we restart the zookeper , then open connections are less then ,maxClientCnxns and we still get CONNECTING , this mean zookeper client cant connect to zookeper server
... View more
01-01-2019
11:32 AM
we already do all this steps , if we increase the axClientCnxns=500 or to 5000, then after some time all ports are in used and we get CLOSE_WAIT so increasing it isn't solution , and from the log we not see hint about - why zookper clinet not connect zookper server
... View more
01-01-2019
07:48 AM
hi
all In
my HDP cluster, I install 3 zookeeper-servers and zookeeper client on 3 nodes (
master1 , master2 , master3 ) ,. all nodes are on redhat machine version 7.2 When we run the zookeeper-client from master1 on the
zookeeper server on master1 , we get CONNECTING When we run the zookeeper-client from master1 on the
zookeeper server on master2 , we get CONNECTED When we run the zookeeper-client from master1 on the
zookeeper server on master3 , we get CONNECTED Examples [root@master1 ~]# /usr/hdp/current/zookeeper-client/bin/zookeeper-client -server master1:2181
Connecting to master1:2181
Welcome to ZooKeeper!
JLine support is enabled
[zk: master1:2181(CONNECTING) 0] <-- we get CONNECTING instead to get CONNECTED
[root@master1 ~]# /usr/hdp/current/zookeeper-client/bin/zookeeper-client -server master2:2181
Connecting to master2:2181
Welcome to ZooKeeper!
JLine support is enabled
WATCHER::
WatchedEvent state:SyncConnected type:None path:null
[zk: master2:2181(CONNECTED) 0]
[root@master1 ~]# /usr/hdp/current/zookeeper-client/bin/zookeeper-client -server master3:2181
Connecting to master3:2181
Welcome to ZooKeeper!
JLine support is enabled
WATCHER::
WatchedEvent state:SyncConnected type:None path:null
[zk: master3:2181(CONNECTED) 0]
so problem is only on master1 machine , and actually client cant connected to the zookeeper server on machine - master1 What could be the reason for that? more /etc/zookeeper/2.6.4.0-91/0/zoo.cfg
clientPort=2181
syncLimit=15
autopurge.purgeInterval=24
maxClientCnxns=60
dataDir=/var/hadoop/zookeeper
initLimit=30
tickTime=2000
autopurge.snapRetainCount=30
server.1=master1.sys89.com:2888:3888
server.2=master2.sys89.com:2888:3888
server.3=master3.sys89.com:2888:3888
cat /usr/hdp/current/zookeeper-client/bin/zookeeper-client
#!/bin/bash
export ZOOKEEPER_HOME=/usr/hdp/2.6.4.0-91//zookeeper
export ZOOKEEPER_CONF=${ZOOKEEPER_HOME}/conf
export CLASSPATH=$CLASSPATH:$ZOOKEEPER_CONF:$ZOOKEEPER_HOME/*:$ZOOKEEPER_HOME/lib/*
export ZOOCFGDIR=${ZOOCFGDIR:-$ZOOKEEPER_CONF}
env CLASSPATH=$CLASSPATH ${ZOOKEEPER_HOME}/bin/zkCli.sh "$@"
we check the port 2181 and we get ok status
telnet localhost 2181
Trying ::1
Connected to localhost.
Escape character is '^]'.
... View more
Labels:
12-31-2018
06:14 PM
we noticed about the following: /usr/hdp/2.6.4.0-91/zookeeper/bin/zkCli.sh
Connecting to localhost:2181
Welcome to ZooKeeper!
JLine support is enabled
[zk: localhost:2181(CONNECTING) 0] <-- this should be connected not CONNECTING
... View more
12-31-2018
06:05 PM
we also get this from the zookeper service check Welcome to ZooKeeper!
JLine support is enabled
[zk: zookeper_server.sys54.com:2181(CONNECTING) 0] ls /
Command failed after 1 tries
... View more
12-31-2018
05:23 PM
and after 10min we get that: netstat -nape | awk '{if($5 =="23.1.35.197:2181")print $4, $9;}'
23.1.35.197:34425 -
23.1.35.197:34416 -
23.1.35.197:34392 -
23.1.35.197:34389 -
23.1.35.197:34462 63468/java
23.1.35.197:34401 -
23.1.35.197:34358 -
23.1.35.197:34437 -
23.1.35.197:34361 -
23.1.35.197:34451 63468/java
23.1.35.197:34354 -
23.1.35.197:34360 -
23.1.35.197:34368 -
23.1.35.197:34444 -
23.1.35.197:34459 63468/java
23.1.35.197:34442 -
23.1.35.197:34391 -
23.1.35.197:34440 -
23.1.35.197:34452 63468/java
... View more
12-31-2018
05:11 PM
I get that ( after restart the zookeper service from ambari )
netstat -nape | awk '{if($5 =="23.1.35.197:2181")print $4, $9;}'
23.1.35.197:34065 -
23.1.35.197:34071 -
23.1.35.197:34053 -
23.1.35.197:34066 -
23.1.35.197:34068 -
23.1.35.197:34079 63468/java
23.1.35.197:34082 63468/java
23.1.35.197:34052 -
23.1.35.197:34063 -
23.1.35.197:34069 -
23.1.35.197:34075 63468/java
23.1.35.197:34084 63468/java
23.1.35.197:34061 -
23.1.35.197:34078 63468/java
<br>
... View more
12-31-2018
04:40 PM
What application is running at that particular time? This can be caused by a bug in user code check the offending application with nestat - need to verify Ensure that the configuration setting for the maximum number of client connections is sufficient enough to avoid the loss of connections. - OK update the value of the maxClientCnxns configuration parameter in the ZooKeeper-installation-directory/conf/zoo.cfg file on the zookeeper ensemble. - OK Ensure that you have no system issues with CPU services, memory, disk input/output, or other system resources. - OK Zookeeper is sensitive to NTPD functionality make sure the clock is synchronized in the ensemble. - OK Restart ZooKeepers through Ambari - NO need since we restart couple times and with the same results
... View more
12-31-2018
03:51 PM
we check all your comments and I not see a problem except step 1 , you said "
What application is running at that particular time? This can be caused by a bug in user code check the offending application with nestat" , can you please suggest how to verify ? ( what actualy we need to look on netstat output )
... View more
12-31-2018
01:51 PM
Environment:
HDP 2.6.4 Ambari – 2.6.1 3
zookeeper server hi all, In the first
zookeeper server it seems that even after closing the connection to zookeeper is
not getting closed, which
causes the maximum number of client connections to be reached from a host - we
have maxClientCnxns as 60 in zookeeper config As
a result when a new application comes and tries to create a connection it
fails. Example when Connections are: echo stat | nc 23.1.35.185 2181
Latency min/avg/max: 0/71/399
Received: 3031 Sent: 2407
Connections: 67
Outstanding: 622
Zxid: 0x130000004d
Mode: follower
Node count: 3730 But after some time when connection comes to ~70 we see echo stat | nc 23.1.35.185 2181
Ncat: Connection reset by peer. And We can see also many CLOSE_WAIT java 58936 zookeeper 60u IPv6 381963738 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44983 (CLOSE_WAIT)
java 58936 zookeeper 61u IPv6 381963798 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:45034 (CLOSE_WAIT)
java 58936 zookeeper 62u IPv6 381963667 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44956 (CLOSE_WAIT)
java 58936 zookeeper 63u IPv6 381949363 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44911 (CLOSE_WAIT)
java 58936 zookeeper 64u IPv6 381964358 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44957 (CLOSE_WAIT)
java 58936 zookeeper 65u IPv6 381963638 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44940 (CLOSE_WAIT)
java 58936 zookeeper 66u IPv6 381963640 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44943 (CLOSE_WAIT)
java 58936 zookeeper 67u IPv6 381963642 0t0 TCP zookeper_server.sys54.com:eforward->zookeper_server.sys54.com:44945 (CLOSE_WAIT)
From the zookeeper log 2018-12-26 02:50:46,382 [myid:1]
- WARN [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193]
- Too many connections from /23.1.35.185 - max is 602018-12-26 02:50:46,429 [myid:1]
- WARN
[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.197 - max is 602018-12-26 02:50:46,849 [myid:1]
- WARN
[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.187 - max is 602018-12-26 02:50:47,645 [myid:1]
- WARN [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193]
- Too many connections from /23.1.35.197 - max is 602018-12-26 02:50:47,845 [myid:1]
- WARN
[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.185 - max is 602018-12-26 02:50:48,180 [myid:1]
- WARN
[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.187 - max is 602018-12-26 02:50:49,035 [myid:1]
- WARN [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193]
- Too many connections from /23.1.35.185 - max is 602018-12-26 02:50:49,375 [myid:1]
- WARN
[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.187 - max is 60 In the ambari we can see also Connection failed: [Errno 104] Connection reset
by peer to zookeper_server.sys54.com.:2181 I must to say that this not happening on
zookeeper servers 2 and 3 so any hint why the connection are CLOSE_WAIT ? NOTE - if we increase the maxClientCnxns to 300 , its not help because after some time we get more the 300 connections and then we see from the log 2018-12-26 02:50:49,375 [myid:1] - WARN [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@193] - Too many
connections from /23.1.35.187 - max is 60
... View more
Labels: