Attaching the Debugger to a Running Process

  1. When launching the process you want to attach the debugger to, type -Xdebug in the Java virtual machine's parameter list (after -classic when running on Hotspot) and note the agent password.

  2. From the main window, choose Debug Attach to VM.

  3. In the Attach to VM dialog box, type the IP address and password of the host machine.

  4. Click OK.

    The debugger connects to the running virtual machine, and you will see threads as if you were debugging locally. If you set a breakpoint in the source code, the Source Editor opens with the breakpoint line highlighted in red.
See also
The Debugging Environment

Legal Notices