Exception of type System.OutOfMemoryException is thrown

G

Guest

There are several pages that occasionally start throwing System.OutOfMemoryException and another exception related to storage.

The problem goes away after iisreset or terminating aspnet_wp.exe worker process.

- There is plenty of memory and disk space on the webserver
- worker process is high, but it does not take all available memory
- pages use remoted ServicedComponents
- I looked into KB - nothing even close. We don't upload files, no VB arrays, etc. The page simply call the component on the different server that does the work.

How can I find this problem?

Thanks,

-Stan
 
A

Alvin Bruney [MVP]

The .net memory profiler is a good starting point coupled with a few well
placed perfmon counters

--
Regards,
Alvin Bruney [ASP.NET MVP]
Got tidbits? Get it here...
http://tinyurl.com/3he3b
Stan said:
There are several pages that occasionally start throwing
System.OutOfMemoryException and another exception related to storage.
The problem goes away after iisreset or terminating aspnet_wp.exe worker process.

- There is plenty of memory and disk space on the webserver
- worker process is high, but it does not take all available memory
- pages use remoted ServicedComponents
- I looked into KB - nothing even close. We don't upload files, no VB
arrays, etc. The page simply call the component on the different server that
does the work.
 
S

Steven Cheng[MSFT]

Hi Stan,


Thanks for posting in the community!
From your description, you encountered the "System.OutOfMemoryException"
and some other related exceptions occassionally on some certain ASP.NET web
pages in your web application. Also, these pages have called a certain
remote SErviceComponent, yes?
If there is anything I misunderstood, please feel free to let me know.

As for this problem, I agee with Alvin Bruney's suggestion that you have a
check or monitor on your ASP.NET worker process to see whether there is
anything abnormal on it, especially the memory. In addition to the Memory
Profiler Alvin Bruney has mentioned, here are some other approaches on
monitor ASP.NET process and performance:

#Watching Your Server Processes
http://msdn.microsoft.com/library/en-us/dnaspp/html/aspnet-watchserverproces
ses.asp?frame=true

#ASP.NET Performance Monitoring, and When to Alert Administrators
http://msdn.microsoft.com/library/en-us/dnaspp/html/monitor_perf.asp?frame=t
rue

#Production Debugging for .NET Framework Applications
http://msdn.microsoft.com/library/en-us/dnbda/html/DBGch02.asp?frame=true

#Performance Counters for ASP.NET
http://msdn.microsoft.com/library/en-us/cpguide/html/cpconPerformanceCounter
sForASPNET.asp?frame=true

In addtion, I still feel the remote SeriveComponent is a potential cause.
Would you please try temporarily remove the remote Component's calling from
those web pages to see whether the problem goes away? Or would you please
provide some further descriptions on a certain page which calls the remote
component or some infos on the remote SErviceComponent?

Please check out the above items. If you meet any further assitance, please
feel free to post here.



Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

-------------------------------------------------------------------------
 
G

Guest

Yes, thanks for the usefull links

The problem is still not resolved yet. What makes it very strange is that memoryLimit is set to 40% on 2Gb memory server, but the exception happens much earlier than that - when aspnet_wp reaches 250-300kb. I reduced the API cache duration and it seemed helped a little bit, but the problem persists and the people get paged in the middle of the night just to shutdown aspnet_wp...

It is so frustrated that ASP.NET is so unstable, and I don't see what we are doing wrong.

It all started when we started getting more hits on a web site

Thanks

-Sta

----- Steven Cheng[MSFT] wrote: ----

Hi Stan


Have you had a chance to check out my suggestions or have you got any
further progress on this issue? If you need any further assistance, please
feel free to post here



Regards

Steven Chen
Microsoft Online Suppor

Get Secure! www.microsoft.com/securit
(This posting is provided "AS IS", with no warranties, and confers no
rights.

Get Preview at ASP.NET whidbe
http://msdn.microsoft.com/asp.net/whidbey/default.asp
 
S

Steven Cheng[MSFT]

Hi Stan,


Thanks for your followup. From your further information, it seems that the
ASP.NET workerprocess doesn't take much memory, only 200-300k? So I doubt
that whether the problem is concerned with the ServicedComponent called
remotely?
Would you provide some further infos on the component or attach on the
process to have a debug on it?



Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
 
G

Guest

Steven

No, we haven't solved the problem yet. Since it happens on a production web server we are limited in diagnostic tools that can be used.. How should we approach this? Why we are getting OutOfMemoryException if there are plenty of memory

Do you want us to open a regular support case

Thanks

-Sta

----- Steven Cheng[MSFT] wrote: ----

Hi Stan


Have you viewed my last message or have you got any progress on this issue?
Please feel free to post here if you have any update or let me know if
you've resolve d the problem. Thanks


Regards

Steven Chen
Microsoft Online Suppor

Get Secure! www.microsoft.com/securit
(This posting is provided "AS IS", with no warranties, and confers no
rights.

Get Preview at ASP.NET whidbe
http://msdn.microsoft.com/asp.net/whidbey/default.asp
 
S

Steven Cheng[MSFT]

Hi Stan,

Thanks for your followup. As you mentioned the problem still remains, have
you tried remove those code which calls the ServiceComponent and see
whether there is any changes? I still think the servicedcomponents is the
potential cause of the problem. Anyway, since such problem may caused by
some unexpedted errors and need detailed troubleshooting, I do think it
better to open a case request focusing on it.


Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
 
G

Guest

RESOLUTIO
On computers running the following operating systems, you can turn on the special feature 4GT RAM Tuning
Microsoft Windows Server famil
Microsoft Windows XP Professional Editio
Microsoft Windows 2000 Datacenter Serve
Microsoft Windows 2000 Advanced Serve
Microsoft Windows NT 4.0 Enterprise Editio
The 4GT RAM Tuning feature permits each process to address up to 3 GB of virtual memory. To turn on this feature, add the /3GB switch to the Boot.ini file

For more information, visit the following Microsoft Web site:
http://msdn.microsoft.com/library/en-us/memory/base/4gt_ram_tuning.as
 
S

Scorpio3073

Hi Guys,

Has anyone had any luck diagnosing this problem. We are having the
same problem in a production environment. We are also limited in the
ability to diagnose/debug this as it is a live production server. The
problem does not exist in our QA or Development servers.

Our IIS box is Windows 2003 Server Standard Edition with 4 2.8Ghz Procs
& 2Gb of RAM.
Is everyone else having the problem on Win2k or Win2k3?

We usually get these Out of Memory Exceptions once a day after about 8
or 9 hours of usage on the web server. Our asp.net worker process
seems to generate the exception once it reaches about 1.3Gb. This also
seemed to occur only after an increased client load on this server.

Any help would be appreciated..

Craig Murray

RESOLUTION
Microsoft Windows Server family
Microsoft Windows XP Professional Edition
Microsoft Windows 2000 Datacenter Server
Microsoft Windows 2000 Advanced Server
Microsoft Windows NT 4.0 Enterprise Edition
The 4GT RAM Tuning feature permits each process to address up to 3 GB
of virtual memory. To turn on this feature, add the /3GB switch to the
Boot.ini file.
For more information, visit the following Microsoft Web site:
http://msdn.microsoft.com/library/en-us/memory/base/4gt_ram_tuning.asp
 
K

Ken Cox [Microsoft MVP]

Hi Craig,

This is the kind of issue that Microsoft could track down best through a
support call. They'll have you install some logging software and do some
tests to determine the source of the problem.

Perhaps you could post details of their fix if you go that route?

Ken

Scorpio3073 said:
Hi Guys,

Has anyone had any luck diagnosing this problem. We are having the
same problem in a production environment. We are also limited in the
ability to diagnose/debug this as it is a live production server. The
problem does not exist in our QA or Development servers.

Our IIS box is Windows 2003 Server Standard Edition with 4 2.8Ghz Procs
& 2Gb of RAM.
Is everyone else having the problem on Win2k or Win2k3?

We usually get these Out of Memory Exceptions once a day after about 8
or 9 hours of usage on the web server. Our asp.net worker process
seems to generate the exception once it reaches about 1.3Gb. This also
seemed to occur only after an increased client load on this server.

Any help would be appreciated..

Craig Murray
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,968
Messages
2,570,152
Members
46,697
Latest member
AugustNabo

Latest Threads

Top