Support Questions
Find answers, ask questions, and share your expertise

I am getting 502 Bad Gateway while loading the localhost:8080 ambari UI. Please suggest what could be the issue ?

 
1 ACCEPTED SOLUTION

Super Collaborator

@Divya Thaore 502 Bad Gateway error is usually indicating a networking error, Try restart of the browser or try accessing from Incognito mode

View solution in original post

8 REPLIES 8

Super Collaborator

@Divya Thaore 502 Bad Gateway error is usually indicating a networking error, Try restart of the browser or try accessing from Incognito mode

@scharan : tried incognito too. not working.. i dont think it's browser issue

New Contributor

Hi, even I am facing the same trouble when trying to load Ambari web page, it shows 502 error.

 

It was working fine 2 days back but the error is showing from today when I tried to login in the morning.

I have tried all the replies stated above, none worked. I will be grateful if someone can resolve this issue at the earliest.

 

Many Thanks

Super Collaborator

@Divya Thaore Are you see any errors in Browser Inspect element , Also check ambari-server logs

Mentor

@Divya Thaore

You are trying to access the sandbox:8080 from your laptop because localhost:8080 translates to your local windows machine. To be able to access sandbox ambari from your Windows machine, you should have an entry in your hosts file in C:\Windows\System32\drivers\etc with the format IP:FQDN:ALIAS for example


# localhost name resolution is handled within DNS itself.
#127.0.0.1     localhost
#::1           localhost
127.0.0.1      sandbox.hortonworks.com   sandbox    

With the above entry assuming you sandbox IP is correctly you can access your cluster through

http://sandbox:8080

HTH

Explorer

Hi @Shelton 

 

I followed your suggestion and modified HOSTS file in the C:\Windows\System32\drivers\etc on my Windows 7 machine where the VirtualBox/Sandbox is installed, it still prompts me the 502 error.

 

Here are the hosts file:


127.0.0.1 localhost
::1 localhost
127.0.0.1 sandbox.hortonworks.com sandbox

 

I used the Windows7 built-in Resource Monitor to inspect which application is using 8080, and it shows VirtualBox:

port 8080 used by VirtualBox already

Since VirtualBox is where the sandbox resides, there is no way for me to terminate it. How do I then access Ambari from localhost?

 

Thank you very much if you can kindly help me to sort it out at your earliest convenience.

 

 

New Contributor

instead of localhost try using the IP address of the server.  That should help

; ;