473,394 Members | 1,750 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,394 software developers and data experts.

Exception of type System.OutOfMemoryException is thrown

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
Nov 18 '05 #1
11 19753
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" <no****@yahoo.com> wrote in message
news:63**********************************@microsof t.com...
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

Nov 18 '05 #2
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...chserverproces
ses.asp?frame=true

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

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

#Performance Counters for ASP.NET
http://msdn.microsoft.com/library/en...ormanceCounter
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

-------------------------------------------------------------------------

Nov 18 '05 #3
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 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

Nov 18 '05 #4
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
Nov 18 '05 #5
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


Nov 18 '05 #6
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 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

Nov 18 '05 #7
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
Nov 18 '05 #8
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

Nov 18 '05 #9
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..._ram_tuning.as
Nov 18 '05 #10
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
Spencer wrote:
RESOLUTION
On computers running the following operating systems, you can turn on the special feature 4GT RAM Tuning: 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...ram_tuning.asp

Nov 19 '05 #11
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" <vo***********@yahoo.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
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
Spencer wrote:
RESOLUTION
On computers running the following operating systems, you can turn on

the special feature 4GT RAM Tuning:
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...ram_tuning.asp


Nov 19 '05 #12

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

Similar topics

1
by: Ripul Handa | last post by:
Hi We are running IIS 5.0 cluster with cisco local director. We are running a website on 2 webservers and I have been observing that from past few days we have are getting this error message of...
1
by: SMG - Idealake | last post by:
Hi all, I am getting following error on my error, what could be the reason? Exception of type System.OutOfMemoryException was thrown. Description: An unhandled exception occurred during the...
5
by: karups | last post by:
Hi, There are several pages that occasionally start throwing System.OutOfMemoryException and "The type initializer for...
8
by: =?Utf-8?B?UGlnZ3k=?= | last post by:
Hi to all, I am getting this System.OutOfMemoryException calling the Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize(<stream>,<Obj>) method. The type of <streamis...
16
by: Lamont Sanford | last post by:
I can't figure out why once or twice per week, my C# server application throws OutOfMemoryExceptions. There is plenty of memory in the machine. As far as I can tell, when the exception is thrown,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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?
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.