You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "Hudson (JIRA)" <ji...@apache.org> on 2015/05/06 15:55:00 UTC
[jira] [Commented] (AMBARI-10953) Hive Server 2 Process Check
Should Always Use Beeline Instead of TCP Sockets
[ https://issues.apache.org/jira/browse/AMBARI-10953?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14530577#comment-14530577 ]
Hudson commented on AMBARI-10953:
---------------------------------
SUCCESS: Integrated in Ambari-trunk-Commit #2527 (See [https://builds.apache.org/job/Ambari-trunk-Commit/2527/])
AMBARI-10953. Hive Server 2 Process Check Should Always Use Beeline Instead of TCP Sockets (dlysnichenko) (dlysnichenko: http://git-wip-us.apache.org/repos/asf?p=ambari.git&a=commit&h=ccd0c44b64e6768f5fab3a2d349ba365f9af6b34)
* ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
* ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_service_check.py
* ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_service.py
* ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
* ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/alerts/alert_hive_thrift_port.py
* ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/service_check.py
* ambari-common/src/main/python/resource_management/libraries/functions/hive_check.py
> Hive Server 2 Process Check Should Always Use Beeline Instead of TCP Sockets
> ----------------------------------------------------------------------------
>
> Key: AMBARI-10953
> URL: https://issues.apache.org/jira/browse/AMBARI-10953
> Project: Ambari
> Issue Type: Bug
> Components: ambari-server
> Reporter: Dmitry Lysnichenko
> Assignee: Dmitry Lysnichenko
> Fix For: 2.1.0
>
>
> {{ambari-common/src/main/python/resource_management/libraries/functions/hive_check.py}} uses a combination of {{beeline}} and sockets to check the availability of the Hive server.
> Hive Server can be configured to run in either {{binary}} or {{http}} mode, as configured by the following property in {{hive-site}}:
> {code}
> <property>
> <name>hive.server2.transport.mode</name>
> <value>binary</value>
> </property>
> {code}
> The python, however, only runs the {{beeline}} command if KERBEROS is in use _AND_ the mode is {{binary}}. This not correct in that {{beeline}} can connect via both TCP and HTTP:
> {code}
> beeline -u 'jdbc:hive2://c6402.ambari.apache.org:10000/;transportMode=binary' -e ''
> beeline -u 'jdbc:hive2://c6402.ambari.apache.org:10001/;transportMode=http' -e ''
> {code}
> Additionally, {{alert_hive_thrift_port.py}} needs to provide a better error message. Currently, the code
> {code}
> try:
> hive_check.check_thrift_port_sasl(host_name, port,
> hive_server2_authentication, hive_server_principal, kinitcmd, smokeuser,
> transport_mode = transport_mode)
> is_thrift_port_ok = True
> except:
> is_thrift_port_ok = False
> if is_thrift_port_ok == True:
> result_code = 'OK'
> total_time = time.time() - start_time
> label = OK_MESSAGE % (total_time, port)
> else:
> result_code = 'CRITICAL'
> label = CRITICAL_MESSAGE.format(host_name,port)
> {code}
> will not show the exact error message and instead just say that it couldn't connect to host:port, which is wrong since that implies the only failure could be TCP-based. I recommend putting the exception message in as well.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)