haproxy开启日志 vi /etc/haproxy/haproxy.cfg #添加配置 global log 127.0.0.1 local2 info defaults mode http log global #开启日志功能 systemctl restart haproxy.service #修改日志 vi /etc/rsyslog.conf #去掉注释 # Provides UDP syslog reception $ModLoad imudp $UDPServerRun 514 #添加日志路径 local2.* /var/log/haproxy.log systemctl restart rsyslog.service #查看日志 [root@manager log]# tail -100f /var/log/harpox.log May 9 17:39:26 localhost haproxy[32484]: Connect from 100.98.100.186:60128 to 100.98.100.186:5000 (main/HTTP)
标签:haproxy,log,vi,global,开启,日志 From: https://www.cnblogs.com/wukc/p/17387241.html