<?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: Ambari Agent failed to start in manual installation in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106640#M54542</link>
    <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/users/15105/rahgulati.html"&gt;@rahul gulati&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Are you sure that when you are running the following command on those hosts individually then you are getting the correct FQDN?&lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;hostname -f&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;-
 Ambari agent sends registration request to ambari-server every time 
when agent is restarted. In the registration request it sends the FQDN 
information of it's own as well.   Agent uses the following approach to 
findout the FQDN using python. So please check if all your hosts are 
returning correct hostname &lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;python -c "import socket; print socket.getfqdn()"&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;Also
 in local system it might get using which is not actually FQDN as above.
 So local agent might behave bit differently then remote.&lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;python -c "import socket; print socket.gethostname()"&lt;/LI&gt;&lt;/OL&gt;</description>
    <pubDate>Wed, 15 Feb 2017 23:03:07 GMT</pubDate>
    <dc:creator>jsensharma</dc:creator>
    <dc:date>2017-02-15T23:03:07Z</dc:date>
    <item>
      <title>Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106630#M54532</link>
      <description>&lt;P&gt;I am installing 4 node cluster using ambari. I installed ambari server and ambari agent on master node. In addition to that i have installed ambari agents on 2 slave nodes. Ambari server and ambari agents on master node is running.But i am unable to start ambari-agent on my slave nodes due to the error  "Ambari Agent start fails with local variable 'server_url' referenced before assignment". This seems like jira bug but it has already been fixed.&lt;/P&gt;&lt;P&gt;&lt;A href="https://issues.apache.org/jira/browse/AMBARI-19246" target="_blank"&gt;https://issues.apache.org/jira/browse/AMBARI-19246&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I am using ambari version 2.4.2&lt;/P&gt;&lt;P&gt;Could anyone please help me in starting agents on slave nodes?&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 16:59:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106630#M54532</guid>
      <dc:creator>munnyrahul</dc:creator>
      <dc:date>2017-02-15T16:59:56Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106631#M54533</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15105/rahgulati.html" nodeid="15105"&gt;@rahul gulati&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Yes, its a bug also reported in HDP JIRA - &lt;A href="https://hortonworks.jira.com/browse/BUG-70990" target="_blank"&gt;https://hortonworks.jira.com/browse/BUG-70990&lt;/A&gt; [Internal link for reference]&lt;/P&gt;&lt;P&gt;This will be fixed in up coming Ambari Release version 2.5.0. &lt;/P&gt;&lt;P&gt;If you are looking to get a patch to Fix this issue, please reach out to Hortonworks Support team to get Subscription.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:14:34 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106631#M54533</guid>
      <dc:creator>sshimpi</dc:creator>
      <dc:date>2017-02-15T17:14:34Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106632#M54534</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15105/rahgulati.html" nodeid="15105"&gt;@rahul gulati&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Check if the below think works and resolve the issue -&lt;/P&gt;&lt;P&gt;Suspected the issue is with snmpd service not installed or installed and not running.

&lt;STRONG&gt;Execute: &lt;/STRONG&gt;
1) service snmpd start
If this does not recognize the service then snmpd needs to be installed and proceed with remaining steps.
2) yum -y install net-snmp net-snmp-utils
3) service snmpd start&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:16:59 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106632#M54534</guid>
      <dc:creator>sshimpi</dc:creator>
      <dc:date>2017-02-15T17:16:59Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106633#M54535</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/2648/sshimpi.html" nodeid="2648"&gt;@Sagar Shimpi&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Thanks for replying. Then i want to check how to register host in case of ambari installation if manual installation is not working? I am stuck at registering host since i cannot install and start ambari agents on slave nodes.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:17:16 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106633#M54535</guid>
      <dc:creator>munnyrahul</dc:creator>
      <dc:date>2017-02-15T17:17:16Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106634#M54536</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15105/rahgulati.html" nodeid="15105"&gt;@rahul gulati&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Although the workaround is quite simple. Just edit the file &lt;EM&gt;&lt;STRONG&gt;"/usr/lib/python2.6/site-packages/ambari_agent/main.py"&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Just change the line &lt;EM&gt;&lt;STRONG&gt;"&lt;/STRONG&gt;&lt;/EM&gt;&lt;STRONG&gt;server_ip = socket.gethostbyname(server_hostname)&lt;/STRONG&gt;&lt;EM&gt;&lt;STRONG&gt;"&lt;/STRONG&gt;&lt;/EM&gt; as mentioned in: &lt;/P&gt;&lt;P&gt;
&lt;A href="https://git1-us-west.apache.org/repos/asf?p=ambari.git;a=commitdiff;h=a43837a35536096224a77356a4049ea5b01a8bdc;hp=8b3ec80cef1ac453b53b24cd0e0efa944cb45c89" target="_blank"&gt;https://git1-us-west.apache.org/repos/asf?p=ambari.git;a=commitdiff;h=a43837a35536096224a77356a4049ea5b01a8bdc;hp=8b3ec80cef1ac453b53b24cd0e0efa944cb45c89&lt;/A&gt;&lt;/P&gt;&lt;P&gt;This need to be done on all the ambari-agent hosts and then followed by &lt;STRONG&gt;"ambari-agent restart"
&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;.
&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;NOTE&lt;/STRONG&gt;: It should help only if your issue is exactly same as the one mentioned in : &lt;STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://issues.apache.org/jira/browse/AMBARI-19246"&gt;https://issues.apache.org/jira/browse/AMBARI-19246&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:19:13 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106634#M54536</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-02-15T17:19:13Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106635#M54537</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/3418/jsensharma.html" nodeid="3418"&gt;@Jay SenSharma&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Thanks for the answer. I am able to start the ambari agent successfully on all the 3 nodes. Thanks to you. But while registering the agents from ambari UI i am getting Registration failed for slave nodes although master is able to register successfully. Any idea why? I am not able to see any other logs.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:36:39 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106635#M54537</guid>
      <dc:creator>munnyrahul</dc:creator>
      <dc:date>2017-02-15T17:36:39Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106636#M54538</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15105/rahgulati.html" nodeid="15105"&gt;@rahul gulati&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Good to know that your original issue is resolved.&lt;/P&gt;&lt;P&gt;Can you please share more details about your latest error?   &lt;/P&gt;&lt;P&gt;1. ambari-server.log snippet&lt;/P&gt;&lt;P&gt;2. Screenshot of the error.&lt;/P&gt;&lt;P&gt;Few things you might want to check is&lt;/P&gt;&lt;P&gt;1. If you are able to do password less ssh to those hosts.  That might not  be needed though.&lt;/P&gt;&lt;P&gt;2. If ambari server is able to recognize all the agents hosts using their "hostname -f"  (FQDN output) &lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 17:41:44 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106636#M54538</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-02-15T17:41:44Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106637#M54539</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/3418/jsensharma.html" nodeid="3418"&gt;@Jay SenSharma&lt;/A&gt; &lt;/P&gt;&lt;P&gt;actually it was not able to establish connection to ambari server hostname. So i changed the value from hostname to IP address in ambari.ini file. And it worked. But i wanted to ask one thing that i kept host name in master node ambari.ini file where ambari server is installed and it worked in first go but in slave nodes ambari.ini file it worked wit IP. Any specific reasons for that?&lt;/P&gt;&lt;P&gt;And once again that for the above answer. It worked like charm. Could not be possible to wait till 2.5 release. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 18:02:45 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106637#M54539</guid>
      <dc:creator>munnyrahul</dc:creator>
      <dc:date>2017-02-15T18:02:45Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106638#M54540</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15105/rahgulati.html" nodeid="15105"&gt;@rahul gulati&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Good to know that it worked well after fixing the hostname.&lt;/P&gt;&lt;P&gt;Ambari (and also HDP) is very much dependent on the FQDN  (hostname -f) so every host must be able to recognize then using the FQDN (instead of IP). Even ambari agent script uses the same approach to get the hostname of it's own.&lt;/P&gt;&lt;PRE&gt;host_name = socket.gethostname().lower()
host_ip = socket.gethostbyname(host_name)
host_fqdn = socket.getfqdn().lower()
fqdn_ip = socket.gethostbyname(host_fqdn)
return host_ip == fqdn_ip&lt;/PRE&gt;&lt;P&gt;. &lt;/P&gt;&lt;P&gt;See: &lt;/P&gt;&lt;P&gt;&lt;A href="http://docs.hortonworks.com/HDPDocuments/Ambari-2.2.2.0/bk_Installing_HDP_AMB/content/_edit_the_host_file.html"&gt;http://docs.hortonworks.com/HDPDocuments/Ambari-2.2.2.0/bk_Installing_HDP_AMB/content/_edit_the_host_file.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 18:58:29 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106638#M54540</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-02-15T18:58:29Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106639#M54541</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/3418/jsensharma.html" nodeid="3418"&gt;@Jay SenSharma&lt;/A&gt;&lt;/P&gt;&lt;P&gt;My ambari-agents are successfully registered with ambari-server but i am seeing a warning which says that hostname resolution issue in which it says not all the hosts could resolve hostname of other hosts. &lt;/P&gt;&lt;P&gt;Although i have added the IP addresses and hostnames of all the hosts in /etc/hosts files of all the 4 nodes. But still it is not able to resolve. Anything else to do?&lt;/P&gt;&lt;P&gt;Below is my example /etc/hosts file on edge node(where abcd, etf, sco, jfjf are hostnames of edge, master, slave1 and slave 2 nodes resp). Same goes with all other nodes as well&lt;/P&gt;&lt;P&gt;127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6 &lt;/P&gt;&lt;P&gt;1.2.3.4  abcd &lt;/P&gt;&lt;P&gt;3.4.5.6  etf &lt;/P&gt;&lt;P&gt;7.8.9.1 sco &lt;/P&gt;&lt;P&gt;10.11.12.13 jfjf&lt;/P&gt;&lt;P&gt;Please note that the ambari.ini file on slave1, slave2 and edge node has IP address as hostname while master node file has hostname of masternode. This is how it is setup and is working. Because i tried to register ambari agents by giving hostname in ambari.ini files of slaves and edge node but i was getting failure but master ambari agent was able to register with ambari server with fqdn.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 21:44:54 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106639#M54541</guid>
      <dc:creator>munnyrahul</dc:creator>
      <dc:date>2017-02-15T21:44:54Z</dc:date>
    </item>
    <item>
      <title>Re: Ambari Agent failed to start in manual installation</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106640#M54542</link>
      <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/users/15105/rahgulati.html"&gt;@rahul gulati&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Are you sure that when you are running the following command on those hosts individually then you are getting the correct FQDN?&lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;hostname -f&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;-
 Ambari agent sends registration request to ambari-server every time 
when agent is restarted. In the registration request it sends the FQDN 
information of it's own as well.   Agent uses the following approach to 
findout the FQDN using python. So please check if all your hosts are 
returning correct hostname &lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;python -c "import socket; print socket.getfqdn()"&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;Also
 in local system it might get using which is not actually FQDN as above.
 So local agent might behave bit differently then remote.&lt;/P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;OL&gt;&lt;LI&gt;python -c "import socket; print socket.gethostname()"&lt;/LI&gt;&lt;/OL&gt;</description>
      <pubDate>Wed, 15 Feb 2017 23:03:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ambari-Agent-failed-to-start-in-manual-installation/m-p/106640#M54542</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-02-15T23:03:07Z</dc:date>
    </item>
  </channel>
</rss>

