SHARE
TWEET

Untitled

a guest Jan 12th, 2017 60 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public static void main(String args[]) {
  2.     Class.forName("org.apache.hive.jdbc.HiveDriver");
  3.     conn = DriverManager.getConnection("jdbc:hive2://<ip>:10015/default","","");
  4.     System.out.println("Connected!");
  5. }
  6.    
  7. !connect jdbc:hive2://127.0.0.1:10015
  8.    
  9. 1300 [main] INFO  org.apache.hive.jdbc.HiveConnection  - Could not open client transport with JDBC Uri: jdbc:hive2://192.168.225.128:10015/default
  10. java.sql.SQLException: Could not open client transport with JDBC Uri: jdbc:hive2://192.168.225.128:10015/default: java.net.ConnectException: Connection refused: connect
  11. at org.apache.hive.jdbc.HiveConnection.openTransport(HiveConnection.java:215)
  12. at org.apache.hive.jdbc.HiveConnection.<init>(HiveConnection.java:163)
  13. at org.apache.hive.jdbc.HiveDriver.connect(HiveDriver.java:105)
  14. at java.sql.DriverManager.getConnection(DriverManager.java:664)
  15. at java.sql.DriverManager.getConnection(DriverManager.java:247)
RAW Paste Data
Top