Created on 02-27-2019 12:12 AM - edited 09-16-2022 07:11 AM
Hi,
We are not able to connect to impala from squirrel /workbench client using JDBC.
At the same time, We are able to successfully connect using ODBC driver.
There is no configuration issue from Kerberos side as we are able to fetch the data using ODBC.
We have installed
1) CDH 6.1 cluster
2) MIT Kerberos enabled
3) SSL enabled for Impala
4) Tested using the Impala JDBC driver version 2.5.45(ClouderaImpalaJDBC4_2.5.45)
and 2.6.2 (impala_jdbc_2.6.2.1003)
We are getting the below error
[Simba][ImpalaJDBCDriver](500164) Error initialized or created transport for authentication: [Simba][ImpalaJDBCDriver](500169) Unable to connect to server: GSS initiate failed
Also, could not send response: org.apache.thrift.transport.TTransportException: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target.
Connection strings:
jdbc:impala://Loadbalancer.amazonaws.com:21050/default;AuthMech=1;KrbHostFQDN=master2-impala-146.com;KrbRealm=PRODIMPALA.COM;KrbServiceName=impala;SSL=1;CAIssuedCertNamesMismatch=1;SocketTimeout=10;loglevel=6;logpath=d:\;TrustedCerts=D:\CA-Certs\\cacerts
jdbc:impala://Loadbalancer.amazonaws.com:21050/default;AuthMech=1;KrbHostFQDN=master2-impala-146;KrbRealm=PRODIMPALA.COM;KrbServiceName=impala;ssl=1;CAIssuedCertNamesMismatch=1;loglevel=6;logpath=d:\CA-CERTS\;TrustedCerts="C:\Program Files (x86)\Java\jre1.8.0_201\lib\security\cacerts"
jdbc:impala://Loadbalancer.amazonaws.com:21050/default;AuthMech=1;KrbHostFQDN=master2-impala-146;KrbRealm=PRODIMPALA.COM;KrbServiceName=impala;ssl=1;
Different Options:
1) Imported the pem file into /jre/lib/security/cacerts
2) Copied the jssecacerts from impala node to client node
3) Tried connecting with jks file
4) Tried with both impala jdbc 4 & 4.1 driver.
Any help would be really appreciated.
Regards,
Balaji
Created 06-09-2021 11:22 AM
Hi Guys.
Well, we had the same problem here and at the end, we identified there something in the network blocking the certificate validation. It was the OpenDns and we solved it by adding the server to the whitelist.
Regards
Created 04-22-2019 05:16 PM
I am having the same problem, were you able to resolve this ? If so can you share your experience ?
Created 06-09-2021 11:22 AM
Hi Guys.
Well, we had the same problem here and at the end, we identified there something in the network blocking the certificate validation. It was the OpenDns and we solved it by adding the server to the whitelist.
Regards
Created 06-15-2021 11:17 PM
Hello Balaji
1. Could you confirm if you are using the same certificates for both the JDBC and ODBC connection strings?
2. The error looks like more of cert DNS issue un.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid
hat application if it can trust it. The way trust is handled in the Java world is that you have a keystore (typically $JAVA_HOME/lib/security/cacerts), also known as the truststore. This contains a list of all known Certificate Authority (CA) certificates, and Java will only trust certificates that are signed by one of those CAs or public certificates that exist within that keystore. For example, if we look at the certificate for Atlassian, we can see that the *.atlassian.com certificate has been signed by the intermediate certificates, DigiCert High Assurance EV Root CA and DigiCert High Assurance CA-3. These intermediate certificates have been signed by the root Entrust.net Secure Server CA :
These three certificates combined are referred to as the certificate chain, and, as they are all within the Java keystore (cacerts), Java will trust any certificates signed by them (in this c
This problem is therefore caused by a certificate that is self-signed (a CA did not sign it) or a certificate chain that does not exist within the Java truststore. Java does not trust the certificate and fails to connect to the application.
Resolution
Created 06-20-2021 10:09 PM
@rodrigo_fritsch, Has the reply helped resolve your issue? If so, please mark the appropriate reply as the solution, as it will make it easier for others to find the answer in the future.
Regards,
Vidya Sargur,Created 07-06-2021 11:52 PM
Hi @rodrigo_fritsch, would you have any update on the solutions provided? If they have helped you resolve the issue, can you kindly accept the appropriate response as a solution?
Regards,
Vidya Sargur,Created 07-07-2021 05:18 AM
Hi VydiaSargur!
Maybe I didn't express myself well. I have replied to the topic to help the other people, we had the same problem here and fortunately, we were able to fix it by adding the CDP server to the DNS's whitelist.
Anyway, thank you for your answer. It was complete and surely will be much useful than mine to help other users.
Best regards.
Created 07-07-2021 09:27 PM
Thanks for the confirmation @rodrigo_fritsch. I have marked your reply as the solution.
Regards,
Vidya Sargur,