Tomcat is most popular web server for hosting java based websites. If you want to install tomcat on your system use following tutorials. By default tomcat runs on port 8080. This tutorial will help you to change tomcat server default port.
Change Tomcat Default Port
Edit server.xml file located under conf directory of tomcat installation.
$ vi [TOMCAT INSTALL DIR]/conf/server.xml
Find the below content in configuration file
8080" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" />
Replace port 8080 with your required port. For example we are changing the default tomcat port with 8081.
8081" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" />
After making above changes restart tomcat service. You will see that now tomcat is started on port 8081 or port you configured. Access tomcat on new port in web browser.