Hey Shawn,

On 17 July 2018 at 19:59, Shawn Heisey <[email protected]> wrote:
[snip]
> Can haproxy be configured to create multiple logfiles?  Can the filename
> of each log be controlled easily in the haproxy config?  Can I use
> dynamic info for the logfile name like the value in the Host header?

Haproxy has absolutely nothing to do with the logfile creation! It
doesn't name them, rotate them or write into them.

That's *entirely* your local syslog daemon's responsibility -
configure it appropriately, and it'll do what you want.

Here's someone from 2011 doing exactly that:
https://tehlose.wordpress.com/2011/10/10/a-log-file-for-each-virtual-host-with-haproxy-and-rsyslog/

> The *format* of the haproxy logfile is fine as it is, except that I
> would like to have more than the 1024 bytes that syslog allows.

Read the haproxy docs on this - you want to tune the "length"
parameter: http://cbonte.github.io/haproxy-dconv/1.8/configuration.html#3.1-log

As the docs say: some syslog servers allow messages >1024, some don't.

Use one that does :-)

Cheers,
Jonathan

-- 
Jonathan Matthews
London, UK
http://www.jpluscplusm.com/contact.html

Reply via email to