473,403 Members | 2,323 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

Memory leak in aspnet_wp.exe

aspnet_wp process accumulates memory usage up to the point when it's more
than 60% of available RAM (2G) and none of .NET applications function.
Sometimes user is able to login, navigate between the pages but can't perform
any operations that generate thing like PDF files using Crystal Reports etc.
Sometimes the application can't even be loaded and sign-in page stays blank.
There are no events that are logged in the event viewer to point to this
problem. However we do find these errors occasionally:

"aspnet_wp.exe (PID: 3900) was recycled because it was suspected to be in a
deadlocked state. It did not send any responses for pending requests in the
last 180 seconds. This timeout may be adjusted using the <processModel
responseDeadlockInterval> setting in machine.config. "

and

"aspnet_wp.exe (PID: 3328) was recycled because it failed to respond to
ping message. "

and

"Failed to execute request because QueryInterface for ASP.NET runtime
failed. Error: 0x80004005 Unspecified error "

Can you tell me how we can trap or log this information so that we can find
what is causing the leak and solve it.
Nov 19 '05 #1
2 5128
Raptor:
You have a long and difficult journey ahead of you.
Here are some resources that will be key in your battle:
http://blogs.msdn.com/akhune/archive...11/153734.aspx
http://blogs.msdn.com/yunjin/archive.../27/63642.aspx

http://www.scitech.se/memprofiler/ (14 day free trial ought to be good
enough)
http://www.red-gate.com/code_profiling.htm (14 day free trial ought to be
good enough).
First you need to figure out if this is a managed or unmanaged leak. The
first rticle tells you how to figure it out (never mind using SOS stuff with
windbg and simply use perfmon and the above profile r(scitech is probably
better). Assuming it's a managed leak, it isn't actually a leak it's really
the simple fact that you are holding on to references to your objects,
you'll need to do some investigating. You can take snapshots with the above
tools to figure out what objects are taking the most space. You'll have
String and Int32 and Boolean at the top, but look for your own custom
objects, or larger objects such as DataSets, collections and arrays as these
are likely the root objects of the strings and ints which are really holding
on to memory.

Make sure you call Dispose() on things. Simplify your code so you have less
references to the same object all over the place (utility classes can often
help manage these references by providing single point of access).

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/
"RaptorsFan" <Ra********@discussions.microsoft.com> wrote in message
news:7A**********************************@microsof t.com...
aspnet_wp process accumulates memory usage up to the point when it's more
than 60% of available RAM (2G) and none of .NET applications function.
Sometimes user is able to login, navigate between the pages but can't perform any operations that generate thing like PDF files using Crystal Reports etc. Sometimes the application can't even be loaded and sign-in page stays blank. There are no events that are logged in the event viewer to point to this
problem. However we do find these errors occasionally:

"aspnet_wp.exe (PID: 3900) was recycled because it was suspected to be in a deadlocked state. It did not send any responses for pending requests in the last 180 seconds. This timeout may be adjusted using the <processModel
responseDeadlockInterval> setting in machine.config. "

and

"aspnet_wp.exe (PID: 3328) was recycled because it failed to respond to
ping message. "

and

"Failed to execute request because QueryInterface for ASP.NET runtime
failed. Error: 0x80004005 Unspecified error "

Can you tell me how we can trap or log this information so that we can find what is causing the leak and solve it.

Nov 19 '05 #2
I've received those errors, too, and here's a few things that I've learned.

Do not use excessive arrays - they chomp memory until the session expires.
If you have 10 clients, and use Dim a(1000) somewhere in your code, that's a
ton of RAM if a() is an array of controls.

Do not overburden the wp by doing long computational things such as
interpolation of a surface. Pass them on to other processes such as dll's,
etc...

Make the session timeout as short as practical. That will free RAM more
quickly.

HTH,

Steve
"RaptorsFan" <Ra********@discussions.microsoft.com> wrote in message
news:7A**********************************@microsof t.com...
aspnet_wp process accumulates memory usage up to the point when it's more
than 60% of available RAM (2G) and none of .NET applications function.
Sometimes user is able to login, navigate between the pages but can't perform any operations that generate thing like PDF files using Crystal Reports etc. Sometimes the application can't even be loaded and sign-in page stays blank. There are no events that are logged in the event viewer to point to this
problem. However we do find these errors occasionally:

"aspnet_wp.exe (PID: 3900) was recycled because it was suspected to be in a deadlocked state. It did not send any responses for pending requests in the last 180 seconds. This timeout may be adjusted using the <processModel
responseDeadlockInterval> setting in machine.config. "

and

"aspnet_wp.exe (PID: 3328) was recycled because it failed to respond to
ping message. "

and

"Failed to execute request because QueryInterface for ASP.NET runtime
failed. Error: 0x80004005 Unspecified error "

Can you tell me how we can trap or log this information so that we can find what is causing the leak and solve it.

Nov 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: ianstirkcv | last post by:
Hello, I wonder if you can please help… We are running a web application built using .net framework version 1.0, service pack 2, running on Windows 2000 server, service pack 3. The server has...
8
by: ranjeet.gupta | last post by:
Dear All Is the Root Cause of the Memory corruption is the Memory leak, ?? suppose If in the code there is Memory leak, Do this may lead to the Memory Corruption while executing the program ? ...
7
by: Xing | last post by:
Hi all I am not an ASP developer but I am in a support case for our customer who's experiencing resource problems that seems to be ASP.NET related. Basically our app is built on .NET Framework 1.1...
1
by: caulker | last post by:
i have an asp.net that seems to be leaking memory somewhere. in an attempt to find it, i create a blank test.aspx page with one label on it, and made this the default page for the site. every time...
9
by: Anton | last post by:
{Willy Skjveland} Hi, how can I trace a Memory leak in aspnet_wp.exe? {Rheena} One moment please while I search it for you. It may take me a few moments {Willy Skjveland} I need to find out...
3
by: Emmanuel Gehin | last post by:
When I use the following code in VB.NET : Public Function test() As String Try Dim da1 As OdbcDataAdapter Dim i As Int32 Dim tfem As DataTable For i = 0 To 1000 da1 = New...
7
by: Erkan Tatlidil | last post by:
Hi, Our customer has a win2k Xeon 2.0 web server with 2GB of Ram. After a certain time the aspnet_wp.exe consumes %70 of the Ram and comes to a standstill. We end the process and everything is...
23
by: James | last post by:
The following code will create memory leaks!!! using System; using System.Diagnostics; using System.Data; using System.Data.SqlClient; namespace MemoryLeak
2
by: Rishan | last post by:
Hi, I'm trying to debug a memory leak on a production application for one of my clients. The aspnet_wp.exe, if left to grow, will eventually consume enough memory to throw an out of memory...
22
by: Peter | last post by:
I am using VS2008. I have a Windows Service application which creates Crystal Reports. This is a multi theaded application which can run several reports at one time. My problem - there is a...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.