tuk
tuk

Reputation: 6862

How to upgrade zookeeper from from 3.4.8 to 3.4.13?

I am trying to upgrade zookeeper from 3.4.8 to 3.4.13.

Before upgrade the content of /usr/lib/zookeeper

drwxr-xr-x  5 root root 4.0K Aug 23 08:39 .
drwxr-xr-x 77 root root  12K Aug 23 08:50 ..
drwxr-xr-x  2 root root 4.0K Aug 23 08:39 bin
lrwxrwxrwx  1 root root   19 May 24 11:25 conf -> /etc/zookeeper/conf
drwxr-xr-x  2 root root 4.0K Aug 23 08:39 lib
-rw-r--r--  1 root root  12K May 24 11:25 LICENSE.txt
-rw-r--r--  1 root root  170 May 24 11:25 NOTICE.txt
-rw-r--r--  1 root root 1.3M Aug 23 08:39 zookeeper-3.4.8.jar
lrwxrwxrwx  1 root root   38 Aug 23 08:39 zookeeper.jar -> /usr/lib/zookeeper/zookeeper-3.4.8.jar

As mentioned in answer I have downloaded the zookeeper from this link and placed the zookeeper-3.4.13.jar in /usr/lib/zookeeper and pointed the symbolic link like below

lrwxrwxrwx  1 root root   39 Aug 30 03:19 zookeeper.jar -> /usr/lib/zookeeper/zookeeper-3.4.13.jar

But on checking the status after resarting zookeeper it is still pointing to 3.4.8

ubuntu@vrni-platform:/etc/zookeeper/conf$ telnet localhost 2181
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
status
Zookeeper version: 3.4.8--1, built on 02/06/2016 03:18 GMT

It appears this is because of the way the jars are loaded from /usr/lib/zookeeper/bin/zkEnv.sh

#release tarball format
for i in "$ZOOBINDIR"/../zookeeper-*.jar
do
  CLASSPATH="$i:$CLASSPATH"
done

Can someone let me know is this some known issue is zkEnv.sh? Is this expected?

Upvotes: 1

Views: 1180

Answers (1)

tuk
tuk

Reputation: 6862

This has been answered in zookeeper mailing list. We should not have multiple zookeeper-<version>.jar in the CLASSPATH.

Upvotes: 1

Related Questions