Question

I setup a tomcat 6 server in Eclipse pointing to a local tomcat folder:

C:\Program Files (x86)\Apache\Tomcat

I setup a debug configuration to point to that tomcat server with the following settings:

Program arguments:

start

VM arguments:

-Dcatalina.base="C:\Program Files (x86)\Apache\Tomcat" -Dcatalina.home="C:\Program Files (x86)\Apache\Tomcat"

Classpath Bootstrap Entries:

JRE System Library [jdk]

Classpath User Entries:

bootstrap - C:\Program Files (x86)\Apache\Tomcat\bin\ tools.jar - C:\Program Files (x86)\Java\jdk\lib\

When attempting to start the debug configuration (and subsequently Tomcat), I instantly get this error in the Console:

java.lang.NoClassDefFoundError: Files
Caused by: java.lang.ClassNotFoundException: Files
       at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
       at java.security.AccessController.doPrivileged(Native Method)
       at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
       at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

And this error as a Windows Popup:

Java Virtual Machine Launcher - Could not find the main class Files. Program will now exit.

I think somewhere the JVM is trying to parse a "Program Files" related path, failing on the space, and thinks that "Files" is a parameter. But I don't even know where to look to find whatever path it's referencing! Is there an argument I can pass that will be verbose about what it's doing?

Était-ce utile?

La solution

Install Tomcat into a directory that does not have spaces in its full path.

Such as C:\Apache\Tomcat

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top