Home > NetBeans, Uncategorized > NetBeans IDE – hang on startup

NetBeans IDE – hang on startup


If your NetBeans IDE crashes on shutdown, you might have trouble restarting it.  On a Mac this can manifest itself as a dock icon that bounces for a few minutes before being shown as Not Responding.  If you do a stack trace you might see things like the following:

StackTrace Remote Thread" prio=5 tid=0x00000001018fd800 nid=0x12774b000 waiting on condition [0x0000000000000000]
   java.lang.Thread.State: RUNNABLE

"AWT-EventQueue-1" prio=6 tid=0x00000001018fc800 nid=0x127599000 in Object.wait() [0x0000000127597000]
   java.lang.Thread.State: WAITING (on object monitor)
	at java.lang.Object.wait(Native Method)
	- waiting on <0x00000001077f4580> (a java.awt.EventQueue)
	at java.lang.Object.wait(Object.java:485)
	at java.awt.EventQueue.getNextEvent(EventQueue.java:515)
	- locked <0x00000001077f4580> (a java.awt.EventQueue)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:263)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:205)
	at java.awt.Dialog$1.run(Dialog.java:1045)
	at java.awt.Dialog$3.run(Dialog.java:1097)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.Dialog.show(Dialog.java:1095)
	at java.awt.Component.show(Component.java:1563)
	at java.awt.Component.setVisible(Component.java:1515)
	at java.awt.Window.setVisible(Window.java:841)
	at java.awt.Dialog.setVisible(Dialog.java:985)
	at com.sun.deploy.ui.DialogTemplate$10.run(DialogTemplate.java:1421)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:633)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

"Java2D Disposer" daemon prio=10 tid=0x000000010190c800 nid=0x1283d6000 in Object.wait() [0x00000001283d5000]
   java.lang.Thread.State: WAITING (on object monitor)
	at java.lang.Object.wait(Native Method)
	- waiting on <0x00000001073b3830> (a java.lang.ref.ReferenceQueue$Lock)
	at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:118)
	- locked <0x00000001073b3830> (a java.lang.ref.ReferenceQueue$Lock)
	at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:134)
	at sun.java2d.Disposer.run(Disposer.java:125)
	at java.lang.Thread.run(Thread.java:637)

"DestroyJavaVM" prio=5 tid=0x0000000102800800 nid=0x100501000 waiting on condition [0x0000000000000000]
   java.lang.Thread.State: RUNNABLE

"Java Web Start Main Thread" prio=5 tid=0x0000000102a30000 nid=0x12769c000 in Object.wait() [0x000000012769a000]
   java.lang.Thread.State: WAITING (on object monitor)
	at java.lang.Object.wait(Native Method)
	- waiting on <0x0000000107340f00> (a java.awt.EventQueue$1AWTInvocationLock)
	at java.lang.Object.wait(Object.java:485)
	at java.awt.EventQueue.invokeAndWait(EventQueue.java:1028)
	- locked <0x0000000107340f00> (a java.awt.EventQueue$1AWTInvocationLock)
	at javax.swing.SwingUtilities.invokeAndWait(SwingUtilities.java:1320)
	at com.sun.deploy.ui.DialogTemplate.setVisible(DialogTemplate.java:1429)
	at com.sun.deploy.ui.UIFactory$3.execute(UIFactory.java:242)
	at com.sun.javaws.ui.JavawsSysRun.delegate(JavawsSysRun.java:156)
	at com.sun.deploy.util.DeploySysRun.execute(DeploySysRun.java:24)
	at com.sun.deploy.util.DeploySysRun$1.run(DeploySysRun.java:46)
	at java.security.AccessController.doPrivileged(Native Method)
	at com.sun.deploy.util.DeploySysRun.executePrivileged(DeploySysRun.java:42)
	at com.sun.deploy.ui.UIFactory.showErrorDialog(UIFactory.java:229)
	at com.sun.javaws.ui.LaunchErrorDialog$2.execute(LaunchErrorDialog.java:250)
	at com.sun.javaws.ui.JavawsSysRun.delegate(JavawsSysRun.java:156)
	at com.sun.deploy.util.DeploySysRun.execute(DeploySysRun.java:24)
	at com.sun.deploy.util.DeploySysRun.execute(DeploySysRun.java:33)
	at com.sun.javaws.ui.LaunchErrorDialog.show(LaunchErrorDialog.java:266)
	at com.sun.javaws.Launcher.prepareToLaunch(Launcher.java:318)
	at com.sun.javaws.Launcher.prepareToLaunch(Launcher.java:186)
	at com.sun.javaws.Launcher.launch(Launcher.java:107)
	at com.sun.javaws.Main.launchApp(Main.java:405)
	at com.sun.javaws.Main.continueInSecureThread(Main.java:252)
	at com.sun.javaws.Main$1.run(Main.java:111)
	at java.lang.Thread.run(Thread.java:637)

"AWT-Shutdown" prio=5 tid=0x0000000102899800 nid=0x124983000 in Object.wait() [0x0000000124982000]
   java.lang.Thread.State: WAITING (on object monitor)
	at java.lang.Object.wait(Native Method)
	- waiting on <0x0000000107ae9ec8> (a java.lang.Object)
	at java.lang.Object.wait(Object.java:485)
	at sun.awt.AWTAutoShutdown.run(AWTAutoShutdown.java:259)
	- locked <0x0000000107ae9ec8> (a java.lang.Object)
	at java.lang.Thread.run(Thread.java:637)

In my specific case, this was due to the lock file that the program creates at startup not being deleted on shutdown.  You can manually remedy this by doing the following:

cd ~/.netbeans/6.8/
[511][nicholasdunn: 6.8]$ ls
build.properties	lock			update_tracking
config			modules			var
[512][nicholasdunn: 6.8]$ rm -f lock

This fixed the problem for me; hopefully if you find yourself in the same position this helps you.

Advertisements
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: