What Application Pool does this W3WP.EXE belong to?

Published 22 February 06 04:58 AM | jamesbl 

During the course of working through issues, I get asked at least twice a week how to determine which application pool maps to a particular worker process PID (Process ID) on a server.  I suppose there are lots of ways to determine this, but here two that come to mind to determine the answer.

The first way, and by far the easiest, is to use one of the new scripts that come in the box called IISAPP.VBS.  It is located in the %SystemRoot%\system32 directory.  For example:

C:\WINDOWS\system32>cscript iisapp.vbs
Microsoft (R) Windows Script Host Version 5.6
Copyright (C) Microsoft Corporation 1996-2001. All rights reserved.

W3WP.exe PID: 1172 AppPoolId: StsAdminAppPool
W3WP.exe PID: 2656 AppPoolId: MSSharePointAppPool
W3WP.exe PID: 2148 AppPoolId: WMS App Pool
W3WP.exe PID: 3604 AppPoolId: defaultwebsite

As you can see, this script makes it very easy to determine what the PID is of each specific Application Pool.  This is nice to use when trying to determine which PID you may want to snap a dump of for debugging purposes.

There are others that are cool as well.  For more details on the various other scripts that are also included, see this link.  I also encourage you to open a command prompt, navigate to your system32 directory on your IIS6 machine then run a "dir iis*.vbs" command and check out the new scripts.

The second way is a bit more obscure and requires that you run the tlist.exe command, which comes with the Debugging Tools for Windows.  Here is an example of that, which is fairly interesting:

C:\Program Files\Debugging Tools for Windows>tlist -v
0 1172 w3wp.exe
Command Line: c:\WINDOWS\system32\inetsrv\w3wp.exe -a \\.\pipe\iisipmec19a7d8-c08d-42f4-b2c9-69d7cfe28c74 -ap "StsAdminAppPool"
0 2656 w3wp.exe
Command Line: c:\WINDOWS\system32\inetsrv\w3wp.exe -a \\.\pipe\iisipm4bc52071-9ebb-4e39-9ba5-b256b4be4014 -t 20 -ap "MSSharePointAppPool"
0 2148 w3wp.exe
Command Line: c:\WINDOWS\system32\inetsrv\w3wp.exe -a \\.\pipe\iisipmfa132134-c1ed-47d4-be52-417ce5a59e63 -t 20 -ap "WMS App Pool"
0 3604 w3wp.exe Title: OLEChannelWnd
Command Line: c:\WINDOWS\system32\inetsrv\w3wp.exe -a \\.\pipe\iisipmdd93382a-645a-467c-bdbd-07c3ad6833a4 -t 20 -ap "defaultwebsite"

Note:  I snipped all other processes and only left the 4 W3WP.EXE processes that we're interested in.

If you look carefully above, you will see the name of the Application Pool specified directly on the command line for W3WP.EXE!  You mean you can call this thing directly?  Interestingly enough, there are documented command line options for it.  Interesting?  No?  Bonus points if you can tell me why the last application pool has a Title of "OLEChannelWnd" :)

For those interested parties still left reading, here are the command line options for W3WP.EXE that are documented via -?:

C:\WIN2003\system32\inetsrv>w3wp -?
Usage: w3wp [options]
 
        -debug
                 This option is required for launching from the command line.
                 If not provided the app pool name, default url, and site id
                 will be defaulted to
                         AppPoolName = StandAloneAppPool
                         URL list    = http://*:80/:80/:80/
                         Site Id     = 1
 
        -ap <Application Pool Name>
                 Indicates the application pool name
                 that will queue requests for the
                 worker process.  No other worker processes
                 with this name can be running at the
                 same time as this one
 
        -d <URL List>
                 Indicates the urls to listen to.
                 Examples:les:
                         http://*:80/:80/
                         http://HostString:80/
                         http://111.11.111.11:80:111.11.111.11/
                         http://HostString:80:111.11.111.11/
 
        -s <#>
                 Which site are the urls provided associated with.
                 The site number is used to access data from the metabase
                 for processing the requests.sts.

 

Good night...for now.

Filed under:

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# Rafael Marrara said on June 28, 2006 12:56 PM:
I just tried to get info about w3wp.exe using "-?", just like you did, and it's returning nothing. I would like to get some info about what does the parameters (specifically "-a" and "-t"). If you know anything about it, can you update the post with some info? I'm sure it would greatly help a lot of people.
# jamesbl said on June 30, 2006 1:21 AM:
Hi Rafael,

Neither of these switches you mentioned are really anything that can be used outside of IIS, so I'm not sure how it will help a lot of people, but...

The number after the -t command line argument maps to the idle timeout (in minutes) for the application pool in question, as configured on the "Performance" tab in the application pool properties window.
# Andrew said on August 30, 2006 7:12 PM:
You can always check the "Command Line" column in Proc Explorer (http://www.sysinternals.com/Utilities/ProcessExplorer.html) as well.
# Atteint de Javascriptite aigüe said on January 18, 2007 7:45 PM:

IIS6 possede un système de pool d'application qui permet de regrouper plusieurs sites web. Chaque pool

# Steve Mapua said on February 25, 2007 4:51 AM:

This is a bandaid that seemed to fix our problem

# samb said on September 4, 2007 6:35 AM:

Hi

I'm using a patched Windows 2003 SP2 server running IIS 6 and SQL 2000 SP4. I'm having some issues and noticed that w3wp is taking the most of my memory use. I ran the iisapp.vbs but all that showed is one entry:

AppPoolID: DefaultAppPool

Should I be using different pools for different apps?

# samb said on September 4, 2007 6:37 AM:

Sorry, my email is samb@townsware.com

# Joel Oleson's Blog SharePoint Land said on November 8, 2007 3:25 AM:

Talking to a buddy on Friday, the post he said he actually read was one I must have posted on 2003. I

# w3wp exe dumps said on May 15, 2008 2:23 PM:

PingBack from http://katelynn.clearviewlearning.info/w3wpexedumps.html

# w3wp exe dumps said on May 15, 2008 2:24 PM:

PingBack from http://maximo.newscontentworld.info/w3wpexedumps.html

# &nbsp; Application pool and the process of correspondence between W3WP.exe&nbsp;by&nbsp;Free Article For You said on July 31, 2008 11:10 AM:

PingBack from http://www.dajiahi.com/archives/27433

# Nicolas said on August 27, 2008 2:06 PM:

James, could you please write an article on how to configure IIS settings (Application Pools, HHTP Compression) for x64 servers to follow Joel's article on Application Pools settings(http://blogs.msdn.com/joelo/archive/2007/10/29/sharepoint-app-pool-settings.aspx ). From Joel comments I understand his article is about 32 bits servers or can I use the same settings on my 64 bits servers??

Thanks in advance for your help.

# Dirk Van den Berghe SharePoint Admin Blog said on September 25, 2008 7:32 AM:

Looking at the processes of one of my servers, I notices a huge memory consumption on one of the w3wp

# SharePoint Products and Technologies - Pointing to Share the Knowledge - Luis Du Solier G. said on October 27, 2008 9:28 PM:

Alguna vez has entrado al IIS Manager MMC y de pronto no ves los Sitios Web ni Applications Pools ni

# SharePoint en Español - Luis Du Solier G. said on October 27, 2008 9:29 PM:

Alguna vez has entrado al IIS Manager MMC y de pronto no ves los Sitios Web ni Applications Pools ni

# Luis Du Solier G. - SharePoint en Español said on October 27, 2008 9:29 PM:

Alguna vez has entrado al IIS Manager MMC y de pronto no ves los Sitios Web ni Applications Pools ni

# Installed VS2008 SP1, F5 no longer works for IIS websites | keyongtech said on January 18, 2009 12:35 PM:

PingBack from http://www.keyongtech.com/2391252-installed-vs2008-sp1-f5-no

# Thoughts about IIS and now SharePoint What Application Pool does | Cellulite Creams said on June 8, 2009 10:36 PM:

PingBack from http://cellulitecreamsite.info/story.php?id=8871

# 小向美奈子 said on June 13, 2009 4:54 PM:

話題の小向美奈子ストリップを隠し撮り!入念なボディチェックをすり抜けて超小型カメラで撮影した神動画がアップ中!期間限定配信の衝撃的映像を見逃すな

# Thoughts about IIS and now SharePoint What Application Pool does | debt consolidator said on June 19, 2009 11:23 AM:

PingBack from http://mydebtconsolidator.info/story.php?id=19932

Leave a Comment

(required) 
(optional)
(required) 
Page view tracker