On 2020-10-26 13:57, Christopher Faulet wrote:
health-check log messages are emitted in the same way in 1.9 and 2.0.
And at first glance, the code responsible to set the syslog priority
is the same too. So there is probably something we missed. Could you
confirm you still have the same issue with the above configuration and
a netcat as syslog server ? If it works as expected, please share your
configuration, not only the global and defaults sections.

I cannot reproduce the issue with netcat, neither with simple configuration provided by you or our more complex test server config.

I've reconfigured rsyslog to log raw messages into different files suffixed with syslog facility name:

$ grep "proxy_upstream_ssl" haproxy-*
haproxy-daemon.log:<30>Oct 28 12:57:19 haproxy[13420]: [WARNING] 301/125719 (13424) : Health check for server proxy_upstream_ssl/ovh_sbg succeeded, reason: Layer7 check passed, code: 200, info: "OK", check duration: 30ms, status: 3/3 UP. haproxy-daemon.log:<30>Oct 28 12:57:20 haproxy[13420]: [WARNING] 301/125720 (13424) : Health check for server proxy_upstream_ssl/ovh_bhs succeeded, reason: Layer7 check passed, code: 200, info: "OK", check duration: 423ms, status: 3/3 UP. haproxy-local0.log:<133>Oct 28 12:57:19 haproxy[13420]: Proxy proxy_upstream_ssl started. haproxy-local0.log:<133>Oct 28 12:57:19 haproxy[13424]: Health check for server proxy_upstream_ssl/ovh_sbg succeeded, reason: Layer7 check passed, code: 200, info: "OK", check duration: 30ms, status: 3/3 UP. haproxy-local0.log:<133>Oct 28 12:57:20 haproxy[13424]: Health check for server proxy_upstream_ssl/ovh_bhs succeeded, reason: Layer7 check passed, code: 200, info: "OK", check duration: 423ms, status: 3/3 UP.

Meaning my initial assumption about all health check logs being emitted differently was wrong.

Strange that log line formats are also different. haproxy-daemon.log is emitted by master process running as user root (13420) and it duplicates health check log messages from it's subprocess running as user haproxy (13424), prepending severity name and subprocess pid. Between those is '301/125719' - I don't know what it is.

Another difference between 1.9 and 2.0 here is that 2.0 is compiled with systemd support and executed using -Ws and Type=notify instead of 1.9 -W and Type=forking.

global
  log /dev/log local0
  daemon
  nbproc 1
  nbthread 2

I wonder if systemd-journald is duplicating messages here.

Best regards,
Veiko

Reply via email to