Article ID: 322350
This step-by-step article describes how to download and use the Internet Information Services (IIS) 5.0 Process Recycling Tool (IIS5Recycle) version 1.0, which was released in June 2001.
The following example illustrates how IIS5Recycle can be used to recycle processes and to gather information:
Minimizing consumption caused by memory leaks:
A Web administrator suspects that Web applications that are running on the servers are leaking memory. The administrator schedules periodic recycling of IIS processes to release resources that are consumed by the leaking Web applications. The administrator can troubleshoot a Web application by using the Advanced Scripting feature. The administrator gathers and logs information about a problematic Web application before IIS is recycled. While the Web site continues to serve the customer, a developer can analyze the logs.
Configure IIS5RecycleIIS5Recycle automatically recycles IIS processes based on the following criteria:
Stop IIS with IIS5RecycleIIS5Recycle forcefully stops IIS if a recycle request is unsuccessful after a configurable amount of time. This functionality makes sure that IIS is recycled when a recycle threshold is met. The registry key for this feature is IISStopTimeoutSecs.
Value name: NoRealRecycleTo turn off this feature, set the NoRealRecycle key to 0 in the registry.
Data type: REG_DWORD
Value data: 1
On the IIS5Recycle screen, click Advanced to open the Advanced Control window. In the resulting window, you can add commands to run before or after IIS is recycled, and you can also add a timeout value for these commands.
The return value of the Before Command section is verified if the Verify Return Value check box is selected. The output of the script is redirected to a log file under %windir%\System32\Logfiles\Iis5recycle. If the script does not return the expected value, the current recycle is skipped.
Note On a system that uses Windows Load Balancing Service (WLBS), the script is executed after WLBS stops and before WLBS starts.
If you do not see the expected output in the log file, verify that the script name is correct and that it is copied to the %windir%\system32 directory. If the script must access any other executable files, make sure that all of those files are also located in the %windir%\system32 directory.
The WaterMark feature guarantees that the number of servers in the cluster will always be more than the value that is set for WLBSWaterMark in the registry. There are two requirements to use the WaterMark feature:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\IIs5RecycleIIS5Recycle picks up all registry changes automatically.
You can configure the following entries by using the user interface in the IIS5Recycle Tool:
Description: Recycles an IIS process every specified number of hours.
Default: 24 * 7 (No Recycle)
Description: Recycles an IIS process every specified number of received HTTP requests.
Default: 200,000 Requests
Description: Recycles an IIS process at certain times of a day.
Default: Blank (No Recycle schedule)
Description: Recycles an IIS process if it uses more than a specified amount of memory (in KB).
Default: 1000000 KB
Description: Recycles an IIS process if the value of ASP requests queued is over this specified value in ASPThresholdRetries.
Description: Runs this script after the IIS process is recycled.
Description: Runs this script before the IIS process is recycled.
Description: The time that is permitted for the custom scripts to run before or after the IIS process is recycled.
Default: 300 seconds
The following are the names, types, and default values of the registry entries that IIS5Recycle uses. Note that you can only configure these settings by using the registry. You cannot configure these settings by using the user interface for the IIS5Recycle Tool.
Note Your computer must be running Microsoft Windows 2000 Server with IIS 5.0 to add these registry entries.
Description: Indicates how frequently processes query IIS status.
Default: 15 minutes
Description: Indicates how long to wait to see if IIS can reach a quiet time that is defined by QuietTimeRequests if a recycle condition is reached.
Default: 0 minutes (recycle immediately)
Description: Used to determine if IIS reached the quiet time. IIS tries to recycle processes at the next quiet time (if RecycleIISDelayMinutesequals zero) if a recycle condition is reached.
Default: 10 GET requests/second
Description: Indicates the time specified for IIS to stop before a timeout occurs.
Default: 60 seconds
Description: Indicates the time specified for IIS to start before a timeout occurs.
Default: 60 seconds
Description: Reports a recycle event only.
Default: 0 (do a recycle)
Description: Indicates the time specified for a WLBS drain to stop.
Default: 60 seconds
Description: Indicates the number of current active hosts the NLB cluster must have to prevent IIS from skipping the current recycle period. IIS skips the recycle period if the number of current active hosts in the NLB cluster is equal to or below this threshold.
Default: 0 (disabled)
Description: Indicates the minimum number of current connections for IIS5Recycle to stop draining. IIS5Recycle stops draining if the number of current connections is below this value.
Default: 0 (drain until there are no connections)
Description: Prevents NLB from being started by other monitoring programs during the WLBSDrainWaitSecs period.
Default: 0 (disabled)
Description: Indicates how many times IIS5Recycle retries when the number of ASP requests queued is above the set value of ASPRequestsQueued.
Default: 0 (no retries)
To add these entries, follow these steps:
For more information, visit the following Microsoft TechNet Web sites:
IIS 5.0 Process Recycling Tool
The following file is available for download from the Microsoft Download Center:
Download the IIS5Recycle.exe package now.
Collapse this imageExpand this image
(http://www.microsoft.com/downloads/details.aspx?FamilyID=c4ba5f3c-1eb2-4f3c-99b0-b0cde072a7d8&DisplayLang=en)For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:
119591Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.
(http://support.microsoft.com/kb/119591/ )How to Obtain Microsoft Support Files from Online Services
Article ID: 322350 - Last Review: June 19, 2014 - Revision: 8.0
Retired KB Content Disclaimer
This article was written about products for which Microsoft no longer offers support. Therefore, this article is offered "as is" and will no longer be updated.
Contact us for more help