Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Support Questions

Find answers, ask questions, and share your expertise
Announcements
Share your experience with Cloudera on G2 and get a $25 Amazon Gift card.
Hi, I'm CLEO! Something exciting is coming to the Community. Stay Tuned!

R client connections fails with CDP Impala

avatar
Explorer

I am having trouble with the Impala connection from R with the following error:

 

'Error: nanodbc/nanodbc.cpp:983: 00000: [unixODBC][Cloudera][DriverSupport] (1100) SSL certificate verification failed because the certificate is missing or incorrect.'

 

Here is the connection details in our code:

 

impala = src_impala(

     drv = drv,

     driver = "/opt/cloudera/impalaodbc/lib/64/libclouderaimpalaodbc64.so",

     host = "cdp-tdh-de3-master0.cdp-tdh.u5te-1stu.cloudera.site",

     database = db,

     port = 21050,

     uid = username,

     pwd = password,

     AuthMech = 3,

     transportMode="http",

     httpPath="cdp-tdh-de3/cdp-proxy-api/impala",

     ssl = 1,

    sslTrustStore="/home/csso_innovation.cdh/gateway-client-trust.jks"

)

return(impala)

 

Any help is appreciated.

Thanks,

Gozde

11 REPLIES 11

avatar
Explorer

@mszurap, not sure are you still following the issue, but I just wanted to update the current situation here in case you have other suggestions 🙂

 

Following the ODBC documentation from Cloudera (https://docs.cloudera.com/documentation/other/connectors/impala-odbc/2-6-14/Cloudera-ODBC-Connector-...), after modifying the .odbc.ini file in home folder with the following:

 

[ODBC Data Sources]

Sample DSN=Cloudera ODBC Driver for Impala 64-bit

[Sample DSN]

 

driver = /opt/cloudera/impalaodbc/lib/64/libclouderaimpalaodbc64.so

host = host

database = db

port = 21050

KrbRealm = realm

KrbFQDN = fqdn

KrbServiceName = impala

AuthMech = 1

ssl = 1

TrustedCerts = /var/lib/cloudera-scm-agent/agent-cert/cm-auto-global_cacerts.pem

 

My connection works and I can see all our tables.

However using the same connection string from our R code, I got the following error when it comes to write a table in impala:

 

Warning:
object '.__C__impala_connection' not found
Error: org.apache.spark.sql.catalyst.analysis.NoSuchDatabaseException: Database 'commcare_typed' not found

 the code also has spark connection:

 

spark = spark_connect(master="yarn") 

 

and writes the table in the R code with spark_write_table fuction.

 

Any ideas about why our connection seem to be not working? 

 

 

avatar

Hi! Sorry, but this seems some R specific usage problem in which I cannot help.

What you can do is to enable DEBUG/TRACE level logging on the ODBC driver side (please check the ODBC Driver documentation how to do it), maybe there you can find further clues.