I am trying to connect to HIVE via Python (Jupyter Notebooks). I have installed all the necessary packages for connecting HIVE using Python -
sasl 0.2.1 py37h8a4fda4_1
thrift 0.13.0 pypi_0 pypi
thrift-sasl 0.3.0 pypi_0 pypi
pyhive 0.6.1 pypi_0 pypi
from pyhive import hive
conn = hive.Connection(host="xxxxxxx", port=xxxxx, username="xxxxxxxx")
But unable to connect as it's throwing error: TTransportException: Could not start SASL: b'Error in sasl_client_start (-4) SASL(-4): no mechanism available: Unable to find a callback: 2'
.
Am I missing anything? How do I connect?
On the Windows platform, you need to add to win reestr the path to your C:\PyProj\MyProj\venv\Lib\site-packages\sasl\sasl2 directory. In the win command line: C:\Windows\system32>REG ADD "HKEY_LOCAL_MACHINE\SOFTWARE\Carnegie Mellon\Project Cyrus\SASL Library" /v SearchPath /t REG_SZ /d "C:\PyProj\MyProj\venv\Lib\site-packages\sasl\sasl2"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With