This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
There are two spaces <space><space> in path used for installation and such path caused troubles. Solaris output showed below, Linux shows same exception without stacktrace. Run from file explorer has same result so this is not console problem. Standalone non bundle installer affected as well. On Windows platform it works fine. bash-3.2$ ~/netbeans\ n\ \ 6.7.1/bin/netbeans Exception in thread "main" java.lang.NoClassDefFoundError: org/netbeans/Main Caused by: java.lang.ClassNotFoundException: org.netbeans.Main 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:303) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:248) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:316) Could not find the main class: org.netbeans.Main. Program will exit.
What's the reason?
Workaround (install into different path) exists => P2
This is NOT workaround. Workaround is answer for "how to install this path".
http://wiki.netbeans.org/BugPriorityGuidelines
Thanks for link. P1 crash or deadlock Reproducible, unavoidable crash It reproducible and unavoidable for sure. "Do not use <something>" is not workaround at all.
Use different path is clearly valid workaround for the problem. Moreover, usage of two subsequent spaces in path is obviously corner-case. Probably more P3 than P2.
core-main #cc6eca4799d4
Fix does not seem to work. While 6.7 died immediately: Exception in thread "main" java.lang.NoClassDefFoundError: org/netbeans/Main Caused by: java.lang.ClassNotFoundException: org.netbeans.Main 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:303) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:248) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:316) Could not find the main class: org.netbeans.Main. Program will exit. 6.8 with the attempted fix just dies soon after: ------------------------------------------------------------------------------- >Log Session: Tuesday, November 17, 2009 7:21:15 PM EST >System Info: Product Version = NetBeans Platform Dev (Build 091113-2affbb438743) Operating System = Linux version 2.6.31-14-generic running on i386 Java; VM; Vendor = 1.6.0_17; Java HotSpot(TM) Client VM 14.3-b01; Sun Microsystems Inc. Runtime = Java(TM) SE Runtime Environment 1.6.0_17-b04 Java Home = /space/jdk1.6.0_17/jre System Locale; Encoding = en_US (nb); UTF-8 Home Directory = /home/jglick Current Directory = /tmp User Directory = /tmp/testud09 Installation = /tmp/double space in path/platform11 Boot & Ext. Classpath = /space/jdk1.6.0_17/jre/lib/resources.jar:/space/jdk1.6.0_17/jre/lib/rt.jar:/space/jdk1.6.0_17/jre/lib/sunrsasign.jar:/space/jdk1.6.0_17/jre/lib/jsse.jar:/space/jdk1.6.0_17/jre/lib/jce.jar:/space/jdk1.6.0_17/jre/lib/charsets.jar:/space/jdk1.6.0_17/jre/classes:/space/jdk1.6.0_17/jre/lib/ext/sunjce_provider.jar:/space/jdk1.6.0_17/jre/lib/ext/sunpkcs11.jar:/space/jdk1.6.0_17/jre/lib/ext/dnsns.jar:/space/jdk1.6.0_17/jre/lib/ext/localedata.jar Application Classpath = /tmp/double space in path/platform11/lib/boot.jar:/tmp/double space in path/platform11/lib/org-openide-modules.jar:/tmp/double space in path/platform11/lib/org-openide-util.jar:/space/jdk/lib/dt.jar:/space/jdk/lib/tools.jar Startup Classpath = /tmp/double space in path/platform11/core/org-openide-filesystems.jar:/tmp/double space in path/platform11/core/core.jar ------------------------------------------------------------------------------- WARNING [org.netbeans.core.startup.Main] java.lang.NoClassDefFoundError: org.netbeans.license.AcceptLicense starting from org.netbeans.MainImpl$BootClassLoader@ec16a4 with possible defining loaders null and declared parents [] at org.netbeans.core.startup.Main.getKlass(Main.java:364) at org.netbeans.core.startup.Main.access$000(Main.java:71) at org.netbeans.core.startup.Main$1LicenseHandler.run(Main.java:475) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199) at java.awt.EventQueue.dispatchEvent(EventQueue.java:597) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161) [catch] at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Created attachment 91215 [details] Suggested continuation of fix With this added patch, things seem to work. Not sure that other things are not broken.
Jesse, thanks for the patch. Tomasi, take a look at that. However, we are in high-resistance now, so I would agree with integration to 6.8 only if we are sure the fix is 100% safe and that the case of 2 spaces in installation path is really a P1 for some reason. Setting TM to Next for now. Can installer team comment on priority of this issue?
IMHO no need to push this during HR.
I would suggest that the impact of the bug be carefully evaluated, since we cannot later (6.8.1?) push an update to launchers if we change our mind. (Perhaps AU can now update platform/lib/nbexec, but I presume it cannot update bin/netbeans since that is not part of a cluster.)
I`d say that is the corner case though valid. I have feeling that have 2 spaces in path will be used by mistake rather than intentionally. Moreover, Linux/Solaris users typically does not uses spaces at all, or, at least, not as often as on Windows. And, yes, Jesse is absolutely correct, bin/netbeans can`t be updated by AU at the moment. But due to rare occurrence of the bug I don`t think it is absolutely required to be fixed in 6.8.
Jesse's patch integrated in core-main #b7bd22f6ea9c
Integrated into 'main-golden', will be available in build *200911241400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/b7bd22f6ea9c User: Tomas Holy <t_h@netbeans.org> Log: #175260: Failed to start IDE installed into path with two spaces