ISSUE :
 
Profile photo
Submitted by Martin Fowler
on July 13th, 2011 at 11:40:31 EST

Default port for HSQLDB and Tomcat issues

Hi,
I want to know what is the default port for Tomcat App server and HSQLDB?
Also if I have more than one app or db server running I often get port conflict.
How do I change default port and resolve conflict?
Thanks,
Martin


Profile photo
Replied by Yogaraj Khanal
on July 13th, 2011 at 13:50:59 EST
For Tomcat go to <CATALINA_HOME>/conf and open server.xml to find these content

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

Change the port that is available and you want to change save file and restart the Tomcat will do the job.

For HSQLDB:
server.properties file
server.port=9123(change to what you need)
In the web.xml change the port no to this.

<context-param>
<param-name>hsqldb-port</param-name>
<param-value>YOUR_PORT</param-value>
</context-param>
Accepted Answer
Accepted
 Answer

Profile photo
Replied by Martin Fowler
on July 13th, 2011 at 14:38:28 EST
Thanks.