HAProxy Enterprise Documentation 2.2r1
Logging Comments on Failure
Use the comment
directive to define a message that will be reported in the logs if the rule that follows the directive fails.
Define a message indicating a ping test has failed:
option tcp-check
tcp-check comment PING\ phase
tcp-check send PING\r\n
You can also include the comment
definition in connect
, send
, and expect
rules.
Define a message indicating a matching HTTP string was not received:
tcp-check expect rstring HTTP/1\..\ (2..|3..) comment check\ HTTP\ response
For complete details, see http-check comment.
Next up
Variables