1

I'm trying to acces to an unsecured hive (hive.server2.authentication is NONE) and I get the following error message in both pyhive and impala:

TTransportException: Could not start SASL: Error in sasl_client_start (-4) SASL(-4): no mechanism available: Unable to find a callback: 2 

My impyla code:

from impala.dbapi import connect
conn = connect(host='my_host_name', port=10000, auth_mechanism='PLAIN')
cursor = conn.cursor()
cursor.execute('SHOW TABLES')
print cursor.description  # prints the result set's schema
for table in cursor.fetchall():
    print table
results = cursor.fetchall()

my pyhive code:

from pyhive import hive
conn = hive.Connection(host='my_host_name' , port=10000, auth='NONE' )
cursor = conn.cursor()
cursor.execute("SHOW TABLES")
for table in cursor.fetchall():
    print table

Any ideas on how to solve this? Or any other python APIs that let me connect to hive?

h3h325
  • 751
  • 1
  • 9
  • 19

0 Answers0