[root@node01 ~]# vim /etc/rsyslog.conf
# Provides UDP syslog reception
$ModLoad imudp
$UDPServerRun 514
... ...
# Save haproxy messages also to haproxy.log
local2.* /var/log/haproxy.log
[root@node01 ~]# vim /etc/rsyslog.conf
[root@node01 ~]# systemctl restart rsyslog.service
Display all 261 possibilities? (y or n)
[root@node01 ~]# systemctl restart rsyslog.service
[root@node01 ~]# systemctl restart haproxy.service
[root@node01 ~]# cat /var/log/haproxy.log
Jan 14 13:13:04 localhost haproxy[17388]: Proxy stats started.
Haproxy 负载均衡高可用解决方案 -- haproxy日志配置
最新推荐文章于 2024-03-17 18:19:15 发布