Support Questions

Find answers, ask questions, and share your expertise

Tomcat Installation in Azure on port 2222

avatar

Hi Team,

I have installed hortonworks on Azure. And also deployed tomcat on port 2222. I have change the port(12123) for tomcat server.xml . I am not able to see the login screen of tomcat.

Kindly suggest.

Thanks In advance.

Thanks,

Vishal Gupta

1 ACCEPTED SOLUTION

avatar
Master Mentor

@Vishal Gupta

Please try this.

Change your Tomcat port to 9090 (instead of 2222) and then try again

9090 is the defauilt Nifi Port , which might not be running on your Sandbox and the port forwarding rules are already setup for port 9090 so you should be fine with this port.

Change the tomcat port to 9090 and then restart the tomcat then try accessing the tomcat URL on this port.

View solution in original post

10 REPLIES 10

avatar
Master Mentor

@Vishal Gupta

1. Can you please share the exact set of tags where you made the port changes inside the "server.xml"

2. On the tomcat host are you able to see the port is listening and bound properly?

# netstat -tnlpa | grep 12123
# netstat -tnlpa | grep 2222

3. Do you see any error inside the "catalina.out" ?

4. Is there any restriction at firewall level which is restricting the port 12123 access? Can you check the firewall rules (may be it is set in such a way that the port 2222 only will be accessible).

avatar

Hi,

1. Attaching you the server.xml

2. netstat -tnlpa | grep 12123 .

below is the output .

tcp 0 0 :::12123 :::* LISTEN 10595/java

netstat -tnlpa | grep 2222

The above command gives no output.

3. Catalina.out has no error.

4.How to check firewall ? Also

this url is working fine

http://52.177.199.181:8888/splash2.html.

http://52.177.199.181:8080/ is not displaying anything . I guess there is firewall issue.

avatar
Master Mentor

@Vishal Gupta

Are you talking about Azure HDP Sandbox?

If yes, then there is a separate way to add ports. As it runs on docker container. Please see the following guides to know how sandbox exposes the ports.

Add ports to Azure HDP Sandbox Docker: https://hortonworks.com/tutorial/sandbox-port-forwarding-guide/section/4/

For adding new Ports: https://community.hortonworks.com/articles/65914/how-to-add-ports-to-the-hdp-25-virtualbox-sandbox.h... (even though this link says VirtualBox but should be fine in your case)

avatar

Hi Jay,

Thanks for the suggestion.

Well my azure ip is say "125.32.45.85" from where i run the below command ,

ssh -p 2222 root@localhost.

as per the docs you provided , where i need to run the below command.

ssh azureSandbox. I Have tried the command from azure ip as well as after running the below command also ssh -p 2222 root@localhost.

but none of them worked.

Thanks in advance.

avatar
Master Mentor

@Vishal Gupta

The prerequisite of setting up the Azure Sandbox is described here: https://hortonworks.com/tutorial/sandbox-deployment-and-install-guide/section/4/

So please check if you have done the Local Forwards properly or not as described in the above link?

avatar

test.txtHi,

I followed the below steps .

https://hortonworks.com/tutorial/sandbox-deployment-and-install-guide/section/4/

but it didnt worked. I have installed the tomcat in 2222 port.

attaching you the config file in test.txt

Thanks,

Vishal

avatar
Master Mentor

@Vishal Gupta

Please try this.

Change your Tomcat port to 9090 (instead of 2222) and then try again

9090 is the defauilt Nifi Port , which might not be running on your Sandbox and the port forwarding rules are already setup for port 9090 so you should be fine with this port.

Change the tomcat port to 9090 and then restart the tomcat then try accessing the tomcat URL on this port.

avatar
Master Mentor

@Vishal Gupta

Good to know that your issue is resolved. It will be great if you can mark this thread as Answered by clicking on the "Accept" link on the answer which helped in resolving the issue. That way it will be helpful for other HCC users to quickly find the solution.

avatar

Hi,

I changed the port to 9090 . still it didnt worked . port 2222 is hortonworks sandbox port on which i deployed the tomcat with 12123 port. But now i changed to 9090 but still it didnt worked.

Thanks,

Vishal Gupta