Community
Participate
Working Groups
20020910 com.sun.jdi.VMDisconnectedException: Got IOException from Virtual Machine at org.eclipse.jdi.internal.connect.PacketSendManager.sendPacket (PacketSendManager.java:63) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:163) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:185) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:215) at org.eclipse.jdi.internal.ReferenceTypeImpl.signature (ReferenceTypeImpl.java:809) at org.eclipse.jdi.internal.ReferenceTypeImpl.name(ReferenceTypeImpl.java:795) at org.eclipse.jdt.internal.debug.core.breakpoints.JavaBreakpoint.getTypeName (JavaBreakpoint.java:730) at org.eclipse.jdt.internal.debug.core.breakpoints.JavaBreakpoint.addToTarget (JavaBreakpoint.java:415) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.breakpointAdded (JDIDebugTarget.java:989) at org.eclipse.jdt.internal.debug.ui.JavaDebugOptionsManager.notifyTarget (JavaDebugOptionsManager.java:360) at org.eclipse.jdt.internal.debug.ui.JavaDebugOptionsManager.handleDebugEvents (JavaDebugOptionsManager.java:563) at org.eclipse.debug.core.DebugPlugin.fireDebugEventSet(DebugPlugin.java (Compiled Code)) at org.eclipse.jdt.internal.debug.core.model.JDIDebugElement.fireEvent (JDIDebugElement.java:133) at org.eclipse.jdt.internal.debug.core.model.JDIDebugElement.fireCreationEvent (JDIDebugElement.java:123) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.initialize (JDIDebugTarget.java:338) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.<init> (JDIDebugTarget.java:237) at org.eclipse.jdt.debug.core.JDIDebugModel$1.run(JDIDebugModel.java:134) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1361) at org.eclipse.jdt.debug.core.JDIDebugModel.newDebugTarget (JDIDebugModel.java:138) at org.eclipse.jdt.debug.core.JDIDebugModel.newDebugTarget (JDIDebugModel.java:98) at org.eclipse.jdt.internal.launching.StandardVMDebugger.run (StandardVMDebugger.java:145) at org.eclipse.pde.internal.ui.launcher.WorkbenchLaunchConfigurationDelegate.doLaun ch(WorkbenchLaunchConfigurationDelegate.java:279) at org.eclipse.pde.internal.ui.launcher.WorkbenchLaunchConfigurationDelegate.launch (WorkbenchLaunchConfigurationDelegate.java:87) at org.eclipse.debug.internal.core.LaunchConfiguration.launch (LaunchConfiguration.java:140) at org.eclipse.debug.internal.ui.actions.RelaunchActionDelegate.relaunch (RelaunchActionDelegate.java:56) at org.eclipse.debug.internal.ui.actions.RelaunchActionDelegate.relaunch (RelaunchActionDelegate.java:32) at org.eclipse.debug.internal.ui.actions.RelaunchHistoryLaunchAction$1.run (RelaunchHistoryLaunchAction.java:59) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:66) at org.eclipse.debug.internal.ui.actions.RelaunchHistoryLaunchAction.run (RelaunchHistoryLaunchAction.java:57) at org.eclipse.jface.action.Action.runWithEvent(Action.java:749) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:1239) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:775) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:462) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:247) at org.eclipse.core.launcher.Main.run(Main.java:703) at org.eclipse.core.launcher.Main.main(Main.java:539)
major - i have to go back to 2.0.1
restarting eclipse made it work again sorry for the severity mess
I can get a similar problem: Debug a self hosted workspace Put a breakpoint at line 87 of BreakpointsViewEventHandler Debug a program in the target, that will cause a breakpoint to be installed. The breakpoint in the host is hit Hit resume, the breakpoint is hit again in the host In the self-host target, terminate the program Hit resume in the host (takes a couple of times) and you will stop at the VMDisconnectedException (if stopping at uncaught exceptions) Terminate and Remove in the self-host target to cleanup the zombie launch. Any further attempts to debug a program in the self-host target fail with the IOException-->VMDisconnectedException. Like Adam, restarting the self-host target fixes the problem.
Turns out this was a problem with breakpoints not being removed from a target that has shutdown unexpectedly. A breakpoint would hold onto a ReferenceType (in fInstalledType). In #addToTarget(JDITarget) one of the first things we do is call #getTypeName(). This would blow up with a VMDisconnectedException as we were asking the old ReferenceType. So this is the reason for all future launches failing. Now the reason the breakpoints were not removed from the target. The EventDispatcher attempts to resume the event set. This can fail with a VMDisconnectedException. This caused all event dispatching to fail...including the pending notification that the VM had disconnected-->the target is not notified and the breakpoints are not removed.
Fixed in EventDispatcher.
Verified explanation and code fix. Was not able to reproduce problem.
I'm still getting this problem in the latest code: !ENTRY org.eclipse.ui 4 0 Sep 18, 2002 09:57:29.680 !MESSAGE Got IOException from Virtual Machine !STACK 0 com.sun.jdi.VMDisconnectedException: Got IOException from Virtual Machine at org.eclipse.jdi.internal.connect.PacketReceiveManager.getReply (PacketReceiveManager.java:123) at org.eclipse.jdi.internal.connect.PacketReceiveManager.getReply (PacketReceiveManager.java:137) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:167) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:185) at org.eclipse.jdi.internal.MirrorImpl.requestVM(MirrorImpl.java:215) at org.eclipse.jdi.internal.ReferenceTypeImpl.signature (ReferenceTypeImpl.java:809) at org.eclipse.jdi.internal.ReferenceTypeImpl.name (ReferenceTypeImpl.java(Compiled Code)) at org.eclipse.jdt.internal.debug.core.breakpoints.JavaBreakpoint.getTypeName (JavaBreakpoint.java:807) at org.eclipse.jdt.internal.debug.core.breakpoints.JavaBreakpoint.addToTarget (JavaBreakpoint.java:452) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.breakpointAdded (JDIDebugTarget.java:999) at org.eclipse.jdt.internal.debug.ui.JavaDebugOptionsManager.notifyTarget (JavaDebugOptionsManager.java:360) at org.eclipse.jdt.internal.debug.ui.JavaDebugOptionsManager.handleDebugEvents (JavaDebugOptionsManager.java:563) at org.eclipse.debug.core.DebugPlugin.fireDebugEventSet(DebugPlugin.java (Compiled Code)) at org.eclipse.jdt.internal.debug.core.model.JDIDebugElement.fireEvent (JDIDebugElement.java:133) at org.eclipse.jdt.internal.debug.core.model.JDIDebugElement.fireCreationEvent (JDIDebugElement.java:123) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.initialize (JDIDebugTarget.java:338) at org.eclipse.jdt.internal.debug.core.model.JDIDebugTarget.<init> (JDIDebugTarget.java:237) at org.eclipse.jdt.debug.core.JDIDebugModel$1.run (JDIDebugModel.java:134) at org.eclipse.core.internal.resources.Workspace.run (Workspace.java:1378) at org.eclipse.jdt.debug.core.JDIDebugModel.newDebugTarget (JDIDebugModel.java:138) at org.eclipse.jdt.debug.core.JDIDebugModel.newDebugTarget (JDIDebugModel.java:98) at org.eclipse.jdt.internal.launching.StandardVMDebugger.run (StandardVMDebugger.java:145) at org.eclipse.jdt.internal.launching.JavaLocalApplicationLaunchConfigurationDelega te.launch(JavaLocalApplicationLaunchConfigurationDelegate.java:97) at org.eclipse.debug.internal.core.LaunchConfiguration.launch (LaunchConfiguration.java:140) at org.eclipse.debug.internal.ui.actions.RelaunchActionDelegate.relaunch (RelaunchActionDelegate.java:56) at org.eclipse.debug.internal.ui.actions.RelaunchLastAction$1.run (RelaunchLastAction.java:60) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:66) at org.eclipse.debug.internal.ui.actions.RelaunchLastAction.run (RelaunchLastAction.java:58) at org.eclipse.ui.internal.PluginAction.runWithEvent (PluginAction.java:210) at org.eclipse.ui.internal.WWinPluginAction.runWithEvent (WWinPluginAction.java:196) at org.eclipse.ui.internal.registry.AcceleratorScope$AcceleratorAction.run (AcceleratorScope.java:289) at org.eclipse.ui.internal.registry.AcceleratorScope.processKey (AcceleratorScope.java:249) at org.eclipse.ui.internal.KeyBindingMenu$3.handleEvent (KeyBindingMenu.java:90) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:1239) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:775) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:462) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:247) at org.eclipse.core.launcher.Main.run(Main.java:703) at org.eclipse.core.launcher.Main.main(Main.java:539)
I think the problem is that when multiple targets are run, the install count can be greater than 0, and we cache an installed type from a terminated VM.
Changed code to cache the type name, rather than the actual ReferenceType. This fixes the problem.
Fixed. Please verify, Darin S.
Verified code.
*** Bug 23641 has been marked as a duplicate of this bug. ***
*** Bug 23786 has been marked as a duplicate of this bug. ***