RE: Tomcat NT Service: Strange issue
The JAR file for the com.sun...Provider class is in a JAR file that is in the CLASSPATH environment variable, but not in your wrapper.properties file's wrapper.class_path variable. (When the service starts the new JVM it ignores the System's CLASSPATH environment variable) Randy -Original Message- From: Nibler Jeff R. (PDX1JRN) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 06, 2001 1:19 PM To: [EMAIL PROTECTED] Subject: Tomcat NT Service: Strange issue Ok, I've been banging my head against the keyboard for a day and a half trying to figure this out. Here is the scenario: I have Tomcat 3.2 running as a service on an NT server with IIS. Until yesterday, I had an older Version of Tomcat running, then I upgraded it. Now, when I start the service, everything seems to work fine, but in one of my servlet's init method, I have the following code: System.getProperties().put(java.protocol.handler.pkgs,com.s un.net.ssl.int ernal.www.protocol); java.security.Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); When I try to hit that servlet in a browser, I get a java.lang.NoClassDefFoundError: com/sun/net/ssl/internal/ssl/Provider error. Now HERE is the strange part. If I stop the service, and launch Tomcat using the Startup.bat file, everything works just fine. The only thing I could see causing this problem would be some sort of classpath issue, but I have the correct TOMCAT_HOME environment variable, as well as the correct CLASSPATH and JAVA_HOME env variables. I also put the TOMCAT_HOME and JAVA_HOME in the wrapper.properties file, but still it gives me the NoClassDefFoundError when I run as a service, but not when I run it using the Startup.bat. Does ANYONE have any idea what could be causing this? Thanks in advance for any help with this!! -Jeff
RE: Tomcat NT Service: Strange issue
It never fails. You could wait days before sending a question to the list, but the second you do, you figure the problem out yourself. Well, I didn't figure it out exactly, but I did get it to work. I had to add each and every entry in my CLASSPATH environment variable to the wrapper.properties file. This made everything ok when running Tomcat as an NT service. I do still have a question though: Why doesn't Tomcat just use the existing CLASSPATH environment variable? Jeff -Original Message- From: Nibler Jeff R. (PDX1JRN) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 06, 2001 10:19 AM To: [EMAIL PROTECTED] Subject: Tomcat NT Service: Strange issue Ok, I've been banging my head against the keyboard for a day and a half trying to figure this out. Here is the scenario: I have Tomcat 3.2 running as a service on an NT server with IIS. Until yesterday, I had an older Version of Tomcat running, then I upgraded it. Now, when I start the service, everything seems to work fine, but in one of my servlet's init method, I have the following code: System.getProperties().put(java.protocol.handler.pkgs,com.sun.net.ssl.int ernal.www.protocol); java.security.Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); When I try to hit that servlet in a browser, I get a java.lang.NoClassDefFoundError: com/sun/net/ssl/internal/ssl/Provider error. Now HERE is the strange part. If I stop the service, and launch Tomcat using the Startup.bat file, everything works just fine. The only thing I could see causing this problem would be some sort of classpath issue, but I have the correct TOMCAT_HOME environment variable, as well as the correct CLASSPATH and JAVA_HOME env variables. I also put the TOMCAT_HOME and JAVA_HOME in the wrapper.properties file, but still it gives me the NoClassDefFoundError when I run as a service, but not when I run it using the Startup.bat. Does ANYONE have any idea what could be causing this? Thanks in advance for any help with this!! -Jeff
RE: Tomcat NT Service: Strange issue
Very strange. I wonder why it does that? I wish it would have been documented in the NT-IIS-Service-How-To. Thanks for your reply Randy! Jeff -Original Message- From: Randy Layman [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 06, 2001 10:20 AM To: [EMAIL PROTECTED] Subject: RE: Tomcat NT Service: Strange issue The JAR file for the com.sun...Provider class is in a JAR file that is in the CLASSPATH environment variable, but not in your wrapper.properties file's wrapper.class_path variable. (When the service starts the new JVM it ignores the System's CLASSPATH environment variable) Randy -Original Message- From: Nibler Jeff R. (PDX1JRN) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 06, 2001 1:19 PM To: [EMAIL PROTECTED] Subject: Tomcat NT Service: Strange issue Ok, I've been banging my head against the keyboard for a day and a half trying to figure this out. Here is the scenario: I have Tomcat 3.2 running as a service on an NT server with IIS. Until yesterday, I had an older Version of Tomcat running, then I upgraded it. Now, when I start the service, everything seems to work fine, but in one of my servlet's init method, I have the following code: System.getProperties().put(java.protocol.handler.pkgs,com.s un.net.ssl.int ernal.www.protocol); java.security.Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); When I try to hit that servlet in a browser, I get a java.lang.NoClassDefFoundError: com/sun/net/ssl/internal/ssl/Provider error. Now HERE is the strange part. If I stop the service, and launch Tomcat using the Startup.bat file, everything works just fine. The only thing I could see causing this problem would be some sort of classpath issue, but I have the correct TOMCAT_HOME environment variable, as well as the correct CLASSPATH and JAVA_HOME env variables. I also put the TOMCAT_HOME and JAVA_HOME in the wrapper.properties file, but still it gives me the NoClassDefFoundError when I run as a service, but not when I run it using the Startup.bat. Does ANYONE have any idea what could be causing this? Thanks in advance for any help with this!! -Jeff