Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Zookeeper average client session timeout

Solved Go to solution
Highlighted

Zookeeper average client session timeout

Explorer

Hello Team,

 

Consider i have a client which is negotiating a timeout from the ZK server.

 

I have observed that 0x36e18413b196cfc  is the session id and i could see that ZK is terminating the connection after 23,419 seconds ??? Could anyone suggest why ?? 

 

 

2020-01-30 01:03:23,762 - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:ZooKeeperServer@861] - Client attempting to renew session 0x36e18413b196cfc at /xx.xx.xx.xx:37952
2020-01-30 01:03:23,762 - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:Learner@108] - Revalidating client: 0x36e18413b196cfc
2020-01-30 01:03:23,762 - INFO [QuorumPeer[myid=1]/0.0.0.0:2181:ZooKeeperServer@617] - Established session 0x36e18413b196cfc with negotiated timeout 10000 for client /xx.xx.xx.xx:37952
EndOfStreamException: Unable to read additional data from client sessionid 0x36e18413b196cfc, likely client has closed socket
2020-01-30 07:33:42,962 - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxn@1033] - Closed socket connection for client //xx.xx.xx.xx:37952 which had sessionid 0x36e18413b196cfc

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Zookeeper average client session timeout

Explorer

The following values are used based on ZooKeeper settings:

 

minSessionTimeout = ticktime * 2,  maxSessionTimeout=ticktime * 20

 

If no Session Timeouts are set in the client, the server will use tickTime*2. Hence, any session which establishes to ZooKeeper, will have this value as a minimum timeout. 
Likewise, if there are no SessionTimout set, the maximum value will be tickTime*20. Hence, any session which establishes to ZooKeeper will have this value as a maximum timeout. 

The sessionTimeout cannot be less than minSessionTimeout (ticktime * 2) or greater than maxSessionTimeout (ticktime * 20)

View solution in original post

2 REPLIES 2
Highlighted

Re: Zookeeper average client session timeout

Explorer

This is on HDP 2.6.5, ZK version : 3.4.6.2

Re: Zookeeper average client session timeout

Explorer

The following values are used based on ZooKeeper settings:

 

minSessionTimeout = ticktime * 2,  maxSessionTimeout=ticktime * 20

 

If no Session Timeouts are set in the client, the server will use tickTime*2. Hence, any session which establishes to ZooKeeper, will have this value as a minimum timeout. 
Likewise, if there are no SessionTimout set, the maximum value will be tickTime*20. Hence, any session which establishes to ZooKeeper will have this value as a maximum timeout. 

The sessionTimeout cannot be less than minSessionTimeout (ticktime * 2) or greater than maxSessionTimeout (ticktime * 20)

View solution in original post

Don't have an account?
Coming from Hortonworks? Activate your account here