Created 01-26-2017 02:47 PM
Hi,
I'm currently working through tutorial
Section 2.2.10 - Beeline
As instructed I do the following
1. Run Putty
2. Login as maria_dev
3. run 'sudo su hive' (su hive just asks me for a password and I've tried maria_dev's and roots with no luck)
4. run 'beeline'
5. beeline starts and I get the version number and the prompt changes to beeline>
But then no matter what I run I get the message back 'No current connection'.
Even if I run 'quit;' The steps in the tutorial seem pretty basic so I dont know where I'm going wrong. Any ideas?
Thanks, Nic
Created 01-26-2017 02:54 PM
After entering into beeline shell, you need to give connection string to connect to Hiveserver2.
Please use below command in beeline shell to connect to HS2
!connect jdbc:hive2://<hiveserver2-hostname-or-ip>:10000/<database-name>
After you run above command, you will have to provide username and password based on authentication mechanism that you have configured for Hiveserver2 (by default it's none)
Please refer below document for more details
https://cwiki.apache.org/confluence/display/Hive/HiveServer2+Clients
Created 01-26-2017 02:54 PM
After entering into beeline shell, you need to give connection string to connect to Hiveserver2.
Please use below command in beeline shell to connect to HS2
!connect jdbc:hive2://<hiveserver2-hostname-or-ip>:10000/<database-name>
After you run above command, you will have to provide username and password based on authentication mechanism that you have configured for Hiveserver2 (by default it's none)
Please refer below document for more details
https://cwiki.apache.org/confluence/display/Hive/HiveServer2+Clients
Created 01-26-2017 03:13 PM
If you have Kerberos enabled you need to connect as:
!connect jdbc:hive2://<hiveserver2_hostname>:10001/<database_name>;transportMode=http;httpPath=cliservice;principal=<hive_principal>
Created 01-27-2017 08:59 AM
Thank you both for the responses. Greatly appreciate both.
Kuldeep - That worked perfectly
Daniel - Very useful to know, I'm sure it will end up being used down the line.