views:

1397

answers:

6

When I access a wrong call to a sql server data into my application in classical ASP I get this message in my entire site: Service Unavailable. It stopped. My site is in a remote host. Don´t know what to do. What can I tell to the "support team" of them to fix that?

A: 

One reason you can get this is if the application pool has stopped.

Brian Adams
A: 

But how to fix that? Why an error from sql server, for example, writing the wrong name of a field, stops the application pool?

fhnaylor
probably an uncaught sql exception.
tvanfosson
Disable 'Rapid fail protection' in IIS
Cyril Gupta
A: 

Application pools can stop if they error. Usually after 5 errors in 5 minutes IIS shutsdown the AppPool. It is part of the Rapid-fail protection and it can be disabled for an AppPool otherwise the AppPool has to be restarted every time it happens.

These settings can be changed by the IIS administrator. It looks like you can setup a script to restart and app-pool so you should be able to set up a new web application (in a different app-pool) to restart your closed app-pool. Hoster might not like that though.

Best result for you would be to catch all the exceptions before they get out into IIS.

Brody
A: 

Could be a SQL exception in your Application_Start (or similar) method in Global.asx. If the application (ASP.NET worker process) can't start, it can't run, so the worker process has to shut down.

Robert Wagner
+1  A: 

If you check out Administration Tools/Event Viewer - Application log you will probably see an error message.

This should give you more information as too why the application pool died or why IIS died.

If you paste this into your question we should be able to narrow things down a bit.

JTew
Yeah I'd start at the event log 1st especially if recycling the AppPool fails to fix the issue.
stephbu
I'd disable Rapid fail protection while I investigated the error.
Cyril Gupta
+1  A: 

Hello,

Whenever there are a number of subsequent errors in your asp.net page, the application pool may shut down. There's a tolerance level, typically 5 errors in 10 mins, or so. Beyond this level, IIS will stop the service. I've run into a lot of problem due to this error.

What you can do is either fix all your websites (will take time), or increase the tolerance level or just disable the auto shutdown system. Here's how

Run IIS
Right click on the node 'Application Pools' in your left sidebar.
Click on the tab 'Health'
Remove the check on 'Enable Rapid Fail Protection'

or change the tolerance level.

Hope that helped.

Cyril Gupta