New discovery on Ali Cloud: Another kind of CPU fluctuation related to virtual memory

Source: Internet
Author: User

It's a strange place to be in the clouds, yesterday accidentally found in the application pool recycling settings for IIS, only set the recovery based on virtual memory limit, which caused the CPU to have regular fluctuations. In this blog post, we will report the small discovery on the way to cloud computing.

Before we used the Ali server (virtual machine) encountered a dilemma:

If you open the virtual memory paging file, will cause high CPU, in high concurrency will cause CPU 100%, the system does not respond to the fault, see cloud Computing Road-Ali Cloud: Enable Windows virtual memory raised CPU 100% failure.

If the virtual memory paging file is turned off, it will cause Windows to restart automatically if the virtual memory is not enough for a short period of time, as detailed in the cloud computing road-Ali Cloud: Disabling the reboot caused by Windows virtual memory.

The problem was temporarily solved by adding physical memory (8g->16g), but this is not a long-term solution, and not only does it matter who pays for the extra cost (the Aliyun memory price ratio is inherently low), and even 16G of memory does not guarantee that virtual memory is not enough.

So we turned the focus to how to avoid the problem in 8G memory. The single w3wp process used by our applications consumes about 2G of memory during peak access times, with a total of approximately 5G of memory consumed during the peak of the visit due to the 2 worker processes set up for the Web garden. This may be the case that virtual memory is not enough under the condition of instantaneous large concurrency and GC recovery. In response to this situation, we have taken two measures:

Cancel the Web Garden, using only 1 w3wp.

Set the application pool recycle policy to force a recycle when the memory consumed by the w3wp process reaches a certain value.

The Application pool recycle policy setting is shown in the following illustration:

As you can see from the illustration above, the recycle strategy is to force a recycle when the w3wp process consumes more than 6G of virtual memory.

See more highlights of this column: http://www.bianceng.cnhttp://www.bianceng.cn/Servers/cloud-computing/

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.