LINUXOR.SK ... open source notes ...

Vault - logrotate.d/haproxy (connection log)

category: solutionz · date: 2024-12-31 · updated: 2026-10-02 · author: LALA

Vault Solution · Config document · referenced from Load balancer, Audit logging and log shipping

Rotation of the HAProxy connection log on the load-balancer nodes. After rotating, it tells rsyslog to reopen the file.

ItemValue
Path on the host/etc/logrotate.d/haproxy
Deployed onboth load-balancer nodes of every cluster
Rotates/var/log/haproxy.log

The file

nginx
/var/log/haproxy.log {
    missingok
    notifempty
    sharedscripts
    postrotate
        /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
        /bin/kill -HUP `cat /var/run/rsyslogd.pid 2> /dev/null` 2> /dev/null || true
    endscript
}
← solutionz