• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 9773
  • Last Modified:

An unhandled win32 exception occurred in w3wp.exe IIS Worker Process Stopped working

Server 2008 Standard x64 SP2
sqlserver 2008 X64
.net framework 3.5
IIS7

server console offten show error. it's a .net website(www.51yunli.com) error.
The error happen several times a day. but sometimes it happend more than 10 times in one hour.

when error happen this website app pool will be rebooted.
mostly w3wp.exe cost about 700M memory, peak memory cost about 1.2G

An unhandled win32 exception occurred in w3wp.exe

eventlog
event 1023,.NET Runtime
NET Runtime version 2.0.50727.4206 -

sometimes it will comes with another error
IIS Worker Process Stopped working

eventlog
event 1000, Application Error

Faulting application w3wp.exe, version 7.0.6002.18005, time stamp 0x49e03238, faulting module ntdll.dll, version 6.0.6002.18327, time stamp 0x4cb74dd3,exception code 0xc0000374, fault offset 0x00000000000aca57, , process id ID 0x92c, application start time 0x01cbe96d30f53290.

Windows Error Reporting

Problem signature:
Problem Event Name:      APPCRASH
Application Name:      w3wp.exe
Application Version:      7.0.6002.18005
Application Timestamp:      49e03238
Fault Module Name:      StackHash_b36f
Fault Module Version:      6.0.6002.18327
Fault Module Timestamp:      4cb74dd3
Exception Code:      c0000374
Exception Offset:      00000000000aca57
OS Version:      6.0.6002.2.2.0.274.10
Locale ID:      2052

other .net(.net+mssql) and PHP website(PHP5.2.5+mysql) on the server works ok

already tried 4 solutions, but it doesn't work.

tried solution1
IIS Manager > DefautAppPool > Advanced Settings
and change:
Process Model > Identity
from:
NetworkService
to:
SpecificUser

tried solution2
recycle time is set to the default every 1740 minutes.
Idle timeout is set to '0'
Disable Overlapped Recycle is set to 'True'

tried solution3
config FastCgi

tried solution4
http://support.microsoft.com/kb/913384 
but it would not install on windows 2008 64bit
0
yzhou_cn
Asked:
yzhou_cn
  • 3
  • 2
1 Solution
 
RovastarCommented:
None of your solutions you stated are tackling the problem.

You have a memory leak in your application you will need to look at the code to remove this leak.

Your 'solutions' you suggested are just messy workarounds that might make the situation a little better but will not tackle the root cause of the problem.

It is difficult to know what to recommend to help here other than debugging your code.
0
 
yzhou_cnAuthor Commented:
any advice to debug the memory leak? thanks
0
 
yzhou_cnAuthor Commented:
the issue "An unhandled win32 exception occurred in w3wp.exe" was fixed by following solution.

SqlConnection Do not use global or static. otherwise it will share the connection of different process . the solution is to to use the new connection. and close it  after use.
the issue was fixed  after  using new connection in sqlhelp.cs
0
 
yzhou_cnAuthor Commented:
the issue was fixed  after  using new connection in sqlhelp.cs
0
 
RovastarCommented:
So I was correct I was code not an IIS issue.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

What Kind of Coding Program is Right for You?

There are many ways to learn to code these days. From coding bootcamps like Flatiron School to online courses to totally free beginner resources. The best way to learn to code depends on many factors, but the most important one is you. See what course is best for you.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now