<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: API / VIA script / command + how to verify ZKFailoverController status on nodes in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/API-VIA-script-command-how-to-verify-ZKFailoverController/m-p/178806#M75811</link>
    <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/26229/uribarih.html" nodeid="26229"&gt;@Michael Bronson&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You can try something like following:&lt;/P&gt;&lt;PRE&gt;#  curl -u admin:admin -H "X-Requested-By: ambari" -X GET "http://amb25101.example.com:8080/api/v1/clusters/plain_ambari/components?fields=ServiceComponentInfo/service_name,ServiceComponentInfo/component_name,ServiceComponentInfo/state,host_components/HostRoles/host_name,host_components/HostRoles/state" | grep -A 2 "\"component_name\" \: \"ZKFC\"" |  awk '{print $NF}' &amp;gt; /tmp/requests_details.txt; sed -e '1,2d' -e s'/--//g'  -e 's/\n//g' -e 's/"//g' -e '/^$/d' /tmp/requests_details.txt | awk 'NR%3{printf "%s ",$0;next;}1' &lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;Example Output:&lt;/P&gt;&lt;PRE&gt;STARTED ZKFC, amb25102.example.com,
STARTED ZKFC, amb25103.example.com,&lt;/PRE&gt;</description>
    <pubDate>Wed, 14 Mar 2018 18:13:14 GMT</pubDate>
    <dc:creator>jsensharma</dc:creator>
    <dc:date>2018-03-14T18:13:14Z</dc:date>
    <item>
      <title>API / VIA script / command + how to verify ZKFailoverController status on nodes</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/API-VIA-script-command-how-to-verify-ZKFailoverController/m-p/178805#M75810</link>
      <description>&lt;P&gt;we want to verify by API or any approach by script / command that &lt;STRONG&gt;ZKFailoverController&lt;/STRONG&gt; is started ( status green from ambari GUI )&lt;/P&gt;&lt;P&gt;in our cluster ZKFailoverController is on master01 and master03 machines&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;so how to identify ZKFailoverController is started (green state ) on master01 and master03 machines ?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;example from Ambari GUI&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="64608-capture.png" style="width: 377px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/19455iCF2F739938571BE5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="64608-capture.png" alt="64608-capture.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 18 Aug 2019 09:29:18 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/API-VIA-script-command-how-to-verify-ZKFailoverController/m-p/178805#M75810</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-08-18T09:29:18Z</dc:date>
    </item>
    <item>
      <title>Re: API / VIA script / command + how to verify ZKFailoverController status on nodes</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/API-VIA-script-command-how-to-verify-ZKFailoverController/m-p/178806#M75811</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/26229/uribarih.html" nodeid="26229"&gt;@Michael Bronson&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You can try something like following:&lt;/P&gt;&lt;PRE&gt;#  curl -u admin:admin -H "X-Requested-By: ambari" -X GET "http://amb25101.example.com:8080/api/v1/clusters/plain_ambari/components?fields=ServiceComponentInfo/service_name,ServiceComponentInfo/component_name,ServiceComponentInfo/state,host_components/HostRoles/host_name,host_components/HostRoles/state" | grep -A 2 "\"component_name\" \: \"ZKFC\"" |  awk '{print $NF}' &amp;gt; /tmp/requests_details.txt; sed -e '1,2d' -e s'/--//g'  -e 's/\n//g' -e 's/"//g' -e '/^$/d' /tmp/requests_details.txt | awk 'NR%3{printf "%s ",$0;next;}1' &lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;Example Output:&lt;/P&gt;&lt;PRE&gt;STARTED ZKFC, amb25102.example.com,
STARTED ZKFC, amb25103.example.com,&lt;/PRE&gt;</description>
      <pubDate>Wed, 14 Mar 2018 18:13:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/API-VIA-script-command-how-to-verify-ZKFailoverController/m-p/178806#M75811</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2018-03-14T18:13:14Z</dc:date>
    </item>
  </channel>
</rss>

