On Wed, May 26, 2010 at 9:20 AM, abhisek saikia <
agscontact@xxxxxxxxx> wrote:
> Hi All
> I tried a sample using zookeeper.I am getting the below logs and my remote
> service registration is getting locked in host
> Following is the log in the host side
> java.lang.NoClassDefFoundError: javax/management/JMException
> at
> org.apache.zookeeper.server.ZooKeeperServer.registerJMX(ZooKeeperServer.java:345)
> at
> org.apache.zookeeper.server.ZooKeeperServer.startup(ZooKeeperServer.java:371)
> at
> org.apache.zookeeper.server.NIOServerCnxn$Factory.startup(NIOServerCnxn.java:161)
> at
> org.eclipse.ecf.provider.zookeeper.core.ZooDiscoveryContainer$4.run(ZooDiscoveryContainer.java:213)
> at java.lang.Thread.run(Unknown Source)
> Caused by: java.lang.ClassNotFoundException: javax.management.JMException
> at
> org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:489)
> at
> org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:405)
> at
> org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:393)
> at
> org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105)
> at java.lang.ClassLoader.loadClass(Unknown Source)
> at java.lang.ClassLoader.loadClassInternal(Unknown Source)
> ... 5 more
> 86 [pool-1-thread-3] INFO org.apache.zookeeper.ZooKeeper - Client
> environment:zookeeper.version=3.3.0-925362, built on 03/19/2010 18:38 GMT
> --------------------------
> java.net.ConnectException: Connection refused: no further information
> at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
> at sun.nio.ch.SocketChannelImpl.finishConnect(Unknown Source)
> at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1078)
> 1633 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Opening socket connection to server
>
192.168.1.2/192.168.1.2:2001
> 1634 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Socket connection established to
>
192.168.1.2/192.168.1.2:2001, initiating session
> 1634 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] INFO
> org.apache.zookeeper.server.NIOServerCnxn - Accepted socket connection
> from /
192.168.1.2:51110
> 1635 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] WARN
> org.apache.zookeeper.server.NIOServerCnxn - Exception causing close of
> session 0x0 due to java.io.IOException: ZooKeeperServer not running
> 1635 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] INFO
> org.apache.zookeeper.server.NIOServerCnxn - Closed socket connection for
> client /
192.168.1.2:51110 (no session established for client)
> 1635 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Unable to read additional data from
> server sessionid 0x0, likely server has closed socket, closing socket
> connection and attempting reconnect
> 2790 [pool-1-thread-3-SendThread(
192.168.1.2:2002)] INFO
> org.apache.zookeeper.ClientCnxn - Opening socket connection to server
>
192.168.1.2/192.168.1.2:2002
> 2931 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Opening socket connection to server
>
192.168.1.2/192.168.1.2:2001
> 2932 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] INFO
> org.apache.zookeeper.server.NIOServerCnxn - Accepted socket connection
> from /
192.168.1.2:51112
> 2932 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Socket connection established to
>
192.168.1.2/192.168.1.2:2001, initiating session
> 2933 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] WARN
> org.apache.zookeeper.server.NIOServerCnxn - Exception causing close of
> session 0x0 due to java.io.IOException: ZooKeeperServer not running
> 2933 [NIOServerCxn.Factory:
0.0.0.0/0.0.0.0:2001] INFO
> org.apache.zookeeper.server.NIOServerCnxn - Closed socket connection for
> client /
192.168.1.2:51112 (no session established for client)
> 2935 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Unable to read additional data from
> server sessionid 0x0, likely server has closed socket, closing socket
> connection and attempting reconnect
> 3811 [pool-1-thread-3-SendThread(
192.168.1.2:2002)] WARN
> org.apache.zookeeper.ClientCnxn - Session 0x0 for server null, unexpected
> error, closing socket connection and attempting reconnect
> java.net.ConnectException: Connection refused: no further information
> at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
> at sun.nio.ch.SocketChannelImpl.finishConnect(Unknown Source)
> at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1078)
> 4428 [pool-1-thread-2-SendThread(
192.168.1.2:2001)] INFO
> org.apache.zookeeper.ClientCnxn - Opening socket connection to server
>
192.168.1.2/192.168.1.2:2001
> Before in my environment the same sample was working with jmdns.I just took
> zookeeper and zookeper provider jar and added in my
bundle.info and
> commented jmdns.
> My vm arguments for host are
> -Dzoodiscovery.dataDir=zookeeperdata2 -Dzoodiscovery.clientPort=2001
> -Dzoodiscovery.flavor=zoodiscovery.flavor.standalone=
192.168.1.2:2002
> -Xms40m -Xmx512m
>
> Thanks and Regards
> Abhisek
>
>
>
>
>