I'm not sure the topic is ready to be nailed shut just yet... The problem is due to the way Tomcat converts pathnames to URLs when it uses URLClassLoader. Tomcat calls the method File.toURL and that fails when there's a "#" in the pathname. But the Javadoc for File.toURL suggests a workaround: Convert the pathname to a URI first, then to a URL.
I tried that (in ClassLoaderFactory) and it seem to fix the classloader problem. Tomcat starts up fine - but it can't compile any JSPs. So there are other components of Tomcat that have similar problems. So, my advice is to see how hard it would be for you to get the #s out of your pathnames. That may be easier than fixing Tomcat. -- Len On 8/9/07, Markus Schiegl <[EMAIL PROTECTED]> wrote: > Hi all, > > just to close the topic on this mailing list: > > As jetty suffers from exactly the same problem i'm rather confident this > is not a tomcat problem but part of the java classloader and its > implementation. Next - and last - stop for confirmation: Sun :-) > > kind regards, > Markus > > Alexey Solofnenko wrote: > > Try running "bash -x catalina.sh run" to see if Java is started > > correctly. If it is not, try running the same command from a normal > > directory, and run the same command yourself without using scripts > > provided with Tomcat. > > > > - Alexey. > > > > Markus Schiegl wrote: > >> Hi, > >> > >> you're right about # as a special char for different programming > >> languages. but nevertheless the # sign is a valid character for > >> directory and file names (in contrast to * or / for example) for unix > >> and windows. If it's wise to use it is another question but sometimes > >> it's just beyond your control. > >> > >> The same problem (# in directory name) and error message > >> (ClassNotFoundException) happens with Windows XP. Confirms my suspicion > >> this beeing a Java and/or Tomcat issue. > >> > >> kind regards, > >> Markus > >> > >> Propes, Barry L wrote: > >> > >>> isn't that likely because in some languages like PHP, Python and Perl > >>> the # is to comment out a line, and it will invariably break the code? > >>> Because I thought some on this list were integrating Tomcat with > >>> those languages. > >>> > >>> -----Original Message----- > >>> From: Hassan Schroeder [mailto:[EMAIL PROTECTED] > >>> Sent: Thursday, August 09, 2007 7:58 AM > >>> To: Tomcat Users List > >>> Subject: Re: Tomcat and path with pound sign (#) -> > >>> ClassNotFoundException > >>> > >>> > >>> On 8/8/07, Markus Schiegl <[EMAIL PROTECTED]> wrote: > >>> > >>> > >>>> Has anybody been able to start a tomcat server from such a directory? > >>>> > >>> I copied a working installation from /usr/local/apache-tomcat-6.0.13 > >>> to /usr/local/apache-tomcat#6.0.13, set CATALINA_HOME and got this: > >>> > >>> > >>>> ./bin/catalina.sh run > >>>> > >>> Using CATALINA_BASE: /usr/local/apache-tomcat#6.0.13 > >>> Using CATALINA_HOME: /usr/local/apache-tomcat#6.0.13 > >>> Using CATALINA_TMPDIR: /usr/local/apache-tomcat#6.0.13/temp > >>> Using JRE_HOME: /usr/local/jdk1.6.0_02/jre > >>> java.lang.ClassNotFoundException: org.apache.catalina.startup.Catalina > >>> at java.net.URLClassLoader$1.run(URLClassLoader.java:200) > >>> at java.security.AccessController.doPrivileged(Native Method) > >>> at java.net.URLClassLoader.findClass(URLClassLoader.java:188) > >>> at java.lang.ClassLoader.loadClass(ClassLoader.java:306) > >>> at java.lang.ClassLoader.loadClass(ClassLoader.java:251) > >>> at > >>> org.apache.catalina.startup.Bootstrap.init(Bootstrap.java:215) > >>> at > >>> org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:390) > >>> > >>> So it seems a genuine limitation... > >>> > >>> HTH, > >>> > >> > >> --------------------------------------------------------------------- > >> To start a new topic, e-mail: users@tomcat.apache.org > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > > > > --------------------------------------------------------------------- > To start a new topic, e-mail: users@tomcat.apache.org > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]