ambari-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zhao Wei ZW Shen" <shenz...@cn.ibm.com>
Subject Re:Re: How to get Ambari server host in status function of service control script
Date Fri, 08 Jan 2016 03:34:08 GMT
You can get the Ambari server info from Agent conf file (e.g.
/etc/ambari-agent/conf/ambari-agent.ini).
Btw, there is link about HUE integration with Ambari (
https://developer.ibm.com/hadoop/blog/2015/10/27/how-to-install-hue-3-9-on-top-of-biginsights-4-1/
).


Regards,
Zhaowei Shen



From:	"Zhang Ruiqiang" <zh.r.q@163.com>
To:	user@ambari.apache.org
Date:	2016-01-08 上午 12:48
Subject:	Re:Re: How to get Ambari server host in status function of
            service control script



      I want to integrate HUE as a custom service. The configurations of
HUE are depends on configurations of other services, e.g. namenode host,
resourcemanager host. So I want to check related services' configurations
in HUE's status function, once there is modification found, a new
configuration for HUE will be generated.
      I get the related configurations using REST API, so the ambari server
host is required.

Thanks!






At 2016-01-08 00:02:13, "Nate Cole" <ncole@hortonworks.com> wrote:
  Status commands are meant to be run for the component for which it is
  designed, usually just a pid check.  Therefore, cluster topology does not
  get passed for status commands.

  What are you trying to achieve by accessing the API?

  Thanks

  From: Zhang Ruiqiang <zh.r.q@163.com>
  Reply-To: "user@ambari.apache.org" <user@ambari.apache.org>
  Date: Thursday, January 7, 2016 at 10:54 AM
  To: "user@ambari.apache.org" <user@ambari.apache.org>
  Subject: How to get Ambari server host in status function of service
  control script

  Hi all:
        I want to do use the REST API in status function, so I should get
  the ambari server host. In start/stop function, it can be get by
  Script.get_confgi()['clusterInfo']['ambariServerHost'].  But in status
  function, the key was not exist. Maybe, i can get it by Script.get_confgi
  ()['jdk_location'] indirectly, but I think this is not elegant.
        Is there a better solution?

  Thanks!


















Mime
View raw message