Re: auto reply 200 on stats URL just for logs

2011-07-12 Thread Willy Tarreau
On Tue, Jul 12, 2011 at 03:16:54PM +0200, Damien Hardy wrote: > I have done some tests. > The errorfile 503 directive on empty backend do the job from the client > point of view but to be very perfect I would like there is no 503 error code > in my haproxy logs. OK I see. You want something even u

Re: auto reply 200 on stats URL just for logs

2011-07-12 Thread Damien Hardy
2011/7/12 Willy Tarreau > On Tue, Jul 12, 2011 at 10:42:31AM +0200, Damien Hardy wrote: > > 2011/7/12 Willy Tarreau > > > > > > > > Then you can use the errorfile method : you send your request to a > > > backend without any server (which will produce an error 503) and you > > > use "errorfile 5

Re: auto reply 200 on stats URL just for logs

2011-07-12 Thread Willy Tarreau
On Tue, Jul 12, 2011 at 10:42:31AM +0200, Damien Hardy wrote: > 2011/7/12 Willy Tarreau > > > > > Then you can use the errorfile method : you send your request to a > > backend without any server (which will produce an error 503) and you > > use "errorfile 503 /path/to/file" to return this file i

Re: auto reply 200 on stats URL just for logs

2011-07-12 Thread Damien Hardy
2011/7/12 Willy Tarreau > > Then you can use the errorfile method : you send your request to a > backend without any server (which will produce an error 503) and you > use "errorfile 503 /path/to/file" to return this file instead of the > error 503. Some people use this to serve a few static file

Re: auto reply 200 on stats URL just for logs

2011-07-12 Thread Willy Tarreau
On Tue, Jul 12, 2011 at 08:56:12AM +0200, Damien Hardy wrote: > >frontend XXX > >mode http > >monitor-uri /test > > > > All checks to /test will return a 200 OK. Its used so that haproxy can be > > tested by other components (eg: keepalived). > > > > Regards, > > Willy > > >

Re: auto reply 200 on stats URL just for logs

2011-07-11 Thread Damien Hardy
Le 11/07/2011 22:07, Willy Tarreau a écrit : > On Mon, Jul 11, 2011 at 02:20:37PM +0200, Damien Hardy wrote: >> Whatever method is used, I want that haproxy never ask to any backend an >> answer directly to client and log the request like others > > Then define a "monitor-uri", it's done for that.

Re: auto reply 200 on stats URL just for logs

2011-07-11 Thread Willy Tarreau
On Mon, Jul 11, 2011 at 02:20:37PM +0200, Damien Hardy wrote: > Whatever method is used, I want that haproxy never ask to any backend an > answer directly to client and log the request like others Then define a "monitor-uri", it's done for that. Example : frontend XXX mode http

Re: auto reply 200 on stats URL just for logs

2011-07-11 Thread Damien Hardy
Whatever method is used, I want that haproxy never ask to any backend an answer directly to client and log the request like others best regards, -- Damien 2011/7/11 Baptiste > hi, > > There is a HTTP method for that: HEAD. > > cheers > > On Mon, Jul 11, 2011 at 11:21 AM, Damien Hardy > wrot

Re: auto reply 200 on stats URL just for logs

2011-07-11 Thread Baptiste
hi, There is a HTTP method for that: HEAD. cheers On Mon, Jul 11, 2011 at 11:21 AM, Damien Hardy wrote: > I have to precise that this is not related to the "stats" delivered by > haproxy but a static resource used on our pages to get counters based on > access logs provide by haproxy. > > 2011/

Re: auto reply 200 on stats URL just for logs

2011-07-11 Thread Damien Hardy
I have to precise that this is not related to the "stats" delivered by haproxy but a static resource used on our pages to get counters based on access logs provide by haproxy. 2011/7/11 Damien Hardy > Hello, > > I want haproxy to reply 200 with no data on a predefined URL without going > through

auto reply 200 on stats URL just for logs

2011-07-11 Thread Damien Hardy
Hello, I want haproxy to reply 200 with no data on a predefined URL without going through backends just for getting logs with referrer for our stats platform. Is there a way to do that with haproxy directives (redirect with code 200 maybe) ? Best regards, -- Damien