RE: Quick question on logging from HaProxy.

From: Lauro, John <jlauro#umflint.edu>
Date: Wed, 24 Oct 2007 09:43:37 -0400


Perhaps the problem is using UDP instead of sockets. UDP is unreliable compared to sockets and is another reason it would be nice if haproxy supported it. If you switch to sockets I am sure you will find you can log much more traffic more reliably.

I have one host that sometimes peeks in at tens of thousands of logs a second via syslog over a socket and never misses a beat. However, I cheat a little more than just using -, and have it log to /dev/shm (essentially a ram disk) and have a cron job that runs once a minute to rotate and then consolidate it...

> -----Original Message-----
> From: Willy Tarreau [mailto:w#1wt.eu]
> Sent: Wednesday, October 24, 2007 2:50 AM
> To: Lauro, John
> Cc: haproxy#formilux.org
> Subject: Re: Quick question on logging from HaProxy.
>
> On Wed, Oct 24, 2007 at 01:30:08AM -0400, Lauro, John wrote:
> >
> > > BTW Malcolm, be careful, the default syslogd from sysklogd
cannot
> > forward
> > > messages to a remote syslog server if it received them from a
UDP
> > socket.
> > > This is pretty annoying because syslogd is slow on disk and
cannot
> > forward.
> > > If you want to use this solution in your appliances, I strongly
> > suggest
> > > that you switch to another syslogd.
> > >
> >
> > syslogd isn't so bad if you prefix the busy log filename with a -.
By
> > default syslogd causes a fsync after every message, but as long as
you
> > let it buffer by using a - it's fairly efficient on disk.
>
> I know, but I never got it to log more than 300 lines/s without
randomly
> dropping some of them, and eating all the CPU. On some systems, I
need
> 10000 lines/s with very few CPU eaten.
>
> Regards,
> Willy
Received on 2007/10/24 15:43

This archive was generated by hypermail 2.2.0 : 2007/11/04 19:21 CET