phoenix-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Dimiduk <ndimi...@gmail.com>
Subject Re: JDBC connection zookeeper error
Date Mon, 23 Feb 2015 17:24:35 GMT
Can you double-check the Zookeeper quorum, port, and root node? The HBase
Master web UI shows the first two, the third you can get to by looking at
the output of zk_dump.jsp

On Mon, Feb 23, 2015 at 8:58 AM, Brady, John <john.brady@intel.com> wrote:

>  Hi Matthew,
>
>
>
> Yes, I just doubled checked. The HBase master is running and I can access
> the HMaster status page – I can see the tables I created in Phoenix.
>
>
>
> Would you have any other ideas?
>
>
>
> Thanks
>
>
>
>
>
>
>
> *From:* Matthew Johnson [mailto:matt.johnson@algomi.com]
> *Sent:* Monday, February 23, 2015 3:13 PM
> *To:* user@phoenix.apache.org
> *Subject:* RE: JDBC connection zookeeper error
>
>
>
> Hi John,
>
>
>
> Is your HBase Master running? (It shows up in linux process list as
> HMaster). Are you able to access the HMaster status page? (On mine, it is
> http://<ip address>:60010).
>
>
>
> Cheers,
>
> Matt
>
>
>
>
>
> *From:* Brady, John [mailto:john.brady@intel.com]
> *Sent:* 23 February 2015 14:59
> *To:* user@phoenix.apache.org
> *Subject:* JDBC connection zookeeper error
>
>
>
> Hello,
>
>
>
> I have Phoenix installed on a 5 node Cloudera cluster with 3 zookeeper
> nodes.
>
>
>
> I’m trying to run a basic SQL command from the JDBC program below but I’m
> getting zookeeper errors. Could anybody advise?
>
>
>
> *org.apache.phoenix.exception.PhoenixIOException*:
> *org.apache.hadoop.hbase.MasterNotRunningException*: Can't get connection
> to ZooKeeper: KeeperErrorCode = ConnectionLoss for /hbase
>
>      at org.apache.phoenix.util.ServerUtil.parseServerException(
> *ServerUtil.java:108*)
>
>      at
> org.apache.phoenix.query.ConnectionQueryServicesImpl.ensureTableCreated(
> *ConnectionQueryServicesImpl.java:832*)
>
>      at org.apache.phoenix.query.ConnectionQueryServicesImpl.createTable(
> *ConnectionQueryServicesImpl.java:1126*)
>
>      at
> org.apache.phoenix.query.DelegateConnectionQueryServices.createTable(
> *DelegateConnectionQueryServices.java:110*)
>
>      at org.apache.phoenix.schema.MetaDataClient.createTableInternal(
> *MetaDataClient.java:1590*)
>
>      at org.apache.phoenix.schema.MetaDataClient.createTable(
> *MetaDataClient.java:568*)
>
>      at org.apache.phoenix.compile.CreateTableCompiler$2.execute(
> *CreateTableCompiler.java:175*)
>
>      at org.apache.phoenix.jdbc.PhoenixStatement$2.call(
> *PhoenixStatement.java:271*)
>
>      at org.apache.phoenix.jdbc.PhoenixStatement$2.call(
> *PhoenixStatement.java:263*)
>
>      at org.apache.phoenix.call.CallRunner.run(*CallRunner.java:53*)
>
>      at org.apache.phoenix.jdbc.PhoenixStatement.executeMutation(
> *PhoenixStatement.java:261*)
>
>      at org.apache.phoenix.jdbc.PhoenixStatement.executeUpdate(
> *PhoenixStatement.java:1043*)
>
>      at org.apache.phoenix.query.ConnectionQueryServicesImpl$9.call(
> *ConnectionQueryServicesImpl.java:1551*)
>
>      at org.apache.phoenix.query.ConnectionQueryServicesImpl$9.call(
> *ConnectionQueryServicesImpl.java:1520*)
>
>      at org.apache.phoenix.util.PhoenixContextExecutor.call(
> *PhoenixContextExecutor.java:77*)
>
>      at org.apache.phoenix.query.ConnectionQueryServicesImpl.init(
> *ConnectionQueryServicesImpl.java:1520*)
>
>      at org.apache.phoenix.jdbc.PhoenixDriver.getConnectionQueryServices(
> *PhoenixDriver.java:162*)
>
>      at org.apache.phoenix.jdbc.PhoenixEmbeddedDriver.connect(
> *PhoenixEmbeddedDriver.java:126*)
>
>      at org.apache.phoenix.jdbc.PhoenixDriver.connect(
> *PhoenixDriver.java:133*)
>
>      at java.sql.DriverManager.getConnection(Unknown Source)
>
>      at java.sql.DriverManager.getConnection(Unknown Source)
>
>      at mysqljbdctest.PhoenixJDBC.main(*PhoenixJDBC.java:15*)
>
> Caused by: *org.apache.hadoop.hbase.MasterNotRunningException*:
> *org.apache.hadoop.hbase.MasterNotRunningException*: Can't get connection
> to ZooKeeper: KeeperErrorCode = ConnectionLoss for /hbase
>
>      at
> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation$StubMaker.makeStub(
> *HConnectionManager.java:1651*)
>
>      at
> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation$MasterServiceStubMaker.makeStub(
> *HConnectionManager.java:1677*)
>
>      at
> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getKeepAliveMasterService(
> *HConnectionManager.java:1884*)
>
>      at
> org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getHTableDescriptor(
> *HConnectionManager.java:2671*)
>
>      at org.apache.hadoop.hbase.client.HBaseAdmin.getTableDescriptor(
> *HBaseAdmin.java:397*)
>
>      at org.apache.hadoop.hbase.client.HBaseAdmin.getTableDescriptor(
> *HBaseAdmin.java:402*)
>
>      at
> org.apache.phoenix.query.ConnectionQueryServicesImpl.ensureTableCreated(
> *ConnectionQueryServicesImpl.java:764*)
>
>      ... 20 more
>
>
>
>
>
>
>
> *package* mysqljbdctest;
>
>
>
> *import* java.sql.*;
>
>
>
> *public* *class* PhoenixJDBC {
>
>
>
>      *public* *static* *void* main(String args[]) {
>
>
>
>      *try* {
>
>          //Register JDBC Driver
>
>          Class.*forName*("org.apache.phoenix.jdbc.PhoenixDriver"
> ).newInstance();
>
>
>
>          Connection conn = DriverManager.*getConnection*(
> "jdbc:phoenix:54.152.31.122","","");
>
>
>
>          //Create a Statement class to execute the SQL statement
>
>          Statement stmt = conn.createStatement();
>
>
>
>          //Execute the SQL statement and get the results in a *Resultset*
>
>          ResultSet rs = stmt.executeQuery("select * from US_POPULATION");
>
>
>
>          // Iterate through the ResultSet, displaying two values
>
>          // for each row using the getString method
>
>
>
>          *while* (rs.next())
>
>              System.*out*.println("Name= " + rs.getString("host"));
>
>      }
>
>      *catch* (SQLException e) {
>
>          e.printStackTrace();
>
>      }
>
>      *catch* (Exception e) {
>
>          e.printStackTrace();
>
>      }
>
>      }
>
>      }
>
>
>
> -------------------------------------------------------------
> Intel Ireland Limited (Branch)
> Collinstown Industrial Park, Leixlip, County Kildare, Ireland
> Registered Number: E902934
>
> This e-mail and any attachments may contain confidential material for
> the sole use of the intended recipient(s). Any review or distribution
> by others is strictly prohibited. If you are not the intended
> recipient, please contact the sender and delete all copies.
>
> -------------------------------------------------------------
> Intel Ireland Limited (Branch)
> Collinstown Industrial Park, Leixlip, County Kildare, Ireland
> Registered Number: E902934
>
> This e-mail and any attachments may contain confidential material for
> the sole use of the intended recipient(s). Any review or distribution
> by others is strictly prohibited. If you are not the intended
> recipient, please contact the sender and delete all copies.
>

Mime
View raw message