w3wp.exe memory usage with simple hello world

本文探讨了在Windows Server 2003 SP2上使用IIS6.0和ASP.NET2.0时的内存占用情况。通过创建简单的ASP.NET页面并进行压力测试,发现内存使用量显著增加。解释了这种现象的原因,并说明这是由于.NET运行时和构建系统的加载导致的正常行为。

Question:

Hello,

while investigating some memory issues on my new server (win2003 SP2), i stumbled upon very demotivating results which i have a hard time believing. This is what i did:

1) i created a new website and an application pool to go with it. The default config was left and i'm using ASP.NET 2.0
2) i created an ASP.NET page with the following code:

<%@ Page Language="C#" EnableSessionState="false" %>
<% Response.Write("this is a test."); %>

Next i opened up my task manager, found the right w3wp.exe process and checked the VM SIZE column. Here are the results:

1) First hit: memory goes to 28MB
2) Second hit: it increases by some 20KB
3) I launched a stress tool (10 users for half a minute) and the memory increases by 10MB.

So now the memory was up at about 40MB and it remained there.

Is this normal behaviour? For such a simple page, it seems unbelievable to see such a high memory usage, especially the increase with each request.

Is this really the best result i could expect from IIS 6.0 running ASP.NET 2.0 ?

Greg

 

Answer:

That's normal behavior. ASP.NET is pretty heavyweight because the .NET Run-time and the build system will be loaded into memory. When you start a stress-testing certain caches and data structures get created. Sooner or later the memory consumption might go down a little,  e.g. if the Garbage Collector kicks in.

Hope this helps.

 

 

http://forums.iis.net/t/1154064.aspx

 

 

 

 

 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值