tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Hanik - Dev Lists <>
Subject Re: 5.5.28 issue when multiple services with engines named the same
Date Mon, 03 Aug 2009 01:10:46 GMT
Hi Steven, I think the engine name unique per server has been there for 
a very long time. for example the directory
conf/Engine name/Host name
and not Service name, so this would make the engine unique


On 08/02/2009 12:16 PM, Steven Mahurin wrote:
> I am using tomcat 5.5.27 to run a set of simple set of applications.  I am looking at
5.5.28 to address a number of security vulnerabilties.  When I tried the 5.5.28, we ran into
an issue when two services were defined in server.xml, if the same engine name was used for
both but different host names/settings, the second engine would not start up. This worked
in 5.5.27, and the documentation indicates that the engine name must be unique-per-service,
not per server.  Is this a known issue?
> I ended up just renaming the engine defined in the second service and it works fine.
 However, this may cause other people issue when going to 5.5.28 from previous releases, and
it seems to differ from the configuration reference.
> Note that I verified that this issue is present using the 5.5.28 build that Filip had
as a release candidate on 7/24:
> You should be able to reproduce this by adding a service definition similar to the following
to the end of the default server.xml file (and creating a webapps-testonly folder in the tomcat
> <Service name="testservice">
>      <Engine name="Catalina" defaultHost="testpsuedohostname">
>        <Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase"
>        <Host name="testpsuedohostname" appBase="webapps-testonly" />
>      </Engine>
>      <Connector port="8010" enableLookups="false" protocol="AJP/1.3" address=""
>    </Service>
> In 5.5.27, both defined services startup normally.  In 5.5.28, the following trace is
generated when the above testservice starts up:
> INFO: Starting service testservice
> Aug 1, 2009 2:22:19 PM org.apache.catalina.core.StandardEngine start
> INFO: Starting Servlet Engine: Apache Tomcat/5.5.28
> Aug 1, 2009 2:22:19 PM org.apache.catalina.connector.MapperListener handleNotification
> WARNING: Error registering Host Catalina:type=Host,host=testpsuedohostname
> java.lang.NullPointerException
>      at org.apache.catalina.connector.MapperListener.registerHost(
>      at org.apache.catalina.connector.MapperListener.handleNotification(
>      at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor$ListenerWrapper.handleNotification(
>      at
> ...
> I haven't looked into the change that caused the difference, as the work around appeared
to be simple (just rename the engine).  I believe its a bug, but haven't reported it yet as
a bug because I wanted to make sure my understanding of the configuration documentation was
correct (engine name unique-per-service vs unique-per-server).
> Thanks,
> -steve
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message