Details
-
Bug
-
Status: Resolved
-
Critical
-
Resolution: Fixed
-
Impala 3.0, Impala 2.12.0
-
None
-
ghx-label-1
Description
When impala-shell -b / --kerberos_host_fqdn is used, the value will override one passed in via -i / --impalad.
This leads to the socket being created with the former value in the case when -b is used.
The problematic section of code is here
if self.kerberos_host_fqdn is not None: host, port = (self.kerberos_host_fqdn.split(':')[0].encode('ascii', 'ignore'), int(self.impalad[1])) else: host, port = self.impalad[0].encode('ascii', 'ignore'), int(self.impalad[1]) if self.use_ssl: if self.ca_cert is None: # No CA cert means don't try to verify the certificate sock = TSSLSocketWithWildcardSAN(host, port, validate=False) else: sock = TSSLSocketWithWildcardSAN(host, port, validate=True, ca_certs=self.ca_cert) else: sock = TSocket(host, port) if not (self.use_ldap or self.use_kerberos): return TBufferedTransport(sock)
The proposed fix is to always create the socket with the host passed in via -i
self.impalad[0].encode('ascii', 'ignore')
Attachments
Issue Links
- is required by
-
IMPALA-2782 Allow Impala Shell to connect directly to impalad when config with proxy load balancer and kerberos
- Resolved
- relates to
-
IMPALA-7181 Fix flaky test shell/test_shell_commandline.py::TestImpalaShell::test_socket_opening
- Closed