Date: Tue, 30 May 2006 10:18:24 +0100 From: Richard Cooper <ric@jonnycalcutta.com> To: freebsd-java@freebsd.org Subject: Still having the same Tomcat problem Message-ID: <447C0DE0.3040104@jonnycalcutta.com>
next in thread | raw e-mail | index | archive | help
Hi, I've posted a couple of times about a java.net.BindException on port 8005. I'm running 6.1-STABLE. I've added tomcat55_java_opts="-Djava.net.preferIPv4Stack=true" into rc.conf. I've rebuilt the kernel without INET6 support and I've tried all the helpful suggestion posted (even tried putting export JAVA_OPTIONS="-Djava.net.preferIPv4Stack=true" in the tomcat55 file in /usr/local/etc/rc.d). I still get the same problem with binding to port 8005. I'm going to post the full stdout.log message in the hope that it might help someone spot what I am doing wrong. May 30, 2006 9:59:24 AM org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Portable Runtime which allows optimal performance in production environments was not found on the java.library.path: /usr/local/diablo-jdk1.5.0/jre/lib/i386/server:/usr/local/diablo-jdk1.5.0/jre/lib/i386:/usr/local/diablo-jdk1.5.0/jre/../lib/i386:/usr/lib:/usr/local/lib May 30, 2006 9:59:24 AM org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8180 May 30, 2006 9:59:24 AM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1093 ms May 30, 2006 9:59:25 AM org.apache.catalina.core.StandardService start INFO: Starting service Catalina May 30, 2006 9:59:25 AM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.5.12 May 30, 2006 9:59:25 AM org.apache.catalina.core.StandardHost start INFO: XML validation disabled May 30, 2006 9:59:26 AM org.apache.catalina.core.ApplicationContext log INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]] May 30, 2006 9:59:26 AM org.apache.catalina.core.ApplicationContext log INFO: ContextListener: contextInitialized() May 30, 2006 9:59:26 AM org.apache.catalina.core.ApplicationContext log INFO: SessionListener: contextInitialized() May 30, 2006 9:59:26 AM org.apache.catalina.core.ApplicationContext log INFO: ContextListener: contextInitialized() May 30, 2006 9:59:26 AM org.apache.catalina.core.ApplicationContext log INFO: SessionListener: contextInitialized() May 30, 2006 9:59:27 AM org.apache.coyote.http11.Http11BaseProtocol start INFO: Starting Coyote HTTP/1.1 on http-8180 May 30, 2006 9:59:27 AM org.apache.jk.common.ChannelSocket init INFO: JK: ajp13 listening on /0.0.0.0:8009 May 30, 2006 9:59:27 AM org.apache.jk.server.JkMain start INFO: Jk running ID=0 time=0/48 config=null May 30, 2006 9:59:27 AM org.apache.catalina.storeconfig.StoreLoader load INFO: Find registry server-registry.xml at classpath resource May 30, 2006 9:59:27 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 2710 ms May 30, 2006 9:59:27 AM org.apache.catalina.core.StandardServer await SEVERE: StandardServer.await: create[8005]: java.net.BindException: Can't assign requested address at java.net.PlainSocketImpl.socketBind(Native Method) at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359) at java.net.ServerSocket.bind(ServerSocket.java:319) at java.net.ServerSocket.<init>(ServerSocket.java:185) at org.apache.catalina.core.StandardServer.await(StandardServer.java:343) at org.apache.catalina.startup.Catalina.await(Catalina.java:600) at org.apache.catalina.startup.Catalina.start(Catalina.java:560) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) Everything seems to start until it can't bind the shutdown port, when it fails. I'm very new to this Java/Tomcat stuff though so its hard to be sure. I'm also running Apache 2.2 and mod_jk, if that could make any difference. Obviously though, mod_jk can't bind to anything since Tomcat doesn't start. I'm going to be setting this up on a production server soon for some developers, but obviously not if it doesn't work. Also would I be better just going back to the old Linux port? We're anticipating a heavy load so obviously native binaries would be better. Thanks for any help on this - as I said I'm a newbie to Java/Tomcat so please don't feel that any answer is too obvious ;). Cheers Ric
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?447C0DE0.3040104>