If possible, try to run netstat as sudo.
On Thu, Aug 30, 2012 at 11:21 AM, anil gupta <[email protected]> wrote: > Can you also try to run telnet and netstat for port: 60030 and 60010 ? I > dont see post 60030 and 60010 in the output of netstat. Did you configured > some other ports for HBase Master? > > 2181 is the port of zookeeper. > > > On Thu, Aug 30, 2012 at 8:45 AM, Jilani Shaik <[email protected]>wrote: > >> Hi Anil, >> >> Please see the below commands which I executed and respective outputs. >> >> on HBase and Hadoop box >> >> [rtit@localhost conf]$ netstat -alnp | grep 2181 >> (Not all processes could be identified, non-owned process info >> will not be shown, you would have to be root to see it all.) >> tcp 0 0 :::2181 :::* >> LISTEN 22572/java >> tcp 0 0 ::ffff:192.265.47.222:2181 >> ::ffff:192.265.47.222:60094 >> ESTABLISHED 22572/java >> tcp 0 0 ::ffff:192.265.47.222:2181 >> ::ffff:192.265.47.222:60117 >> ESTABLISHED 22572/java >> tcp 0 0 ::ffff:192.265.47.222:2181 >> ::ffff:192.265.47.222:60098 >> ESTABLISHED 22572/java >> tcp 0 0 ::ffff:192.265.47.222:60098 ::ffff:192.265.47.222:2181 >> ESTABLISHED 22642/java >> tcp 0 0 ::ffff:192.265.47.222:60094 ::ffff:192.265.47.222:2181 >> ESTABLISHED 22842/java >> tcp 0 0 ::ffff:192.265.47.222:60117 ::ffff:192.265.47.222:2181 >> ESTABLISHED 22842/java >> tcp 0 0 ::ffff:192.265.47.222:60089 ::ffff:192.265.47.222:2181 >> ESTABLISHED 22642/java >> tcp 0 0 ::ffff:192.265.47.222:2181 >> ::ffff:192.265.47.222:60089 >> ESTABLISHED 22572/java >> >> >> [rtit@localhost conf]$ telnet localhost 2181 >> Trying 127.0.0.1... >> Connected to localhost. >> Escape character is '^]'. >> >> >> Connection closed by foreign host. >> [rtit@localhost conf]$ >> >> >> [rtit@localhost conf]$ telnet 192.265.47.222 2181 >> Trying 192.265.47.222... >> Connected to 192.265.47.222. >> Escape character is '^]'. >> >> >> Connection closed by foreign host. >> [rtit@localhost conf]$ >> >> >> >> --> From the remote box >> [rtit@RTIT-1 hbasedemos]$ telnet 192.265.47.222 2181 >> Trying 192.265.47.222... >> Connected to 192.265.47.222. >> Escape character is '^]'. >> >> >> Connection closed by foreign host. >> [rtit@RTIT-1 hbasedemos]$ >> >> >> >> >> On Thu, Aug 30, 2012 at 8:58 PM, anil gupta <[email protected]> >> wrote: >> >> > Then, it might be a issue with port binding. try to do telnet on the >> port >> > to which HBase listens from localhost as well as remote machine. >> > Also, try to run the netstat command and see the bindings of service. >> > >> > ~Anil >> > >> > On Thu, Aug 30, 2012 at 8:20 AM, Jilani Shaik <[email protected]> >> > wrote: >> > >> > > Anil, >> > > >> > > Already I disabled firewall of linux using iptables service. >> > > >> > > Thank You, >> > > Jilani >> > > >> > > >> > > On Thu, Aug 30, 2012 at 8:35 PM, anil gupta <[email protected]> >> > wrote: >> > > >> > > > Hi Jilani, >> > > > >> > > > It seems like a firewall issue. You will need to open appropriate >> ports >> > > or >> > > > disable the firewall on the machine you are running the service. >> > > > >> > > > HTH, >> > > > Anil >> > > > >> > > > On Thu, Aug 30, 2012 at 7:46 AM, Jilani Shaik <[email protected] >> > >> > > > wrote: >> > > > >> > > > > I am able to connect to HBase using Java client if the client is >> on >> > the >> > > > > same box where Hadoop and HBase are installed. If the client is on >> > > other >> > > > > box either windows or linux, I am getting the error as below >> > > > > >> > > > > org.apache.zookeeper.server.NIOServerCnxn: Closed socket >> connection >> > for >> > > > > client >> > > > > >> > > > > Please suggest me how to identify and fix the issue. >> > > > > >> > > > > Thank You, >> > > > > Jilani >> > > > > >> > > > > On Thu, Aug 30, 2012 at 7:00 PM, Jilani Shaik < >> [email protected]> >> > > > > wrote: >> > > > > >> > > > > > Hi, >> > > > > > >> > > > > > I have installed and configured Hadoop(hadoop-1.0.3) and >> > > > > > HBase(hbase-0.94.1) in a single Fedora linux box, where HBase >> > > > > > as pseudo cluster setup. >> > > > > > >> > > > > > I am able to connect the HBase suing shell from console and >> able to >> > > > > create >> > > > > > and scan table. But when I tried to contact the same using java >> > > > > application >> > > > > > I am not able to connect the HBase. >> > > > > > >> > > > > > Output of "jps" as follows >> > > > > > 16872 HRegionServer >> > > > > > 16603 HQuorumPeer >> > > > > > 15821 DataNode >> > > > > > 16047 JobTracker >> > > > > > 16667 HMaster >> > > > > > 17984 Jps >> > > > > > 15680 NameNode >> > > > > > 15959 SecondaryNameNode >> > > > > > 16179 TaskTracker >> > > > > > >> > > > > > The error log for zoo keeper of HBase is as follows >> > > > > > >> > > > > > 2012-08-30 18:44:19,231 INFO >> > > > > > org.apache.zookeeper.server.NIOServerCnxnFactory: Accepted >> socket >> > > > > > connection from /192.265.47.219:58357 >> > > > > > 2012-08-30 18:44:19,232 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Client attempting to establish new session at >> /192.265.47.219:58357 >> > > > > > 2012-08-30 18:44:19,236 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Established session 0x13977a18091000e with negotiated timeout >> > 180000 >> > > > for >> > > > > > client /192.265.47.219:58357 >> > > > > > 2012-08-30 18:45:16,245 INFO >> > > > > > org.apache.zookeeper.server.PrepRequestProcessor: Processed >> session >> > > > > > termination for sessionid: 0x13977a18091000e >> > > > > > 2012-08-30 18:45:16,252 INFO >> > > org.apache.zookeeper.server.NIOServerCnxn: >> > > > > > Closed socket connection for client /192.265.47.219 :58357 which >> > had >> > > > > > sessionid 0x13977a18091000e >> > > > > > 2012-08-30 18:45:16,256 INFO >> > > > > > org.apache.zookeeper.server.NIOServerCnxnFactory: Accepted >> socket >> > > > > > connection from /192.265.47.219:58373 >> > > > > > 2012-08-30 18:45:16,257 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Client attempting to establish new session at >> /192.265.47.219:58373 >> > > > > > 2012-08-30 18:45:16,264 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Established session 0x13977a18091000f with negotiated timeout >> > 180000 >> > > > for >> > > > > > client /192.265.47.219:58373 >> > > > > > 2012-08-30 18:46:21,279 INFO >> > > > > > org.apache.zookeeper.server.PrepRequestProcessor: Processed >> session >> > > > > > termination for sessionid: 0x13977a18091000f >> > > > > > 2012-08-30 18:46:21,286 INFO >> > > org.apache.zookeeper.server.NIOServerCnxn: >> > > > > > Closed socket connection for client /192.265.47.219:58373 which >> had >> > > > > > sessionid 0x13977a18091000f >> > > > > > 2012-08-30 18:46:21,291 INFO >> > > > > > org.apache.zookeeper.server.NIOServerCnxnFactory: Accepted >> socket >> > > > > > connection from /192.265.47.219:58391 >> > > > > > 2012-08-30 18:46:21,292 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Client attempting to establish new session at >> /192.265.47.219:58391 >> > > > > > 2012-08-30 18:46:21,298 INFO >> > > > org.apache.zookeeper.server.ZooKeeperServer: >> > > > > > Established session 0x13977a180910010 with negotiated timeout >> > 180000 >> > > > for >> > > > > > client /192.265.47.219:58391 >> > > > > > 2012-08-30 18:46:53,302 INFO >> > > > > > org.apache.zookeeper.server.PrepRequestProcessor: Processed >> session >> > > > > > termination for sessionid: 0x13977a180910010 >> > > > > > 2012-08-30 18:46:53,309 INFO >> > > org.apache.zookeeper.server.NIOServerCnxn: >> > > > > > Closed socket connection for client /192.265.47.219:58391 which >> had >> > > > > > sessionid 0x13977a180910010 >> > > > > > >> > > > > > >> > > > > > Below is the exception from java program >> > > > > > >> > > > > > Aug 30, 2012 6:45:13 PM org.apache.zookeeper.ZooKeeper close >> > > > > > INFO: Session: 0x13977a18091000e closed >> > > > > > Aug 30, 2012 6:45:13 PM >> org.apache.zookeeper.ClientCnxn$EventThread >> > > run >> > > > > > INFO: EventThread shut down >> > > > > > Aug 30, 2012 6:45:13 PM org.apache.zookeeper.ZooKeeper <init> >> > > > > > INFO: Initiating client connection, connectString= >> > > 192.265.47.222:2181 >> > > > > > sessionTimeout=180000 watcher=hconnection >> > > > > > Aug 30, 2012 6:45:13 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > startConnect >> > > > > > INFO: Opening socket connection to server / 192.265.47.222:2181 >> > > > > > Aug 30, 2012 6:45:13 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > primeConnection >> > > > > > INFO: Socket connection established to >> > > > > 192.265.47.222/192.265.47.222:2181, >> > > > > > initiating session >> > > > > > Aug 30, 2012 6:45:13 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > onConnected >> > > > > > INFO: Session establishment complete on server >> > > > > > 192.265.47.222/192.265.47.222:2181, sessionid = >> 0x13977a18091000f, >> > > > > > negotiated timeout = 180000 >> > > > > > Aug 30, 2012 6:46:18 PM org.apache.zookeeper.ZooKeeper close >> > > > > > INFO: Session: 0x13977a18091000f closed >> > > > > > Aug 30, 2012 6:46:18 PM >> org.apache.zookeeper.ClientCnxn$EventThread >> > > run >> > > > > > INFO: EventThread shut down >> > > > > > Aug 30, 2012 6:46:18 PM org.apache.zookeeper.ZooKeeper <init> >> > > > > > INFO: Initiating client connection, >> > connectString=192.265.47.222:2181 >> > > > > > sessionTimeout=180000 watcher=hconnection >> > > > > > Aug 30, 2012 6:46:18 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > startConnect >> > > > > > INFO: Opening socket connection to server /192.265.47.222:2181 >> > > > > > Aug 30, 2012 6:46:18 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > primeConnection >> > > > > > INFO: Socket connection established to >> > > > > 192.265.47.222/192.265.47.222:2181, >> > > > > > initiating session >> > > > > > Aug 30, 2012 6:46:18 PM >> org.apache.zookeeper.ClientCnxn$SendThread >> > > > > > onConnected >> > > > > > INFO: Session establishment complete on >> > > > > > server 192.265.47.222/192.265.47.222:2181, sessionid = >> > > > 0x13977a180910010, >> > > > > > negotiated timeout = 180000 >> > > > > > Aug 30, 2012 6:46:50 PM org.apache.zookeeper.ZooKeeper close >> > > > > > INFO: Session: 0x13977a180910010 closed >> > > > > > 12/08/30 18:46:50 >> > org.apache.hadoop.hbase.MasterNotRunningException: >> > > > > > Retried 10 times >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:127) >> > > > > > 12/08/30 18:46:50 at _hbase.demo(_hbase.java:59) >> > > > > > 12/08/30 18:46:50 at _hbase._jspService(_hbase.java:208) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > >> com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:56) >> > > > > > 12/08/30 18:46:50 at >> > > > > > oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:347) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509) >> > > > > > 12/08/30 18:46:50 at >> > > > > > oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413) >> > > > > > 12/08/30 18:46:50 at >> > > > > > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:810) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:322) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:270) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:112) >> > > > > > 12/08/30 18:46:50 at >> > > > > > >> > > > > >> > > > >> > > >> > >> com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186) >> > > > > > 12/08/30 18:46:50 at java.lang.Thread.run(Thread.java:662) >> > > > > > Aug 30, 2012 6:46:50 PM >> org.apache.zookeeper.ClientCnxn$EventThread >> > > run >> > > > > > INFO: EventThread shut down >> > > > > > >> > > > > > >> > > > > > Please suggest me how to resolve this. >> > > > > > >> > > > > > >> > > > > > Thank You, >> > > > > > Jilani >> > > > > > >> > > > > > >> > > > > >> > > > >> > > > >> > > > >> > > > -- >> > > > Thanks & Regards, >> > > > Anil Gupta >> > > > >> > > >> > >> > >> > >> > -- >> > Thanks & Regards, >> > Anil Gupta >> > >> > > > > -- > Thanks & Regards, > Anil Gupta > -- Thanks & Regards, Anil Gupta
