Conflict when JBoss AS 5 and Tomcat 5 stand-alone are in the
showmanlkz Aug 2, 2009 6:59 PMHi,
I need to run both JBoss 5 and Tomcat 5 (stand-alone) on the same server and both connect to Apache HTTP server by using mod_jk.
The mod_jk configuration seems to be correct because request/worker mapping works correctly if I only run either JBoss 5 or Tomcat 5.
When both servers are running, it maybe cause a conflict, typically, if I try to visit a website hosted by Tomcat, there will be HTTP Status 404, returned by JBoss Web/2.1.1.GA. It could be the other way around if I try to visit a website hosted by JBoss (so Tomcat may return 404). This is not always happen but very often.
I configured both JBoss and Tomcat server.xml as follow
# #JBOSS AS 5 server.xml # <Service name="jboss.web"> <!-- A HTTP/1.1 Connector on port 8080 --> <Connector protocol="HTTP/1.1" port="8090" address="${jboss.bind.address}" connectionTimeout="20000" redirectPort="8453" /> <!-- A AJP 1.3 Connector on port 8009 --> <Connector protocol="AJP/1.3" port="8010" address="${jboss.bind.address}" redirectPort="8453" /> <Engine name="jboss.web" defaultHost="localhost" jvmRoute="node1"> .... </Engine> </Service>
<Server port="8005" shutdown="SHUTDOWN"> <!-- Define the Tomcat Stand-Alone Service --> <Service name="Catalina"> <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 --> <Connector port="8085" maxHttpHeaderSize="8192" maxThreads="150" minSpareThreads="25" maxSpareThreads="75" enableLookups="false" redirectPort="8448" acceptCount="100" connectionTimeout="20000" disableUploadTimeout="true" /> <!-- Note : To disable connection timeouts, set connectionTimeout value to 0 --> <!-- Define a SSL HTTP/1.1 Connector on port 8443 --> <!-- <Connector port="8443" maxHttpHeaderSize="8192" maxThreads="150" minSpareThreads="25" maxSpareThreads="75" enableLookups="false" disableUploadTimeout="true" acceptCount="100" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" /> --> <!-- Define an AJP 1.3 Connector on port 8009 --> <Connector port="8009" enableLookups="false" redirectPort="8448" protocol="AJP/1.3" /> <Engine name="Catalina" defaultHost="localhost" jvmRoute="node2"> <Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false"> </Host> </Engine> </Service> </Server>
I could not think of anywhere else JBoss and Tomcat would conflict with each other. Any suggestion?
Thanks~
Der