Thanks for the replies... I guess that can't be done then, but after
thinking a bit, I think that I am probably looking for the scenario where a
service is down on a server, rather than the server itself. Let's assume
that I get the following response when the service is down: HTTP/1.1 404 Not
Found

Is there a way with apache rewrite module to redirect the page based on this
response? So for example, something as follows: If the response code is 404,
then redirect to custommessage.html, where I put my custom error message in
custommessage.html?


On Mon, Jul 6, 2009 at 10:41 AM, hugh williams <hu...@soco.agilent.com>wrote:

> Assuming your definition of "down" is "not responding", there is no way for
> the server to respond with any kind of status code. Your customer's browsers
> will generally give them a message of some kind that it couldn't contact the
> server , however as the web administrator you have no visibility or control
> over that in any way - if your server is down, you won't get the requests.
>
> You could also investigate a server farm, or clustering, or load balancing,
> or any number of other ways to keep your web site visible, but they are all
> more complicated; there is no way to reply "I'm dead, sorry" from a single
> instance of Apache.
>
> hugh
>
> Chintan Kachhi wrote:
>
>> I have installed apache http server version 2.2 on my local machine. I am
>> trying to write an apache rewrite module for the case when the apache server
>> is down. When the server is down, I need to redirect to a custom error page.
>> Does anyone know how can I apply this condition. So for starters, how can I
>> know if the server is down? Is there a status code that is returned when the
>> server is down while I am trying to hit it, and if so, how do I see that
>> http status code that is returned?
>>
>
> --
> Hugh Williams                  "There are two things to aim for in life;
> hugh_willi...@agilent.com       first, to get what you want; and after
> that,
> Agilent Technologies            to enjoy it.  Only the wisest of mankind
> Santa Rosa 3US                  achieve the second."
> (707)-577-4941                         - Logan Pearsall Smith, 1931
>
>
>
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
>  "   from the digest: users-digest-unsubscr...@httpd.apache.org
> For additional commands, e-mail: users-h...@httpd.apache.org
>
>

Reply via email to