Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Can Ambari server and agent run on same host ?

avatar
Contributor

Hello,

I am a newbie to horton and ambari. I am trying to make a 2 node hadoop cluster with physical server.

I am thinking of using Ambari to do provisioning. However since i only have 2 nodes, can i use Ambari server and ambari-agent on same node?

Right now if i do that, ambari-agent fails to startup and gives java unknown host exception . when i used FQDN

Thanks

1 ACCEPTED SOLUTION

avatar

Yes thats possible and necessary if you want to add services to your Ambari-server node.

How does your Ambari Agent configuration look like?

Make sure you have prepared the environment according to http://docs.hortonworks.com/HDPDocuments/Ambari-2.1.2.1/bk_Installing_HDP_AMB/content/_prepare_the_e..., especially DNS settings.

View solution in original post

33 REPLIES 33

avatar
Master Mentor

@Majid Ali Syed Amjad Ali Sayed paste output of every command on the second node

avatar
Contributor

@Artem,

This is output of /etc/hosts on second node

127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4

::1 localhost localhost.localdomain localhost6 localhost6.localdomain6

10.10.8.152 krplhadoop2.kaimrc

10.10.8.151 krplhadoop.kaimrc

avatar
Master Mentor

Also agent.ini and hostname output @Majid Ali Syed Amjad Ali Sayed

avatar
Master Mentor

@Majid Ali Syed Amjad Ali Sayed can you modify your /etc/hosts on both nodes like this

10.10.8.152 krplhadoop2.kaimrc krplhadoop2

10.10.8.151 krplhadoop.kaimrc krplhadoop

then restart ambari-server and agents

also provide a screenshot and error after this modification.

avatar
Contributor

@Artem Ervits

I made the changes you suggested, no luck.

There is no error. The installation gets stuck at step number 8. The following screen shot shows where it gets stuck and then after sometime it goes to same place.

The packages are not being deployed

ambari-freezee.gif

avatar
Contributor

@Artem

On node 2 :

hostname -f

krplhadoop2.kaimrc

The server contents of ambari-agent .ini is as follows

[server] hostname=10.10.8.151

url_port=8440

secured_url_port=8441

avatar
Master Mentor

Please change ip to fqdn of ambari server @Majid Ali Syed Amjad Ali Sayed in ini file

avatar
Contributor

@Artem

Ok, changed now i restart agent on second node and also restart server ?

avatar
Master Mentor

You can but if you look in ambari-server logs and see agent registered its fine too. Let me know how it goes @Majid Ali Syed Amjad Ali Sayed

avatar
Contributor

Unfortunately, it gets stuck at same place. I even restarted agents and servers .@Artem