Hello Luca,

Thanks for your solution. This pretty much took care of the problem. But I
noticed that on even 404 error apache is not showing 404 but it is showing
200 in access log. Is it correct?
On Jun 23, 2016 2:54 PM, "Luca Toscano" <toscano.l...@gmail.com> wrote:

> Hello!
>
> 2016-06-22 19:03 GMT+02:00 Manish Rangari <linuxtricksfordev...@gmail.com>
> :
>
>> Hello Guys,
>>
>>
>>
>>
>> down votefavorite
>> <http://stackoverflow.com/questions/37938692/redirect-apache-proxy-404-request-to-specific-page#>
>>
>>
>> I am trying to specify a page for 404 request but it is not working. Here
>> apache is acting as a reverse proxy which forwards the request to tomcat. I
>> am not using any virtual host configuration. Below is my configuration that
>> I am using
>>
>> <LocationMatch "^/(application|app)">
>>         ErrorDocument 404 /application/abc/def.htm
>> </LocationMatch>
>>
>> Apache is also hosting few php pages but /application and /app goes to
>> tomcat.
>>
>
> By default mod_proxy does not interfere with the response from the
> backend, passing it directly to the client. If you want to force mod-proxy
> to override error responses (like 40X, 50X) you'd need to set
> ProxyErrorOverride (
> https://httpd.apache.org/docs/current/mod/mod_proxy.html#proxyerroroverride
> ).
>
> Hope that helps!
>
> Luca
>
>
>

Reply via email to