Link to home
Start Free TrialLog in
Avatar of maximus_vj
maximus_vj

asked on

W3SVC Warning 1013 - Users sessions timeout

Hello,
I have a Windows 2003 Server running IIS 6.0 and serves an ASP application. But randomly the session times out for users using the ASP application. And I also observed that in the system log I get this warning:
Source : W3SVC
Event ID: 1013
"A process serving the application pool 'Default App Pool' exceeded time limits during shutdown. The process id was ...."

Are these two related. And why am I getting this warning. How do I fix it.

Thanks for your help.
maximus
Avatar of Dave_Dietz
Dave_Dietz
Flag of United States of America image

The two are not necessarily related but appear that they may be in this case.

The 1013 error is basically saying that the Application Pool needed to recycle for some reason and the W3WP.exe process didn't shut down gracefully.  This can be due to a long running request or hung threads (other possibilities but these are most common).

Do you have any of the health monitoring for the Application Pool set to recycle the pool?

Do you make any complicated SQL calls from you applications?

Are there any other entries in the Event Logs that may be related to IIS?

The only way to fix the issue is to figure out why your App Pool needs to recycle and fix the problem that is causing the w3wp to not shut down in a timely manner.

Dave Dietz
Avatar of maximus_vj
maximus_vj

ASKER

Thanks Dave.
These are the answers to your questions:
1) Do you have any of the health monitoring for the Application Pool set to recycle the pool?
For default application pool I have "Recycle Worker Process In 1740 minuites". But it recycles more frequently than that.

2)Do you make complicated SQL calls from your applications?
Yes

3) Are there any other entries in the Event Logs that may be related to IIS?
This is what I found in the application log:
Source:W3SVC-WP
Event ID:2262
Description:
ISAPI 'C:\WINDOWS\SYstem32\inetsrv\asp.dll' reported itself as unhealthy forteh following reason:'ASP unhealthy because 100% of executing requests are hung and 0% of the request queue is full.'
And I also observed that this will happen first and after this 1013 error regarding application pool will show up.
Any ideas?




Sounds like you've got a hang.

ASP sees that all of it's threads are stuck and asks for a recycle.  IIS tries to recycle but can't because the hung threads won't terminate so it has to kill the W3WP process serving the pool.

You'll need to troubleshoot this as a hang to determine what's causing the issue.....

Dave Dietz
Thanks Dave.
So you think ASP application is causing this hang up.
If I run iisstate utiltity does it help me track the culprit ASP pages or that utiltity will help only in diagnosing IIS issues?

maximus
IISState may help - its certainly worth a try.

I would be very curious what the ASP Requests Queued counter in Perfmon reads when you are seeing these errors.  If it is higher than 0 for any significant period of time I would almost be willing to lay money against it being an issue with ASP accessing your SQL Server.

Dave Dietz
Hi Dave,
Thanks again. I will log that counter and keep you posted.
Hello Dave,

That happened to me again. And this time I logged the ASP: Request Queue and Processor Time then the Request Queue was 28 for 45 minutes. And after that it shut down the process.
But the CPU utilization wasn't that high. So do you think it is the ASP that is causing the hang.

Thanks
maximus
Best guess is that you have long running or hung requests to your database from your ASP pages.  I have seen this a number of times in the past.

Might try checking your SQL logs for errors.  Also if you can make a hang dump of the problem available I would be happy to take a look at it.

Dave Dietz
Hi Dave,

Thanks for the reply. What program I have to use to do the hang dump. And one more thing is I changed soem of the ASP Pages (Long Running pages) and this time teh Requests Queued are 5 for 9 hrs.(Requests queued are down from 28 to 5).  During this time w3wp.exe process is utilizing 13% of the CPU all the time no change.

I checked SQL Logs with no luck.

Please let me know how I can do the hang dump.(utility)

Thanks
maximus
Download and install the IIS Crash/Hang Agent - http://www.microsoft.com/downloads/details.aspx?familyid=01c4f89d-cc68-42ba-98d2-0c580437efcf&displaylang=en

Either configure it to autodump for a hang or simply run IISDUMP.exe when you see the hang condition.

Dave Dietz
Hi Dave,

I installed the IIS Crash/Hang Agent on the development box. I have a few questions regarding that.

1) Is it OK to install it on the production box? What I observed on my DEV box is a process is running _IISCHAGent.exe and also in the IISCHAgent.ini file only the [crash Agent] is enabled to 1 and all other options are commented out. So after fixing this bug do we have to disable that and uninstall this debugging utility?
2) Do I have to use Crash Agent or Hang Agent?
As you can see my error is:
This is what I found in the application log:
Source:W3SVC-WP
Event ID:2262
Description:
ISAPI 'C:\WINDOWS\SYstem32\inetsrv\asp.dll' reported itself as unhealthy forteh following reason:'ASP unhealthy because 100% of executing requests are hung and 0% of the request queue is full.'

Which one will do the trick?
3) I am on Win2K3 Server and IIS 6.0 and wswp.exe runs on NETWORK SERVICE account for IISDUMP to work does this need to be in LOCAL SYSTEM account?

4) Or instead of doing all this, Can I just do this:
Install debugging tools and execute IISDUMP when the hang occurs?
If I have to do this what switches I should use so that you can get good information?

PS: I don't know how to give more points to you. Do you think I should post this in a new thread?

Thanks
maximus
ASKER CERTIFIED SOLUTION
Avatar of Dave_Dietz
Dave_Dietz
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi Dave,

Thanks again. I am planning to go with 4th option( IISDUMP when hang happens ).
One more question (this never ends):
When I install the debug tools by default it will be running as Crash Agaent. In the INI file Crash Agent is enabled. As I will be just using IISDUMP when hang happens can I just comment that out (Crash Agent) and then simply do IISDUMP when hang happens.

Thanks
maximus


Yes.  :-)

Dave Dietz
Hi Dave,
I got the Hang condition again and I ran IISDMUP . I got dump file but it is 84 MB. How can I send it to you so that you can take a look at it.

Thanks
maximus
Hi Dave,
You can access the dump file here.

http://doc.curriculummapper.com/tempdoc/Hang--6384_w3wp_DefaultAppPool.dmp

Let me know if you need other files also.

Thanks
maximus.