<?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 How can I put Secondary Namenode to maintenance mode using ambari REST API in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-can-I-put-Secondary-Namenode-to-maintenance-mode-using/m-p/226381#M70142</link>
    <description>&lt;P&gt;I want to turn on and off maintenance mode for Secondary NN using Ambari REST API. How can I do that?&lt;/P&gt;</description>
    <pubDate>Tue, 24 Oct 2017 15:55:47 GMT</pubDate>
    <dc:creator>kedari_sk13</dc:creator>
    <dc:date>2017-10-24T15:55:47Z</dc:date>
    <item>
      <title>How can I put Secondary Namenode to maintenance mode using ambari REST API</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-can-I-put-Secondary-Namenode-to-maintenance-mode-using/m-p/226381#M70142</link>
      <description>&lt;P&gt;I want to turn on and off maintenance mode for Secondary NN using Ambari REST API. How can I do that?&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2017 15:55:47 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-can-I-put-Secondary-Namenode-to-maintenance-mode-using/m-p/226381#M70142</guid>
      <dc:creator>kedari_sk13</dc:creator>
      <dc:date>2017-10-24T15:55:47Z</dc:date>
    </item>
    <item>
      <title>Re: How can I put Secondary Namenode to maintenance mode using ambari REST API</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-can-I-put-Secondary-Namenode-to-maintenance-mode-using/m-p/226382#M70143</link>
      <description>&lt;P&gt; &lt;A rel="user" href="https://community.cloudera.com/users/44529/kedarisk13.html" nodeid="44529"&gt;@Shravan Kumar&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;You can use the below API for Turn ON and Turn OFF respectively&lt;/P&gt;&lt;PRE&gt;curl -k -u &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H "X-Requested-By:ambari" -i -X PUT -d '{"RequestInfo":{"context":"Turn On Maintenance Mode for SNameNode"},"Body":{"HostRoles":{"maintenance_state":"ON"}}}' &lt;A href="http://{ambari-host}:{ambari-port}/api/v1/clusters/{clustername}/hosts/{hostname}/host_components/SECONDARY_NAMENODE" target="_blank"&gt;http://{ambari-host}:{ambari-port}/api/v1/clusters/{clustername}/hosts/{hostname}/host_components/SECONDARY_NAMENODE&lt;/A&gt; &lt;/PRE&gt;
&lt;PRE&gt;curl -k -u &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H "X-Requested-By:ambari" -i -X PUT -d '{"RequestInfo":{"context":"Turn Off Maintenance Mode for SNameNode"},"Body":{"HostRoles":{"maintenance_state":"OFF"}}}' &lt;A href="http://{ambari-host}:{ambari-port}/api/v1/clusters/{clustername}/hosts/{hostname}/host_components/SECONDARY_NAMENODE" target="_blank"&gt;http://{ambari-host}:{ambari-port}/api/v1/clusters/{clustername}/hosts/{hostname}/host_components/SECONDARY_NAMENODE&lt;/A&gt;&lt;/PRE&gt;&lt;P&gt; Replace the ambari-host,ambari-port , clustername and hostname placeholders with the original value.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aditya&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2017 15:57:27 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-can-I-put-Secondary-Namenode-to-maintenance-mode-using/m-p/226382#M70143</guid>
      <dc:creator>asirna</dc:creator>
      <dc:date>2017-10-24T15:57:27Z</dc:date>
    </item>
  </channel>
</rss>

