<?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 HostCleanup.py failing in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220301#M62990</link>
    <description>&lt;P&gt;i am trying to cleanup the existing cluster for new install but this script fails with the following error:&lt;/P&gt;&lt;PRE&gt;[root@hadoop1 ambari_agent]# python HostCleanup.py --help
  File "HostCleanup.py", line 111
    except Exception, err:
                    ^
SyntaxError: invalid syntax
&lt;/PRE&gt;</description>
    <pubDate>Fri, 16 Jun 2017 00:05:42 GMT</pubDate>
    <dc:creator>aliyesami</dc:creator>
    <dc:date>2017-06-16T00:05:42Z</dc:date>
    <item>
      <title>HostCleanup.py failing</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220301#M62990</link>
      <description>&lt;P&gt;i am trying to cleanup the existing cluster for new install but this script fails with the following error:&lt;/P&gt;&lt;PRE&gt;[root@hadoop1 ambari_agent]# python HostCleanup.py --help
  File "HostCleanup.py", line 111
    except Exception, err:
                    ^
SyntaxError: invalid syntax
&lt;/PRE&gt;</description>
      <pubDate>Fri, 16 Jun 2017 00:05:42 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220301#M62990</guid>
      <dc:creator>aliyesami</dc:creator>
      <dc:date>2017-06-16T00:05:42Z</dc:date>
    </item>
    <item>
      <title>Re: HostCleanup.py failing</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220302#M62991</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/10115/sahmad43.html" nodeid="10115" target="_blank"&gt;@Sami Ahmad&lt;/A&gt;
Which exact version of ambari are you using? &lt;/P&gt;&lt;P&gt;I do not see any matching line at 111 on that script of Ambari 2.2.2 / 2.4.0/ 2.4.2/ 2.5.0 versions of API.&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/apache/ambari/blob/release-2.5.0/ambari-agent/src/main/python/ambari_agent/HostCleanup.py" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/apache/ambari/blob/release-2.5.0/ambari-agent/src/main/python/ambari_agent/HostCleanup.py&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/apache/ambari/blob/release-2.4.2/ambari-agent/src/main/python/ambari_agent/HostCleanup.py" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/apache/ambari/blob/release-2.4.2/ambari-agent/src/main/python/ambari_agent/HostCleanup.py&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/apache/ambari/blob/release-2.2.2/ambari-agent/src/main/python/ambari_agent/HostCleanup.py" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/apache/ambari/blob/release-2.2.2/ambari-agent/src/main/python/ambari_agent/HostCleanup.py&lt;/A&gt;&lt;/P&gt;&lt;P&gt;- I see line 111 is empty.  (So i am suspecting that the script that you are using might be slightly changed/edited).&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="16409-line-111.png" style="width: 472px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/15900i2F5EE58189D07A94/image-size/medium?v=v2&amp;amp;px=400" role="button" title="16409-line-111.png" alt="16409-line-111.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt; So by any chance have you made any modification to this script?&lt;/P&gt;&lt;PRE&gt;# /usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py&lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;- What is your python version?&lt;/P&gt;&lt;P&gt;- If you continue to face this issue then it will be quick to "Uninstall ambari-agent" and then install it back after manually cleaning up the agent directories.&lt;/P&gt;&lt;PRE&gt;# yum remove ambari-agent 
# yum install ambari-agent
&lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;</description>
      <pubDate>Sun, 18 Aug 2019 02:30:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220302#M62991</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2019-08-18T02:30:10Z</dc:date>
    </item>
    <item>
      <title>Re: HostCleanup.py failing</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220303#M62992</link>
      <description>&lt;P&gt;thanks Jay  , reinstalling agent fixed this script. &lt;/P&gt;&lt;P&gt;I will go ahead and  deinstall the cluster using this script and then try to reinstall  again.&lt;/P&gt;&lt;P&gt;my cluster was running f ine until I  deinstalled it and since then I am unable to get it up and running . &lt;/P&gt;</description>
      <pubDate>Sat, 17 Jun 2017 10:07:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/HostCleanup-py-failing/m-p/220303#M62992</guid>
      <dc:creator>aliyesami</dc:creator>
      <dc:date>2017-06-17T10:07:33Z</dc:date>
    </item>
  </channel>
</rss>

