tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cocula Remi" <rcoc...@sopragroup.com>
Subject Problem with Tomcat 4.1 in security mode (NT service)
Date Mon, 10 Jan 2005 16:29:27 GMT
Hi all,

I run a Tomcat 4.1 on Windows 2000.
I have installed it as an NT service and it works fine.
here is the script used to install the service :
------------------------------
set SERVICENAME=Apache Tomcat
set JAVACLASSPATH=%CLASSPATH%
set JAVACLASSPATH=%JAVACLASSPATH%;"%CATALINA_HOME%\bin\bootstrap.jar"
set JAVACLASSPATH=%JAVACLASSPATH%;"%CATALINA_HOME%\common\lib\servlet.jar"
set JAVACLASSPATH=%JAVACLASSPATH%;"%JAVA_HOME%\lib\tools.jar"

tomcat.exe -install "%SERVICENAME%" "%JAVA_HOME%\jre\bin\server\jvm.dll" -Djava.class.path=%JAVACLASSPATH%
-Dcatalina.home="%CATALINA_HOME%" -Xrs -start org.apache.catalina.startup.Bootstrap -params
start -stop org.apache.catalina.startup.Bootstrap -params stop -out "%CATALINA_HOME%\logs\stdout.log"
-err "%CATALINA_HOME%\logs\stderr.log"
-------------------------------

Now I need to run tomcat with the -security option : 
If I run it with %CATALINA_HOME%\bin\catalina start -security everything's fine.

Then I install it as a service by modifing the previous script as follows : 
---------------------------------------
set SERVICENAME=Apache Tomcat
set JAVACLASSPATH=%CLASSPATH%
set JAVACLASSPATH=%JAVACLASSPATH%;"%CATALINA_HOME%\bin\bootstrap.jar"
set JAVACLASSPATH=%JAVACLASSPATH%;"%CATALINA_HOME%\common\lib\servlet.jar"
set JAVACLASSPATH=%JAVACLASSPATH%;"%JAVA_HOME%\lib\tools.jar"

tomcat.exe -install "%SERVICENAME%" "%JAVA_HOME%\jre\bin\server\jvm.dll" -Djava.class.path=%JAVACLASSPATH%
-Dcatalina.home="%CATALINA_HOME%" -Djava.security.manager -Djava.security.policy=%CATALINA_HOME%\conf\catalina.policy
-Xrs -start org.apache.catalina.startup.Bootstrap -params start -stop org.apache.catalina.startup.Bootstrap
-params stop -out "%CATALINA_HOME%\logs\stdout.log" -err "%CATALINA_HOME%\logs\stderr.log"
---------------------------------------


It works good until I get the following Exception .
--------------------------------
java.lang.NoClassDefFoundError: sun/io/CharToByteConverter at org.apache.xml.serialize.EncodingInfo.isPrintable(Unknown
Source) at org.apache.xml.serialize.XMLSerializer.printXMLChar(Unknown Source) at org.apache.xml.serialize.XMLSerializer.printEscaped(Unknown
Source) at org.apache.xml.serialize.XMLSerializer.serializeElement(Unknown Source) at org.apache.xml.serialize.BaseMarkupSerializer.serializeNode(Unknown
Source) at org.apache.xml.serialize.XMLSerializer.serializeElement(Unknown Source) at org.apache.xml.serialize.BaseMarkupSerializer.serializeNode(Unknown
Source) at org.apache.xml.serialize.XMLSerializer.serializeElement(Unknown Source) at org.apache.xml.serialize.BaseMarkupSerializer.serializeNode(Unknown
Source) at org.apache.xml.serialize.BaseMarkupSerializer.serializeNode(Unknown Source) at
org.apache.xml.serialize.BaseMarkupSerializer.serialize(Unknown Source) at altaix.intranet.objets.Arbre.Sauver(Arbre.java:168)
at altaix.intranet.transactions.AjouterInfo.Executer(AjouterInfo.java:38) at altaix.intranet.transactions.Transaction.Executer(Transaction.java:59)
at altaix.intranet.servlets.gc.doGet(gc.java:181) at altaix.intranet.servlets.gc.doPost(gc.java:196)

.......

I really don't understand what it means as the sun/io/CharToByteConverter class is part of
rt.jar. On the other hand I never get this error when Tomcat is not lauched as a service.



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message