-
1. Re: HTTPConnector - Bind port 80 on specific IP address
jfair Sep 23, 2003 8:01 AM (in response to jfair)Is there any way to have the HTTPConnector to open a server socket on a specific IP address?
From my server.log:
2003-09-23 09:48:47,664 INFO [STDOUT] Apache Tomcat/4.1.12-LE-jdk14
2003-09-23 09:48:47,684 INFO [org.jboss.web.localhost.Engine] HttpConnector Opening server socket on all host IP addresses
2003-09-23 09:48:47,694 INFO [org.jboss.web.localhost.Engine] HttpConnector[80] Starting background thread
2003-09-23 09:48:47,714 INFO [org.jboss.web.localhost.Engine] HttpProcessor[80][0] Starting background thread
2003-09-23 09:48:47,724 INFO [org.jboss.web.localhost.Engine] HttpProcessor[80][1] Starting background thread
2003-09-23 09:48:47,744 INFO [org.jboss.web.localhost.Engine] HttpProcessor[80][2] Starting background thread
2003-09-23 09:48:47,754 INFO [org.jboss.web.localhost.Engine] HttpConnector Opening server socket on all host IP addresses
2003-09-23 09:48:47,965 INFO [org.jboss.web.localhost.Engine] HttpConnector[443] Starting background thread
2003-09-23 09:48:47,975 INFO [org.jboss.web.localhost.Engine] HttpProcessor[443][0] Starting background thread
2003-09-23 09:48:47,985 INFO [org.jboss.web.localhost.Engine] HttpProcessor[443][1] Starting background thread
2003-09-23 09:48:48,005 INFO [org.jboss.web.localhost.Engine] HttpProcessor[443][2] Starting background thread
2003-09-23 09:48:48,025 INFO [org.jboss.web.localhost.Engine] HttpProcessor[443][3] Starting background thread
2003-09-23 09:48:48,035 INFO [org.jboss.web.localhost.Engine] HttpProcessor[443][4] Starting background thread -
2. Re: HTTPConnector - Bind port 80 on specific IP address
jfair Sep 23, 2003 9:01 AM (in response to jfair)Solved it - should have looked at the code for the HTTPConnector before posting. I needed to specify an address attribute on the HTTPConnector node. By default, if no address is supplied the HTTPConnector opens a server socket on all host IP addresses.
tomcat41-service.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!-- Set catalina.home to the location of the Tomcat-4.1.x dist.
The default value is that of the JBoss/Catalina bundle where the
jakarta-tomcat-4.1.12-LE-jdk14 is included as jboss_dist/catalina
-->
<!DOCTYPE server [
<!ENTITY catalina.home "../tomcat-4.1.x">
]>
<!-- The service configuration for the embedded Tomcat4.1.x web container
-->
&catalina.home;
<!-- Uncomment this if you want interval snapshot for the
session clustering.
interval
2000
-->
<!-- A HTTP Connector on port 8080 -->
<Connector className = "org.apache.catalina.connector.http.HttpConnector"
port = "80" address="172.22.56.14" minProcessors = "3" maxProcessors = "1000" enableLookups = "true"
acceptCount = "1000" debug = "0" connectionTimeout = "60000"/>
<!-- A HTTPS Connector on port 443 -->
<Connector className = "org.apache.catalina.connector.http.HttpConnector"
port = "443" address="172.22.56.14" scheme="https" secure = "true">
Thanks anyways..