tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rainer Jung <rainer.j...@kippdata.de>
Subject Re: Sudden and unexpected exception at Tomcat startup
Date Wed, 31 Dec 2008 16:33:32 GMT
On 28.12.2008 14:01, André Warnier wrote:
> Hi.
>
> Does someone have an idea of what is going as per the logfile
> catalina.out below ?
> What is this IOException all about ?
>
> This is a Tomcat 5.0.x under Suse Enterprise Linux 10.1, which had been
> working fine until now and suddenly logs this at startup.
> This Tomcat runs under an IBM JVM 1.5.
>
> Tomcat is started, as per the listening ports and the "ps" display I can
> see, but apparently the access to Tomcat (through Apache and mod_jk)
> does not work anymore (tells me : The server is temporarily unable to
> service your request due to maintenance downtime or capacity problems.
> Please try again later. )
>
>
> Additional info :
> - the directory /srv/www/tomcat5/base/conf/ is writeable by the user
> "tomcat" under which Tomcat is started.
> - To my knowledge, the server.xml has not been changed since the
> previous succesful restart 2 days ago, and neither has tomcat-users.xml
>
>
> server.xml (excerpts) :
> ...
> <!-- Editable user database that can also be used by
> UserDatabaseRealm to authenticate users -->
> <Resource name="UserDatabase" auth="Container"
> type="org.apache.catalina.UserDatabase"
> description="User database that can be updated and saved">
> </Resource>
> <ResourceParams name="UserDatabase">
> <parameter>
> <name>factory</name>
> <value>org.apache.catalina.users.MemoryUserDatabaseFactory</value>
> </parameter>
> <parameter>
> <name>pathname</name>
> <value>conf/tomcat-users.xml</value>
> </parameter>
> </ResourceParams>
> ...
> (further under <Engine> and <Host> :)
>
> <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
> debug="0" resourceName="UserDatabase"/>
> ...
>
>
>
> catalina.out :
>
> 2008-12-28 13:21:58,543 [main] INFO
> org.apache.catalina.core.StandardService - Starting service Catalina
> 2008-12-28 13:21:58,545 [main] INFO
> org.apache.catalina.core.StandardEngine - Starting Servlet Engine:
> Apache Tomcat/5.0
> 2008-12-28 13:21:58,548 [main] WARN org.apache.naming.NamingContext -
> Unexpected exception resolving reference
> java.io.IOException: IOException writing to
> /srv/www/tomcat5/base/conf/tomcat-users.xml.new
> at
> org.apache.catalina.users.MemoryUserDatabase.save(MemoryUserDatabase.java:495)

Starting with TC 5.5.12 you can add

<parameter>
<name>readonly</name>
<value>true</value>
</parameter>

to prevent this behaviour (e.g. during startup tomcat-users.xml gets 
written out in a normalized way with an additional suffix ".new", and 
then the new file gets renamed to the old one). The parameter is not 
available for any 5.0 version.

Regards,

Rainer

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


Mime
View raw message