RE: attach to process not started in debug mode?



Hi Les,

Based on my understanding, I assume your "debug mode" means the application
debug build. That is your application components is built in release
configuration.

Yes, you can use any debugger to attach a release build application as long
as you have enough priviledge/permissions on remote machine. Debugger will
use .Net/Win32 debugging service to attach the process, so it does not
matter if the target is debug or release build.

Normally, release build is not special comparing to debug build. It will
just perform optimize for the generated code. For example, if there is any
local variables can be eliminated, the release build will discard them in
generated assemblies. Below link talks about the C/C++ code difference
between debug and release build, however, the idea is the same for .Net
compiler:
"Debug versus Release build"
http://www.dotnetheaven.com/Uploadfile/mahesh/DebugaRelease05192005033225AM/
DebugaRelease.aspx

Finally, to debug 3rd party assembly, if the assembly is not obfruscated, I
would recommend you to download Reflector from the link below and use the
Reflector to examine the source code of it. Due to the strong metadata in
the .Net assembly, it is possible for Reflector tool to decompile the
assembly code for review.(A extreme example is .Net Framework assemblies,
which can be decompiled in Reflector for learning)
http://www.aisto.com/roeder/dotnet/

Hope this helps.

Best regards,
Jeffrey Tan
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


.



Relevant Pages

  • RE: Assembly reported as built without debug info - that is not true
    ... enabled or without debug information:..." ... successfully remote debug any other assembly which is not in the GAC? ... in the Modules window's loading assemblies' list, ... Microsoft Online Community Support ...
    (microsoft.public.dotnet.framework)
  • Re: attach to process not started in debug mode?
    ... Jeffrey - I've got a box at a remote ISP where I may need to debug the app from ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.framework)
  • Re: VS2005 conditional directive
    ... I still see "Debug" displayed. ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ... project analysis and dump analysis issues. ...
    (microsoft.public.vsnet.general)
  • RE: Step by Step skips large chunks of code
    ... The interesting thing is that it still skips code during debug but not ... has been correctly complied into assembly code. ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.vsnet.debugging)
  • cpufreq oddness on 2.6.16-rc1-mm4
    ... Some debug info, dmesg, and config are below. ... # Console display driver support ... # USB Device Class drivers ...
    (Linux-Kernel)