This probably diagnoses the problem: If I do nc on the HBase computer, it works, like this -
nc myip 2181 ruok* imok but if I do it on the remote one, it comes back right away, no error, but no work either - $ nc myip 2181 $ Also telnet tells the same story: telnet myip 2181 Trying myip... telnet: connect to address myip: No route to host telnet: Unable to connect to remote host: No route to host I can ping it OK though. Thank you, Mark On Sun, Feb 6, 2011 at 8:28 PM, Ted Dunning <tdunn...@maprtech.com> wrote: > What happens when you try to connect to myip:2181 directly? > > You can use nc (network cat) for this: > > $ *nc myip 2181* > * ruok* > imok > $ > > You type the part in bold italics (nc and ruok) and the response from the > system is (should be) "imok". > > There are a number of such "four letter words" that Zookeeper supports, but > the key here is to verify that Zookeeper is up and running and accessible. > > On Sun, Feb 6, 2011 at 5:25 PM, Mark Kerzner <markkerz...@gmail.com> > wrote: > > > Then I get this error: > > > > 11/02/06 17:16:09 INFO zookeeper.ZooKeeper: Initiating client connection, > > connectString=myip:2181 sessionTimeout=60000 > > watcher=org.apache.hadoop.hbase.zookeeper.ZooKeeperWrapper@21f8c6df > > 11/02/06 17:16:09 INFO zookeeper.ClientCnxn: Opening socket connection to > > server /myip:2181 > > 11/02/06 17:16:09 WARN zookeeper.ClientCnxn: Session 0x0 for server null, > > unexpected error, closing socket connection and attempting reconnect > > java.net.NoRouteToHostException: No route to host > > at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) > > at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:574) > > at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1078) > > > > (of course, myip is the real ip with digits, I just replaced it for this > > email, and I verified that the ip is correct, and that HBase runs at this > > ip) > > > > Thank you again, > > Mark > > > > On Sun, Feb 6, 2011 at 5:34 PM, Tost <nca...@gmail.com> wrote: > > > > > Try this. > > > config.set("hbase.zookeeper.quorum", "myip"); > > > > > > 2011/2/6 Mark Kerzner <markkerz...@gmail.com> > > > > > > > Hi, guys, > > > > > > > > I have these lines trying to connect to the HBase, and it works > > perfectly > > > > well when I am connecting on that machine that runs HBase, but not > when > > I > > > > am > > > > connecting from the outside. What ports or other conditions should I > > > check? > > > > > > > > Configuration config = HBaseConfiguration.create(); > > > > config.set("hbase.zookeeper.quorum", "myip:60010"); > > > > config.set("hbase.zookeeper.property.clientPort", "2181"); > > > > > > > > HTable table = new HTable(config, "myTable"); > > > > > > > > Thank you! > > > > > > > > Mark > > > > > > > > > >