Optimizing IIS Application Pools to prevent IIS from faking death

Source: Internet
Author: User
Tags iis time limit

The server often produces "application pool ' DefaultAppPool ' processes that provide services that are closed longer than the limit. The process ID is ' 2068 '. "Error, which causes IIS to be in suspended animation, is known to be an IIS application pool Setup issue. Here's how to fix it:

The 1th method:

Internet Information Services (IIS) Manager-> Application pool->defaultapppool-> right-click Properties


First, recycling
1. Recovery work process (minutes): checked, value is 1740
2. Recovery worker process (number of requests): Not selected (originally set to 35000)
3, the following time to recycle the work process: do not fill
4, consume too much memory when the process of recycling: all do not select. (2, 3, 4 items may avoid server response problems that may be caused by forcing the recycle process at high traffic levels, causing IIS to suspend animation)


Second, performance
Only the idle timeout is checked for 20 minutes. None of the other options. The maximum number of worker processes in the Web garden is 1 (default). Note that the Web Park here must remain the default, if you fill in the other more than 1 of the number will cause some of the website program background program can not open or refresh constantly.

The original request queue limit is 4000 and is now unrestricted.


Third, the Operation status
The first two entries are used, which is the original default setting. The start time limit is 90 seconds and the closing time limit is 180 seconds.

Remove the hook that starts the quick fail protection.
In order to avoid really encountering a lot of errors without prompting, you can not shut down, just to increase the protection of rapid protection, such as the number of failures 50 times the time period of 5 minutes to close the corresponding program.

"Close time limit of 180 seconds" is required, because the process shutdown time, the original 90-second limit, is the default value, if the process is closed for more than 90 seconds, it is considered time-out, resulting in: Process shutdown time exceeds the limit log, so, appropriate extension of this time, can avoid this error

--------------------------------------------------------------------------------------------------------------- ---------------------

The 2nd method:


Cause: The memory heap constricted of the standalone process is exhausted, and IIS cannot create more process workspaces to handle
Workaround:
1. HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC
2. Create a new DWORD entry under the Parameters key named: Usesharedwpdesktop with a value of 1 restart IIS

--------------------------------------------------------------------------------------------------------------- ---------------------


3rd type (not tested)


The problem has been resolved, found that the database connection can not be released, do not know what the reason, the same code in the local is good, the server side of the problem, and finally in the connection string to add the following statement to solve the problem.
Pooling=true; MAX Pool size=512; Min Pool size=50; Connection lifetime=30

--------------------------------------------------------------------------------------------------------------- ---------------------

4th Type


Create a new application pool, with different Web sites referencing different program pools.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.