Caution when stopping and starting an IIS application pool with appcmd

When starting and stopping IIS 7 application pools from command line with appcmd.exe, you should be aware of a behavior that can sometimes lead to unintended circumstances. To explain it, lets first review what happens when you stop an application pool with the InetMgr.exe tool: 1) Set the autoStart property of the <applicationPool> configuration element to … [Read more…]

When to restart IIS when making changes to your application

Knowing when to restart IIS to pick up various types of changes to your application has traditionally been a challenge. IIS and ASP.NET are both stateful software systems, which heavily rely on cached state that is loaded once to provide high performance.  They also recognize the downside of being stateful – having to refresh the … [Read more…]

Trace IIS 7.0 Errors Like a Pro with Failed Request Tracing

When you are working with the web server, dealing with errors is a fact of life.  They creep in when applications change, when you deploy to a new server, make configuration changes, or add new functionality. The IIS 7.0 philosophy with respect to errors is that an error is better than something seemingly working in … [Read more…]

Starting, stopping and recycling IIS 7.0 Web sites and application pools

As many of you know, IIS 7.0 provides the ability to start and stop Web sites, and application pools.  However, since previous releases, there has been much confusion as to what exactly happens when you do so. This post should clarify this and provide you with the tools you need to execute the tasks correctly. Update: … [Read more…]

Finding your way around IIS 7 configuration sections with AppCmd

The IIS 7 configuration system contains 50+ configuration sections (100+ if you count .NET Framework configuration), 477 attributes, and 57 collections.  This can make it pretty challenging to figure out exactly what IIS 7 configuration section needs to be used to turn on some particular behavior, and then exactly syntax the configuration in that section should … [Read more…]

Fastest way to create IIS7 websites, applications, and application pools

IIS7 provides quite a few ways to create websites, applications, and application pools.  The simplest way of course is to use the new GUI Administration tool, where your new website is always a few mouse-clicks away. But, what if you need to create 10, 100, or even 10,000 websites?  Unless you own a farm of … [Read more…]

Anatomy of an IIS7 configuration path

If you have worked with IIS6 and previous versions of IIS, you are most likely familiar with the IIS metabase paths.  You know, the ones that look like LM/W3SVC/1/ROOT.  These metabase paths serve as a mechanism to identify a part of the IIS website hierarchy, or a url therein, for the purposes of read/writing their … [Read more…]

Creating IIS7 sites, applications, and virtual directories

In the course of IIS7 development, the team and I have answered an infinity of questions about IIS7 on any possible topic imaginable.Ironically, neither I nor anyone else I know on the team has ever answered the most basic question – what is the minimum set of steps necessary to get a website running with … [Read more…]