Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id D88D8200C64 for ; Fri, 14 Apr 2017 03:42:45 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D71A1160BA7; Fri, 14 Apr 2017 01:42:45 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 2B961160B98 for ; Fri, 14 Apr 2017 03:42:45 +0200 (CEST) Received: (qmail 22035 invoked by uid 500); 14 Apr 2017 01:42:44 -0000 Mailing-List: contact issues-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ambari.apache.org Delivered-To: mailing list issues@ambari.apache.org Received: (qmail 22026 invoked by uid 99); 14 Apr 2017 01:42:44 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 14 Apr 2017 01:42:44 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id D034D1A0462 for ; Fri, 14 Apr 2017 01:42:43 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id xsAoIt9tJi_p for ; Fri, 14 Apr 2017 01:42:43 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 74D715FC7A for ; Fri, 14 Apr 2017 01:42:42 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id EAD4DE0D20 for ; Fri, 14 Apr 2017 01:42:41 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id A0C442406A for ; Fri, 14 Apr 2017 01:42:41 +0000 (UTC) Date: Fri, 14 Apr 2017 01:42:41 +0000 (UTC) From: "Yuanbo Liu (JIRA)" To: issues@ambari.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (AMBARI-20754) get_value_from_jmx constantly prints exception message in retry mechanism, which brings bad user experience MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 14 Apr 2017 01:42:46 -0000 [ https://issues.apache.org/jira/browse/AMBARI-20754?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yuanbo Liu updated AMBARI-20754: -------------------------------- Attachment: AMBARI-20754.001.patch > get_value_from_jmx constantly prints exception message in retry mechanism, which brings bad user experience > ----------------------------------------------------------------------------------------------------------- > > Key: AMBARI-20754 > URL: https://issues.apache.org/jira/browse/AMBARI-20754 > Project: Ambari > Issue Type: Bug > Reporter: Yuanbo Liu > Assignee: Yuanbo Liu > Attachments: AMBARI-20754.001.patch > > > {{get_value_from_jmx}} of {{jmx.py}} is used in getting NameNode HA state. As we know, if the cluster is large, it takes a long time for Namenode to leave safe mode when restarting Namenode, thus we use retry mechanism to invoke {{get_value_from_jmx}} in case of getting wrong state. The problem is that, {{get_value_from_jmx}} will print several exception message into std_error during retrying, it confuses users because there're error messages in std_error, while all the services restart successfully. Here are the error messages: > {quote} > 2017-04-12 15:12:56,633 - Getting jmx metrics from NN failed. URL: http://xxxx:50070/jmx?qry=Hadoop:service=NameNode,name=FSNamesystem > Traceback (most recent call last): > File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/jmx.py", line 38, in get_value_from_jmx > _, data, _ = get_user_call_output(cmd, user=run_user, quiet=False) > File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/get_user_call_output.py", line 61, in get_user_call_output > raise ExecutionFailed(err_msg, code, files_output[0], files_output[1]) > ExecutionFailed: Execution of 'curl --negotiate -u : -s 'http://xxxx:50070/jmx?qry=Hadoop:service=NameNode,name=FSNamesystem' 1>/tmp/tmpWp05DF 2>/tmp/tmphm2dny' returned 7. > 2017-04-12 15:12:58,562 - Getting jmx metrics from NN failed. URL: http://xxxx:50070/jmx?qry=Hadoop:service=NameNode,name=FSNamesystem > Traceback (most recent call last): > File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/jmx.py", line 42, in get_value_from_jmx > return data_dict["beans"][0][property] > IndexError: list index out of range > {quote} > We should improve it. -- This message was sent by Atlassian JIRA (v6.3.15#6346)