You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by Raymond Xie <xi...@gmail.com> on 2017/01/23 00:34:21 UTC
Cannot connect to Hive even from local
Hello,
I don't know what's wrong with my hive or my procedure, all I need is very
simple: I just want to connect Tableau to Hive:
1. Tableau: installed on my desktop (Win 7)
2. guest: installed with VMWare
3. Hadoop: installed in the guest, hadoop 2.7.2, Hive 2.0.1
4. Using Tableau to connect to HiveServer2:
[image: Inline image 1]
Below is my troubleshooting:
5. Login in the guest as root
6. Start hadoop
7. start hive2server: $HIVE_HOME/bin/hiveserver2
[image: Inline image 3]
8.start beeline
9. tried both of the following:
!connect jdbc:hive2://localhost:10000/default; -n hiveuser -p hivepassword
!connect jdbc:hive2://localhost:10001/default; -n hiveuser -p hivepassword
return same message:
[image: Inline image 2]
jdbc closed?
What's missing here? how do I fix it? Thank you very much
*------------------------------------------------*
*Sincerely yours,*
*Raymond*
Re: Cannot connect to Hive even from local
Posted by Gopal Vijayaraghavan <go...@apache.org>.
> !connect jdbc:hive2://localhost:10000/default; -n hiveuser -p hivepassword
...
> What's missing here? how do I fix it? Thank you very much
Mostly, this is missing the actual protocol specs - this is something which is never a problem for real clusters because ZK load-balancing automatically configures it.
The HS2 is most likely running in HTTP mode, which needs additional parameters
https://cwiki.apache.org/confluence/display/Hive/HiveServer2+Clients#HiveServer2Clients-ConnectionURLWhenHiveServer2IsRunninginHTTPMode
My paths end up looking like
jdbc:hive2://sandbox.hortonworks.com:10000/tpcds_flat_orc_2;transportMode=http;httpPath=cliservice?
Cheers,
Gopal