plus d'infos sur les logs HAProxy

This commit is contained in:
Jérémy Lecour 2022-12-26 17:10:23 +01:00 committed by Jérémy Lecour
parent 9b7f37aa2c
commit 4e7de27d1c

View file

@ -689,6 +689,17 @@ HAProxy a des logs différents selon le type de connexion.
Pour les connexions TCP ([Voir la doc complète](http://docs.haproxy.org/2.0/configuration.html#8.2.2)) :
~~~
frontend fnt
mode tcp
option tcplog
log global
default_backend bck
backend bck
server srv1 127.0.0.1:8000
>>> Feb 6 12:12:56 localhost haproxy[14387]: 10.0.1.2:33313 [06/Feb/2009:12:12:51.443] fnt bck/srv1 0/0/5007 212 -- 0/0/0/0/3 0/0
Field Format Extract from the example above
1 process_name '[' pid ']:' haproxy[14387]:
2 client_ip ':' client_port 10.0.1.2:33313
@ -705,6 +716,17 @@ Pour les connexions TCP ([Voir la doc complète](http://docs.haproxy.org/2.0/con
Pour les connexions HTTP ([Voir la doc complète](http://docs.haproxy.org/2.0/configuration.html#8.2.3)) :.
~~~
frontend http-in
mode http
option httplog
log global
default_backend bck
backend static
server srv1 127.0.0.1:8000
>>> Feb 6 12:14:14 localhost haproxy[14389]: 10.0.1.2:33317 [06/Feb/2009:12:14:14.655] http-in static/srv1 10/0/30/69/109 200 2750 - - ---- 1/1/1/1/0 0/0 {1wt.eu} {} "GET /index.html HTTP/1.1"
Field Format Extract from the example above
1 process_name '[' pid ']:' haproxy[14389]:
2 client_ip ':' client_port 10.0.1.2:33317