次の方法で共有


What size footprint does your worker process leave?

Well it all depends on what you are cramming into your request pipeline! With IIS7's modular architecture you have the ability to load only what you need to run. What does this mean - well let's look at the footprint of a worker process that has all default modules loaded, i.e. ASP/ASP.NET/CGI/Authorization etc etc.

To see the footprint in its entirety we want to dump out the applications loaded and see their usage. For this I have a handy PowerShell script I whacked together (because I love PowerShell); So browse to your website to spin up a worker process then run the following at a PowerShell prompt:

gps -name w3wp | select -expand Modules | where {$_.Filename -like '*\inetsrv*} | ft

which should give you something like the following:

image

this shows the footprint of a worker module with a default install of IIS 7.0 - you can see all the various modules loaded there for authorization, authentication, gzip etc. So how big is our worker process with no modules? Well simply rip the <globalmodules> out of the applicationhost.config file - NOT RECOMMENDED - without backup up your config first of course. Now browse to your site and you will notice nothing happens...- because you've ripped out all the modules there is nothing to process the request - thus you will get a naked worker process - lets take a look:

image

So you can see with IIS7 you can really customize what happens in your request pipeline to make huge differences to the size of your worker processes. Neat eh?

Now I've also found out you can do the same as PowerShell script by simply running:

tasklist /fi "imagename eq w3wp.exe" /M

but where's the fun in that.. :)

-jorke