SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I built a HTTP Module, insert the DLL into the GAC, changed the webConfig Now , if on visual studio , I Attach to process W3WP , Open the web page where the module must work, I notice that breakpoints has warning and they don't hit! There are more than one w3wp.exe process. Which one should I Catch? I don't if I'm attaching to the wrong process. enter image description here

share|improve this question

Usually you can discover which one to attach to by the user name. It is usually the same as the application pool identity you're running your SharePoint Web Application with.

It's no problem to attach to all, but for god sakes, do not attach to processes on a production environment, because hitting breakpoint, pauses sharepoint processes.

It is also important to at least recycle the application pool after adding the DLL to Gac.

share|improve this answer
Just what I was going to say. If you are on a dev machine, attach to all w3wp processes that you find. – SPArchaeologist Nov 22 '12 at 10:24

To find more information about the w3wp processes to figure out which one to attach to, you can use this command (I have it saved to a batch file).

%windir%\system32\inetsrv\appcmd.exe list wp

I've got one for SecurityTokenService, one with a GUID-ish name that is the search service, and one called "Sharepoint - Port#" for each web app.

share|improve this answer

The rule of thumb for me was always to pick the worker process with the highest number as ID.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.