Invoking IISREST based on a website state

Invoking IISREST based on a website state

am 07.09.2007 23:28:03 von walid

Hello:

Is there any way (maybe a vbscript) that would invoke an IISRESET based on a
result set? For example, the script would check a series of URLs, and if it
fails to get to a URL or receive an error such as ODBC error, it would then
reset IIS or an application pool?

We have several web sites that, from time to time, fail and require either
an IISREST or a restart of the application pool to fix it. Sometimes we get
paged in the middle of the nite just to perform that.

I would really appreciate if anyone would be able to help me with this.

Thank-you!

Walid

Re: Invoking IISREST based on a website state

am 08.09.2007 09:35:27 von David Wang

On Sep 7, 2:28 pm, Walid wrote:
> Hello:
>
> Is there any way (maybe a vbscript) that would invoke an IISRESET based on a
> result set? For example, the script would check a series of URLs, and if it
> fails to get to a URL or receive an error such as ODBC error, it would then
> reset IIS or an application pool?
>
> We have several web sites that, from time to time, fail and require either
> an IISREST or a restart of the application pool to fix it. Sometimes we get
> paged in the middle of the nite just to perform that.
>
> I would really appreciate if anyone would be able to help me with this.
>
> Thank-you!
>
> Walid


It sounds like those websites are buggy -- and their authors should
fix the code to improve reliability, instead of asking you to reboot
their website to "fix" their bug.

You may want to schedule their Application Pools to recycle more
frequently (if they are not running ASP.Net or managed code). For
example, make their websites recycle every 4-6 hours, or every 100
requests, or something like that.

Otherwise, someone will have to write script code to do what you
describe. It is definitely possible to do for IIS -- all the APIs to
do what you describe are publicly available and documented -- but
someone will have to figure out how to do it and write the code to do
it.


//David
http://w3-4u.blogspot.com
http://blogs.msdn.com/David.Wang
//