Profiler hangs on "waiting for profiled process to start"

Use this forum for questions on how to use .NET Memory Profiler and how to analyse memory usage.
Post Reply
cbardon
Posts: 1
Joined: Mon Dec 17, 2012 2:48 pm

Profiler hangs on "waiting for profiled process to start"

Post by cbardon » Mon Dec 17, 2012 2:57 pm

I'm trying to profile a self-hosted WCF service, and I'm running into an issue where I can't launch the process directly, nor can I attach to it while it is running. If I try to launch the host from VS 2010, the app launches, but the profiler hangs on this progress dialog forever. If I launch directly using the tool, I get an error saying "failed to create process" (even though I can run it directly). If I try to launch manually, and then attach, I get an error saying that a profiler is already attached to this process. Any idea why I can't run the profiler against this service? Is there somewhere else I can look for logging information? Some details:

Windows 8 x64
VS 2010
.net 4.0 self-hosted WCF service
Memory profiler 4.5.192.0

Andreas Suurkuusk
Posts: 1029
Joined: Wed Mar 02, 2005 7:53 pm

Re: Profiler hangs on "waiting for profiled process to start

Post by Andreas Suurkuusk » Tue Dec 18, 2012 9:20 pm

How do you launch the WCF service? If you are hosting the service in your own executable, you should just be able to profile the process using the "Start memory profiler" command (or the "Profile application" command).

Is it an ordinary .NET executable you are trying to launch? In that case you should be able to profile your service. However, the fact that you fail to attach to the process and get a message saying that a profiler is already attached to the process, indicates that there might be a conflict with another profiler. Only a single profiler can be connected to a process at any one time. Is there a possibility that another profiler is running on the system (or another tool that is using the .NET profiling API)?

Note that a WCF library project using WcfSvcHost cannot currently be launched using the "Start memory profiler" command in Visual Studio. Instead you have to manually launch WcfSvcHost using the "Profile application" command. Select WcfSvcHost.exe as the executable and provide the command line "/service:<pathToServiceDll> /config:<pathToServiceConfig>".
Best regards,

Andreas Suurkuusk
SciTech Software AB

Post Reply

Who is online

Users browsing this forum: Google [Bot] and 22 guests