Default port of tomcat is 8080, this port can be changed to any other port. Normally HTTP port is 80, tomcat port can change through server.xml in config folder of tomcat.
How to change tomcat port 8080
c:\tomcat\conf\server.xml
Search for this line
<Connector port="8080" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
connectionTimeout="20000"
redirectPort="8443" />
Change to 8080 to your desire port Number
<Connector port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
connectionTimeout="20000"
redirectPort="8443" />
After modification in server.xml file, tomcat must be restarted.
Tags: Tomcat



Link to Us
Hi,
I did the changes as mentioned, after that when i am not able to access the page from localhost
eg:
Before changing, i was able to access my project by the url – http://localhost:8080/project
After changing the server.xml file, i am not able to access my project with http://localhost/project.
Can anybody help me out with this…
Thanks,
Ramesh
After changing port in this file server.xml. Have you restart tomcat? If not first restart tomcat. IF still it is not working. then check 80 port is not using by some other application. Mostly apache httpd server use 80 port. tomcat will give error of already bind 80.
or you can check ports which are running by command.
netstats -a
and check which application is using 80 port stop that port and again restart tomcat and then check.