Return-Path: X-Original-To: apmail-hbase-user-archive@www.apache.org Delivered-To: apmail-hbase-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1B9C3FF2C for ; Mon, 1 Apr 2013 04:42:48 +0000 (UTC) Received: (qmail 64747 invoked by uid 500); 1 Apr 2013 04:42:46 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 64699 invoked by uid 500); 1 Apr 2013 04:42:45 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 64668 invoked by uid 99); 1 Apr 2013 04:42:44 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Apr 2013 04:42:44 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,NORMAL_HTTP_TO_IP,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of gaurharidass@gmail.com designates 74.125.83.41 as permitted sender) Received: from [74.125.83.41] (HELO mail-ee0-f41.google.com) (74.125.83.41) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Apr 2013 04:42:37 +0000 Received: by mail-ee0-f41.google.com with SMTP id c1so922802eek.28 for ; Sun, 31 Mar 2013 21:42:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=2W37DoBb0mxdIGynMCcPSrtmb6W/9LMffNUVxgWvoYA=; b=Rw15pnxevE5lC5zihl0RPggW7vbQyLQicjQts/EbTPxdJUE4ZoW9rAdD1SmKGOoeJJ pA/ZQvhstJrJ9RhCF/ph5DNvjYsm2111LenPephTft+9tDZS5zraRkmNUuINJ+g28zQZ c0sygf9MCj/2h3OAt2jTVMEtLJ4dSf2KeDYJO6nz+ivOztATi+Jx9AYqXsIY3fhCmxxa WxSM9DIJJHEa27HX9Xp3faXxO1gC40SRHGIPXdz1J7olutpzHsdtCHtNSEkiXIrKgKWa dZhu64GamiZ80Y8TyehSSJWWDEMk21hCAis0ucts9ZTdGfp+gSRXFOQg6hd3ULMygtpC MThQ== MIME-Version: 1.0 X-Received: by 10.14.184.68 with SMTP id r44mr21252457eem.40.1364791337198; Sun, 31 Mar 2013 21:42:17 -0700 (PDT) Received: by 10.14.207.201 with HTTP; Sun, 31 Mar 2013 21:42:17 -0700 (PDT) In-Reply-To: References: Date: Mon, 1 Apr 2013 10:12:17 +0530 Message-ID: Subject: Re: Please help me how and when to catch java.net.ConnectException in case hbase is not running as it goes on connecting with hbase From: gaurhari dass To: user@hbase.apache.org Content-Type: multipart/alternative; boundary=047d7b3438ecd8c64304d9453e3c X-Virus-Checked: Checked by ClamAV on apache.org --047d7b3438ecd8c64304d9453e3c Content-Type: text/plain; charset=ISO-8859-1 Please hep me in resolving this issue ,above is the log On Mon, Apr 1, 2013 at 10:11 AM, gaurhari dass wrote: > 3/04/01 10:09:15 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:15 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > 13/04/01 10:09:16 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:16 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > 13/04/01 10:09:17 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:17 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > 13/04/01 10:09:18 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:18 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > 13/04/01 10:09:20 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:20 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > 13/04/01 10:09:21 INFO zookeeper.ClientCnxn: Opening socket connection to > server localhost/127.0.0.1:2181. Will not attempt to authenticate using > SASL (unknown error) > 13/04/01 10:09:21 WARN zookeeper.ClientCnxn: 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:592) > at > org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) > > > > On Thu, Mar 28, 2013 at 7:20 PM, Ted Yu wrote: > >> The second sentence below seems incomplete. >> >> Can you give us more information (such as zookeeper log) ? >> >> Thanks >> >> On Thu, Mar 28, 2013 at 3:26 AM, gaurhari dass > >wrote: >> >> > I am using hbase .94.5 version ,I havent mentioned in class path >> > >> > On Thu, Mar 28, 2013 at 5:01 AM, Ted Yu wrote: >> > >> > > bq. org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.exists( >> > > RecoverableZooKeeper.java:172) >> > > >> > > The exception showed problem connecting to zookeeper. >> > > Is hbase-site.xml on the classpath of your app ? >> > > >> > > If so, please check (and pastebin) zookeeper log. >> > > >> > > Providing HBase version would be useful as well. >> > > >> > > On Tue, Mar 26, 2013 at 12:24 AM, gaurhari dass < >> gaurharidass@gmail.com >> > > >wrote: >> > > >> > > > 13/03/26 12:46:14 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:16 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:16 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:17 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:17 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:18 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:18 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:19 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:19 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:20 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:20 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:21 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:21 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:22 INFO zookeeper.ClientCnxn: Opening socket >> connection >> > to >> > > > server localhost/127.0.0.1:2181. Will not attempt to authenticate >> > using >> > > > SASL (unknown error) >> > > > 13/03/26 12:46:22 WARN zookeeper.ClientCnxn: 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:592) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) >> > > > at >> > > org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) >> > > > 13/03/26 12:46:22 WARN zookeeper.RecoverableZooKeeper: Possibly >> > transient >> > > > ZooKeeper exception: >> > > > org.apache.zookeeper.KeeperException$ConnectionLossException: >> > > > KeeperErrorCode = ConnectionLoss for /hbase/hbaseid >> > > > 13/03/26 12:46:22 ERROR zookeeper.RecoverableZooKeeper: ZooKeeper >> > exists >> > > > failed after 3 retries >> > > > 13/03/26 12:46:22 WARN zookeeper.ZKUtil: hconnection Unable to set >> > > watcher >> > > > on znode (/hbase/hbaseid) >> > > > org.apache.zookeeper.KeeperException$ConnectionLossException: >> > > > KeeperErrorCode = ConnectionLoss for /hbase/hbaseid >> > > > at >> > > org.apache.zookeeper.KeeperException.create(KeeperException.java:99) >> > > > at >> > > org.apache.zookeeper.KeeperException.create(KeeperException.java:51) >> > > > at org.apache.zookeeper.ZooKeeper.exists(ZooKeeper.java:1041) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.exists(RecoverableZooKeeper.java:172) >> > > > at >> > > > >> org.apache.hadoop.hbase.zookeeper.ZKUtil.checkExists(ZKUtil.java:450) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.hadoop.hbase.zookeeper.ClusterId.readClusterIdZNode(ClusterId.java:61) >> > > > at >> > > org.apache.hadoop.hbase.zookeeper.ClusterId.getId(ClusterId.java:50) >> > > > at >> > > org.apache.hadoop.hbase.zookeeper.ClusterId.hasId(ClusterId.java:44) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.ensureZookeeperTrackers(HConnectionManager.java:615) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getMaster(HConnectionManager.java:684) >> > > > at >> > > > >> org.apache.hadoop.hbase.client.HBaseAdmin.(HBaseAdmin.java:116) >> > > > at >> > > > >> > > > >> > > >> > >> org.apache.hadoop.hbase.client.HBaseAdmin.checkHBaseAvailable(HBaseAdmin.java:1750) >> > > > at org.samsung.cloud.dao.HB_Crud.(HB_Crud.java:40) >> > > > at org.samsung.cloud.dao.HB_Read.(HB_Read.java:49) >> > > > at org.samsung.cloud.rest.HB_Rest.getData(HB_Rest.java:46) >> > > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> > > > >> > > >> > >> > > --047d7b3438ecd8c64304d9453e3c--