Configuring ASP.NET Applications in Worker Process Isolation Mode (IIS 6.0)

When you install ASP.NET on a computer running Windows Server 2003, there are two process model modes that you can choose. By default, ASP.NET uses the IIS 6.0 worker process isolation mode. This mode allows you to configure application pools, recycle worker processes, enable Web gardening, set idle time-outs and processor affinity, and use a variety of application health maintenance features. On computers running a member of the Windows Server 2003 family, your ASP.NET applications should use the worker process isolation mode unless you encounter specific compatibility issues.

The <processModel> element configures the ASP.NET process model settings on an IIS Web server. The <processModel> section can be set only within the Machine.config file, and it affects all ASP.NET applications running on the server.

Configuring the <processModel> Element Using IIS Manager

  Important

These features of IIS 6.0 are available only when running in worker process isolation mode.

timeout Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

The timeout attribute specifies the number of minutes until ASP.NET launches a new worker process to take the place of the current one. The default setting is Infinite. The Recycle worker processes entry is set to 120 minutes, as shown below, and is on by default.

Important   You must be a member of the Administrators group on the local computer to perform the following procedure or procedures. As a security best practice, log on to your computer by using an account that is not in the Administrators group, and then use the runas command to run IIS Manager as an administrator. At a command prompt, type runas /User:Administrative_AccountName"mmc %systemroot%\system32\inetsrv\iis.msc".

To configure the ASP.NET attribute timeout using IIS Manager

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and click Properties.

2.

On the Recycling tab, select the Recycle worker processes (in minutes) check box.

3.

Click the up or down arrow to set the number of minutes you want to elapse before the worker process is recycled.

4.

Click OK.

idleTimeout Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

The worker processes or application pools in IIS 6.0 can be shut down after remaining idle for a specific amount of time. The Shutdown worker process entry is set to 20 minutes and is on by default.

To configure the ASP.NET attribute idleTimeout using IIS Manager

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and then click Properties.

2.

Click the Performance tab, and under Idle timeout, select the Shutdown worker processes after being idle for check box.

3.

In the minutes box, type the number of idle (no processing requests) minutes that you want to elapse before shutting down the idle worker process.

4.

Click OK.

shutdownTimeout Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

The shutdownTimeout attribute specifies the amount of time the worker process is given to shut itself down gracefully. The time is expressed in hr:min:sec string format. The worker process Shutdown time limit is set to 90 seconds, as shown below.

To configure the ASP.NET attribute shutdownTimeout using IIS Manager

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and click Properties.

2.

Click the Health tab, and under Shutdown time limit, in the seconds box next to Worker process must shutdown within, type the desired number of seconds.

3.

Click OK.

requestLimit Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

The worker processes or application pools in IIS 6.0 can be set to recycle after a specific number of requests. This feature is not on by default.

To configure the ASP.NET attribute requestLimit using IIS Manager

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and then click Properties.

2.

Select Recycle worker process (in requests) and type the maximum amount of virtual memory allowed before the worker process is recycled.

3.

Click OK.

requestQueueLimit Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

The requestQueueLimit attribute specifies the maximum allowed number of requests that will be queued in the Internet Server API (ISAPI) while waiting for the worker process to start after an abnormal termination. Note that this setting does not apply in the case of a clean shut down or normal cycle. The queue limit in IIS 6.0 is set in the kernel and is set to 1000 by default.

To configure the ASP.NET attribute requestQueueLimit using IIS Manager

1.

In IIS Manager, expand the local computer, expand the Application Pools folder, right-click the application, and then click Properties.

2.

Click the Performance tab.

3.

In the Request queue limit section, select the Limit the kernel request queue to check box, and click the up and down arrows in the requests box to set the maximum number of queued requests.

4.

Click Apply, and then click OK.

memoryLimit Equivalent Setting in IIS 6.0 Worker Process Isolation Mode

In IIS 6.0 worker process isolation mode, worker processes can be recycled based on both virtual memory and physical memory. Unlike the Machine.config files, the memory limit is not a percentage value, it is a finite value measured in megabytes.

Recycling based on physical or virtual memory is not on by default, but if selected, the default value is 500 megabytes (MB) for the virtual memory and 192 MB for the physical memory.

To configure the ASP.NET attribute memoryLimit using IIS Manager

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and click Properties.

2.

On the Recycling tab, under Memory recycling, select the Maximum virtual memory (in megabytes) or Maximum used memory (in megabytes) check box.

3.

Click the up or down arrow to set memory limits.

4.

Click OK.

webGarden and cpuMask Equivalent Settings in IIS 6.0 Worker Process Isolation Mode

The webGarden attribute controls Web garden mode, or using multiple affinitized worker processes. The cpuMask controls the number of processes and the way the Web garden works.

Since webGarden enables the use of multiple processes, it means that all processes will have their own copy of things like application state, in-process session state, caches, and static data.

When using Web gardens, keep in mind the following:

If your application uses session state, it must choose an out-of-process provider (NT Service or SQL).

Application state and application statics are per process, not per computer.

Caching is per process, not per computer.

Web gardens can be also set up in IIS 6.0 worker process isolation mode by increasing the maximum number of worker processes per application pool from 1 to n (as required).

To configure the ASP.NET attribute webGarden and cpuMask

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and then click Properties.

2.

Click the Performance tab, and under Web garden, in the Maximum number of worker processes box, type the number of worker processes that you want to assign to the application pool.

3.

Click OK.

userName and password Equivalent Settings in IIS 6.0 Worker Process Isolation Mode

The userName attribute allows the worker process to run with a different Windows identity than the default process identity. By default, this attribute is empty and the process runs as the IIS identity. If valid credentials are presented in the userName and password attributes, the process runs as the given account. When present, these attributes cause the worker process to run as the configured Windows identity. The default is blank attributes. In worker process isolation mode, the default is to run as Network Service. However, they can be set to a configurable account as follows.

To configure the ASP.NET attributes userName and password

1.

In IIS Manager, expand the local computer, expand the Application Pools folder, right-click the application pool you would like to configure, and click Properties.

2.

Click the Identity tab.

3.

Click Configurable.

4.

Click Browse, and under Enter the object name to select, type the account name in which you want your worker process to run, and click OK.

5.

In the Password box, type the password associated with this account. If there is no password associated with the account, leave the Password box blank.

6.

Click OK.

  Important

When you configure a worker process identity for an application pool using a configurable account, you must add the account you created to the IIS_WPG group in order for the worker process to run.

pingFrequency and pingTimeout Equivalent Settings in IIS 6.0 Worker Process Isolation Mode

The pingFrequency attribute is the time interval in standard process model format (hr:min:sec). The default is 30 seconds. The pingTimeout attribute is the time interval in standard process model format (hr:min:sc). The default is 5 seconds.

In IIS 6.0 worker process isolation mode, pinging is enabled by default. The default value of pingFrequency is 30 seconds after the response comes back from the worker process. The equivalent setting for pingTimeout is PingResponseTime Metabase Property, which is 90 seconds and can be changed directly in the metabase.

To configure the ASP.NET attribute pingFrequency and pingTimeout

1.

In IIS Manager, expand the local computer, expand Application Pools, right-click the application pool, and then click Properties.

2.

Click the Health tab, and select the Enable pinging check box.

3.

In the seconds box next to Ping worker process, type the number of seconds that you want to elapse between pings.

4.

Click OK

Related Information

For information on configuring the ASP.NET worker process for a hosted environment so that users cannot obtain privileged access to information on the server, see Configuring ASP.NET Process Identity.

For more information on the ASP.NET configuration system, see ASP.NET Configuration.



© 2016 Microsoft Corporation. All rights reserved. Contact Us |Terms of Use |Trademarks |Privacy & Cookies
Microsoft