I'm setting up tomcat and I noticed what I think is an odd behavior.

I'm setting up the server to only listen on an ajp port (8009). If I already
have something listening on that port then tomcat starts listening on the next
port number (8010). This doesn't happen if the shutdown port is already in use
or if I try it with a http connector port that is in use.

I don't seem any mention of this behavior in the docs. I do see an autobind
option for clustering which will turn on behavior like this but I'm not using
clustering. 

Here's a log sample:

Jan 20, 2010 4:02:41 PM org.apache.jk.common.ChannelSocket init
INFO: Port busy 8009 java.net.BindException: Address already in use
Jan 20, 2010 4:02:41 PM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8010
Jan 20, 2010 4:02:41 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=1 time=0/118  config=null
Jan 20, 2010 4:02:41 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 2945 ms

The connector from server.xml is:
<Connector port="${ajp-port}" protocol="AJP/1.3"/>

And I define ajp-port on the cmd line. Also tried hard coding the port into
the file. I also tried setting the bind ip address in the server.xml, no luck.

Is this expected behavior? I don't see it mentioned in the docs and google
wasn't helpful. If this is expected then is there a way to shut it off?

This is tomcat 6.0.20 on a fedora 3 server. Java is 1.6.0_14.

Thanks everyone,
Paul

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to