The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,969 other subscribers

Archive for the ‘Remote Debugging’ Category

x64 debugging on Windows: usually not directly by the IDE, but trough a debug helper process (msvsmon / PAServer / dbkw64_16_0)

Posted by jpluimers on 2012/12/07

While developing x64 applications, most Windows development tools are actually running in x86 mode, and use an intermediate x64 layer to debug the x64 process even for local debugging.

For Visual Studio 2008 and up, this is msvsmon.exe (for Delphi XE2 and up it is PAServer.exe for remote debugging or [WayBack] dbkw64_16_0.exe for local debugging, other tools use a similar mechanism).

The fun thing with Visual Studio is that when msvsmon.exe fails to load locally, you get a misleading error message:

[Microsoft Visual Studio]
Error while trying to run project: Unable to start debugging.
The Microsoft Visual Studio Remote Debugging Monitor has been closed on the remote machine.

I found two workarounds myself :

  1. Kill msvsmon.exe if it is running but Visual Studio cannot talk to it
  2. Restart Visual Studio if it cannot start msvsmon.exe

I learned the why from Steve Steiner: he posted the StackOverflow answer explaining msvsmon.exe is also used for local x64 debugging.

Delphi XE2 and up sometimes have a similar cryptic message (I forgot to jolt it down, next time I come across it, I will edit this blog post) and usually killing PAServer.exe or dbkw63*.exe or restarting the IDE solves it.



Posted in .NET, Debugging, Delphi, Delphi x64, Development, QC, Remote Debugging, Software Development, Visual Studio 11, Visual Studio 2008, Visual Studio 2010, Visual Studio and tools | Leave a Comment »

Visual Studio 2010: you should run the Remote Debugging Monitor from a local drive to avoid 0x8007000E E_OUTOFMEMORY

Posted by jpluimers on 2011/04/14

Setting up remote debugging is always a precarious thing, no matter what kind of development platform: the online documentation tells you the standard steps, but usually they don’t suffice.

This case is Visual Studio 2010 remote debugging, where the development environment is on a workstation running Windows 7, and the debug target is on Windows Server 2008 R2.
Both are x64 versions.

There is a remote desktop connection to the server, and the server can see the workstation files on the \\TSCLIENT\C share.

This is the error when running msvsmon.exe from \\tsclient\C\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Remote Debugger\x64:

[Visual Studio Remote Debugging Monitor]
The following error occurred: Not enough storage is available to complete this operation.

View Msvsmon's help for more information.

(Funny BTW that the x64 Remote Debugging Monitor is in fact in an x86 path).

The solution is simple: copy the x64 directory local, then start it from there.

The reason in that the user credentials on the server don’t have enough rights on the \\TSCLIENT\C directory tree, so Windows barfs on it.

This pointed me into the right direction when I started Process Monitor from the same \\TSCLIENT\C share: Read the rest of this entry »

Posted in .NET, Debugging, Development, Remote Debugging, Software Development, Visual Studio 2010, Visual Studio and tools | Leave a Comment »

%d bloggers like this: