Centos – tomcat server port and tomcat connector port are these same

centostomcat

Is the Tomcat server port and the Tomcat connector port the same or should they be same?

I changed my Tomcat5 server port to 8005. my centOS server shows that the Tomcat service is running. Howver, I am unable to access it through the browser.

Should I also change the connector port? I have ISPconfig installed on centOS.

Connector port config looks like this:

<Connector port="8080" protocol="HTTP/1.1" 
       connectionTimeout="20000" 
       URIEncoding="UTF-8"
       address="0.0.0.0"
       redirectPort="8443" />

Best Answer

These values should not be the same, and likely are causing one of the Connectors to fail to start. The reason you cannot connect via a browser is that the service listening on 8005 is not HTTP, but rather the default Tomcat listener for issuing management commands (like shutdown).

You will need to define an HTTP connector in order to connect directly from a web browser. This would look something like:

<Connector port="8080" maxHttpHeaderSize="8192"
           maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
           enableLookups="false" redirectPort="8443" acceptCount="100"
           connectionTimeout="20000" disableUploadTimeout="true" />
Related Topic