Why add additional application pools in IIS?
Solution 1:
Yes, many:
- AppPools can run as different identities, so you can restrict permissions this way.
- You can assign a different identity to each app pool so that when you run task manager, you know which w3wp.exe is which.
- You can recycle/restart one app pool without affecting the sites that are running in different app pools.
- If you have a website that has a memory leak or generally misbehaves, you can place it in an app pool so it doesn't affect the other web sites
- If you have a website that is very CPU-intensive (like resizing photos, for instance), you can place it in its own app pool and throttle its CPU utilization
- If you have multiple websites that each have their own SQL database, you can use active directory authentication instead of storing usernames/passwords in web.config.
Solution 2:
I create my IIS application pools and separate apps under these aspects:
- Mission-critical apps get their own app pool: this way I can insulate them from problematic applications. It makes individual configuration possible and I can more easily monitor or troubleshoot, if there are problems.
- Isolating apps by type: pooling by language/technology or .NET framework version. You could mix ASP.NET with classic ASP in the same pool, but if both ASP and ASP.NET were in the same pool, and if you have a problem with your ASP application which required that you restart the worker process, your ASP.NET applications would also be recycled.
- Problematic apps (for example apps with memory leaks or high cpu usage, database connections leaking etc) are separated from normal apps. New apps go into an "on probation" pool which is monitored for uptime and performance. If the app proves to be stable over time, it is moved to a pool for normal apps; otherwise, it remains isolated. This helps group the more problem-free apps together.
Solution 3:
Also in addition to Portmans answers - for security reasons. restricting Resources access to a pool. See http://blogs.iis.net/tomwoolums/archive/2008/12/17/iis-7-0-application-pools.aspx