Skip to main content
syedshakir
Gold ⭐️
Jun 22, 2022 8:40 AM UTC
Solved

Impala shell error

Hi ,

 

im unable to connect impala shell ( kerberised cluster ) with below: command  on Edge node 

impala-shell -i hostname.abc.com -d default -k

case scenario :  we have two Edge node A and B , able to connect on edgenode A  and unable to connect on edgenode  B with same credentials. checked with different user is it also same as working  on Edge node A and edgenode B . 

observed that both have different python version  A has 2.7.5 as default and B has 3.7.0 is this the cause of connection , if yes how to rectify. 

ERROR screenshot shared.

 


shell error.jpg
syedshakir
Gold ⭐️
Jul 14, 2022 2:33 PM UTC

Hi Vidya , 

 

Issue has been resolved by setting path : 

export PATH=/opt/cloudera/parcels/CDH-5.15.1-1.cdh5.15.1.p0.4/bin:/usr/bin/python2:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/opt/anaconda3/bin:/opt/anaconda3/condabin

 

 

11 replies

ShankerSharma
Gold ⭐️
Gold ⭐️
Jun 22, 2022 2:31 PM UTC

Hello Syed,

 

Yes, the impala is compatible with Python version 2.7.5.

 

 

Translate
ShankerSharma
Gold ⭐️
Gold ⭐️
Jun 22, 2022 2:34 PM UTC

You can try the below steps in edge node B

virtualenv venv -p python2

cd venv

source bin/activate

(venv) impala-shell

Translate
syedshakir
Gold ⭐️
Jun 22, 2022 2:43 PM UTC

Thanks for the solution , every time i have to come in venv and run impala shell ? or it will work without venv !!

 

Translate
ShankerSharma
Gold ⭐️
Gold ⭐️
Jun 22, 2022 2:51 PM UTC

Yes, you need to switch to venv everytime or you need to reinstall python with the 2.7.5 version.

Translate
ShankerSharma
Gold ⭐️
Gold ⭐️
Jun 23, 2022 10:56 AM UTC

For a permanent fix, you need to install the python version 2.7.5.

Translate
syedshakir
Gold ⭐️
Jun 23, 2022 4:08 PM UTC

Python 2.7.5 is already installed and multiple version are available tried to set path but not working , any alternate solution.. .!!!

 

 

Translate
ChethanYM
Gold ⭐️
Gold ⭐️
Jul 6, 2022 2:44 PM UTC

Hello Syed,

 

Can you try the alternatives command to change the python version? Check the below link.

https://medium.com/coderlist/how-to-change-default-python-version-on-linux-fedora-28-c22da18bdd6

 

Regards,

Chethan YM

Translate
VidyaSargur
Community Manager
Community Manager
Jul 11, 2022 5:42 AM UTC

@syedshakir, Have any of the replies helped resolve your issue? If so, kindly mark the appropriate reply as the solution, as it will make it easier for others to find the answer in the future. 

Translate
Regards, Vidya Sargur Madabhushi| Senior Community Manager | Was your question answered? Make sure to mark the answer as the Best Answer. If you find a reply useful, say thanks by clicking on the thumbs up button.
syedshakir
syedshakirAuthorAnswer
Gold ⭐️
Jul 14, 2022 2:33 PM UTC

Hi Vidya , 

 

Issue has been resolved by setting path : 

export PATH=/opt/cloudera/parcels/CDH-5.15.1-1.cdh5.15.1.p0.4/bin:/usr/bin/python2:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/opt/anaconda3/bin:/opt/anaconda3/condabin

 

 

Translate