Uploaded image for project: 'JBoss Enterprise Application Platform 4 and 5'
  1. JBoss Enterprise Application Platform 4 and 5
  2. JBPAPP-2442

Server does not start if PATH contains directories with spaces

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • EAP 5.0.0.CR3
    • EAP 5.0.0.BETA
    • System
    • None
    • Windows 2003, Service Pack 2, x86_64, x86

    • Workaround Exists
    • Hide

      This issue occurs mainly on windows machines. The solution is not using spaces in directory names which are used in environment variables (especially in PATH)

      Show
      This issue occurs mainly on windows machines. The solution is not using spaces in directory names which are used in environment variables (especially in PATH)

      I installed EAP a tried to run it by clicking a desktop icon. I started the server but then it ends up with this error.

      Exception in thread "main" java.lang.NoClassDefFoundError: Files\Java\jdk1/6/0_1
      1\bin;C:\testing\apache-ant-1/7/0\bin;C:\WINDOWS\MsNfs\;C:\WINDOWS\SUA\common\;C
      :\WINDOWS\SUA\usr\lib\;C:\Program
      Caused by: java.lang.ClassNotFoundException: Files\Java\jdk1.6.0_11\bin;C:\testi
      ng\apache-ant-1.7.0\bin;C:\WINDOWS\MsNfs\;C:\WINDOWS\SUA\common\;C:\WINDOWS\SUA\
      usr\lib\;C:\Program
      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:307)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
      Could not find the main class: Files\Java\jdk1.6.0_11\bin;C:\testing\apache-ant-
      1.7.0\bin;C:\WINDOWS\MsNfs\;C:\WINDOWS\SUA\common\;C:\WINDOWS\SUA\usr\lib\;C:\Pr
      ogram. Program will exit.
      Press any key to continue . . .

      Problem is probably in script, which starts server (run.bat). This script probably can not process correctly PATH variable, when this variable contains directories with spaces. When Java is installed in directory containing space (Program Files) and this directory path is on PATH, the server ends up with error. But this error may be generated by any directory with spaces in name when such directory is added to PATH variable.

              tajinder Patrick Macdonald
              bbelovic_jira Boris Belovic (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 5 hours
                  5h