Microsoft KB Archive/911822

= FIX: The worker process of an application may use lots of memory in Internet Information Services 6.0 =

Article ID: 911822

Article Last Modified on 12/3/2007

-

APPLIES TO


 * Microsoft Internet Information Services 6.0

-





Important This article contains information about how to modify the registry. Make sure to back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry



SYMPTOMS
Consider the following scenario. You run Microsoft Internet Information Services (IIS) version 6.0 on a computer that is running Microsoft Windows Server 2003. You host an application that processes a very large amount of static file requests. In this scenario, the worker process of the application may use lots of memory. As the process continues to run, a decreasing amount of memory is available over time. Eventually, the process may run out of memory to allocate.



CAUSE
IIS 6.0 keeps a user mode cache entry for each Internet Server API (ISAPI) response that is sent back to the clients through the Http.sys file. This user mode cache entry has an infinite Time to Live (TTL). When the application data changes, IIS 6.0 uses this user mode cache entry to flush the kernel mode cache entry from the Http.sys file. The design of IIS 6.0 makes sure that the clients are always served with the latest data. For an application that processes a very large amount of static file requests, the cached response for such requests remains in user mode memory until IIS 6.0 is recycled.



Service pack information
To resolve this problem, obtain the latest service pack for Windows Server 2003. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

889100 How to obtain the latest service pack for Windows Server 2003

Registry information
Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall your operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

After you apply this hotfix, you must add and configure the DontFlushCachedIsapiResponses registry entry to disable the user mode tracking and the flushing of cached ISAPI responses. To do this, follow these steps:  Click Start, click Run, type regedit, and then click OK. Locate and then click the following registry subkey:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters

 On the Edit menu, point to New, and then click DWORD Value. Type DontFlushCachedIsapiResponses as the entry name, and then press ENTER. Right-click DontFlushCachedIsapiResponses, and then click Modify. In the Value data box, type 1 to enable the hotfix, and then click OK.

Note To return the service to the default behavior, type a value that is other than 0.</li> Exit Registry Editor.</li> Restart the World Wide Web Publishing Service (WWW service). To do this, follow these steps: <ol style="list-style-type: lower-alpha;"> Click Start, click Run, type cmd, and then click OK.</li> Type the following commands, and then press ENTER after each command:

net stop w3svc

net start w3svc

</li></ol> </li></ol>

Prerequisites
To apply this hotfix, you must have Windows Server 2003 with Service Pack 1 (SP1) installed on the computer.

Restart requirement
You do not have to restart the computer after you apply this hotfix.

Hotfix replacement information
This hotfix does not replace any other hotfixes.

File information
The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

<div class="status_section">

STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section. This problem was first corrected in Windows Server 2003 Service Pack 2.

<div class="moreinformation_section">

MORE INFORMATION
By applying this hotfix and by using the new registry entry, you can disable the user mode tracking and the flushing of cached ISAPI responses.

Important We highly recommend that you contact Microsoft Product Support Services and have the problem diagnosed before you disable this feature. Regardless of where memory leaks occur, memory leaks generally exhibit the same behavior. However, the root cause for each memory leak may be different.

Disabling this feature has several side effects. For example, IIS 6.0 will no longer invalidate the cached ISAPI responses. If any metadata changes, the change will not flush the cache. For example, if an anonymous response was cached in kernel (Http.sys) and you changed the virtual directory to require Basic Authentication, the change will not flush the cache. The Http.sys file will still return the data to anonymous requests. Disabling this feature may only be effective in certain circumstances and may not be a good choice for everyone.

For more information, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates

Additional query words: IIS6, Cache, ISAPI, Response, Memory leak

Keywords: kbbug kbfix kbqfe kbmemory kbpubtypekc kbwinserv2003presp1fix kbhotfixserver kbwinserv2003sp2fix KB911822

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.