Point Deep

Mundeep's Tech Blog

Attaching to the right process when debugging

Posted by mundeep on August 18, 2011

A common problem when trying to debug an ASP.NET web application (including SharePoint based solutions) is determining which w3wp.exe process to attach to. Thankfully there are a couple of commands to help out.

If using IIS7:
c:\Windows\System32\inetsrv\appcmd list wp

If using IIS6:
cscript c:\WINDOWS\system32\iisapp.vbs

Source: http://stackoverflow.com/questions/748927/iis-application-pool-pid

About these ads

2 Responses to “Attaching to the right process when debugging”

  1. lemonharpy said

    One other thing, mundeep, that I’ve only recently discovered. You don’t necessarily have to attach to the correct W3WP when debugging — you can actually just attach to *all of them* (click on first, shift-click on last). Overkill, perhaps, but can speed you up when debugging.

  2. mundeep said

    Yes that is also possible, however that is exactly what i have been trying to avoid hence this blog post. Especially when you are debugging a server others are also working on :)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
Follow

Get every new post delivered to your Inbox.

%d bloggers like this: