Support Questions

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

How to Change Host IP in Ambari View

avatar
Contributor

Hi,

I am having an issue with all the services in my Ambari. All components are in "heartbeat lost" and upon checking I noticed that the IP registered in Ambari Host doest not match the IP in my server. Is there a way to update the IP registered in my Ambari Host to fix the issue. Please see images below.

Ambari IP

13801-ambari-ip.png

Server IP

13802-server-ip.png

Appreciate all your help.

Regards,

Bruce

1 ACCEPTED SOLUTION

avatar
Expert Contributor

Bruce,

Try to change your /etc/hosts file accordingly and restart the sandbox and check ambari host

View solution in original post

6 REPLIES 6

avatar
Expert Contributor

Bruce,

Try to change your /etc/hosts file accordingly and restart the sandbox and check ambari host

avatar
Contributor

@icocio, thanks for your help, actually this is one file that I reconfigured. I updated my hostname and network settings. After that, I restarted my network server and it solves the issue.

avatar
Super Guru

@Bruce Perez

I suspect a refresh problem between hosts file content ... Hopefully, you server has a static IP address because if that is not the case that could be a continuous problem.

Open a terminal window and try first to stop and start Ambari agent

#ambari-agent stop

#ambari-agent start

Check if that fixed the problem. Then try to stop and start Ambari server

#ambari-server stop

#ambari-server start

Anyhow, host IP address is not something managed by Ambari. It supposed to display the actual IP address of the server. You were not supposed to change the server IP address to match what Ambari UI shows. It supposed to have Ambari UI properly show what the server IP address is set 🙂

++++

Let me know if this helped.

avatar
Contributor

@Constantin Stanca, thanks for your answer. I fixed my issue by setting my host ip and hostname in the server as it does not have the proper configuration. Then I restarted the network server. It resolves the issue. 🙂

avatar
Super Guru

@Bruce Perez

Good to hear. That was a force major solution which worked and it is not a big deal for a sandbox. However, for your learning exercise, re-read your question and my answer. That is helpful when you get out of the sandbox and deal with actual production servers where brute force solutions have implications. You should not change the IP address because Ambari shows something else. I responded to your question as it was stated for a server. When you will do a production installation you will see that is a step for hosts registration. At that time you will have the IP address set. Changes to that IP address are still possible but they could have some ripple effect if not handled properly.

avatar
Super Guru

For a multi-node production cluster, it is sufficient to update hosts files and restart agents in each of the nodes showing the wrong IP.