讓Windows Server 2008 + IIS 7+ ASP.NET 支援10萬並發請求

來源:互聯網
上載者:User

標籤:sof   http   asp   啟用   文章   controls   strong   lib   html   

轉自:http://www.cnblogs.com/yxlblogs/p/3330972.html

由於之前使用的是預設配置,伺服器最多隻能處理5000個同時請求,今天下午由於某種情況造成同時請求超過5000,從而出現了上面的錯誤。

為了避免這樣的錯誤,我們根據相關文檔調整了設定,讓伺服器從設定上支援10萬個並發請求。

具體設定如下:

1. 調整IIS 7應用程式集區隊列長度

由原來的預設1000改為65535。

IIS Manager > ApplicationPools > Advanced Settings

Queue Length : 65535

2.  調整IIS 7的appConcurrentRequestLimit設定

由原來的預設5000改為100000。

c:\windows\system32\inetsrv\appcmd.exe set config /section:serverRuntime /appConcurrentRequestLimit:100000

在%systemroot%\System32\inetsrv\config\applicationHost.config中可以查看到該設定:

<serverRuntime appConcurrentRequestLimit="100000" /> 

3. 調整machine.config中的processModel>requestQueueLimit的設定

由原來的預設5000改為100000。

<configuration>    <system.web>        <processModel enable="true" requestQueueLimit="100000"/>

參考文章:http://technet.microsoft.com/en-us/library/dd425294(office.13).aspx

4. 修改註冊表,調整IIS 7支援的同時TCPIP串連數

由原來的預設5000改為100000。

reg add HKLM\System\CurrentControlSet\Services\HTTP\Parameters /v MaxConnections /t REG_DWORD /d 100000 

5. 運行命令使用設定生效 

net stop http  & net start  http & iisreset 

完成上述4個設定,就可以支援10萬個並發請求,部落格園部落格伺服器已經啟用上述設定。 

讓Windows Server 2008 + IIS 7+ ASP.NET 支援10萬並發請求

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.