On Thu, 24 Sep 2009, Willy Tarreau wrote:
Hi Krzysztof,
On Thu, Sep 24, 2009 at 08:54:36PM +0200, Krzysztof Piotr Oledzki wrote:
From e6f4aeafe8a7f547679d80a65892315f8f5cf047 Mon Sep 17 00:00:00 2001
From: Krzysztof Piotr Oledzki <o...@ans.pl>
Date: Thu, 24 Sep 2009 20:48:34 +0200
Subject: [MEDIUM] Health check reporting code rework + health logging
This patch adds health logging so it possible to check what
was happening before a crash. Failed healt checks are logged if
server is UP and succeeded healt checks if server is DOWN,
so the ammountof additional information is limited.
That's an interesting feature.
Thanks.
I've quickly tested it and I think one information is missing : the up
or down count (1/3, ...). For instance, I have this :
Sep 24 23:04:32 localhost haproxy[24369]: Health check for server
Thousand_HTTP/127.0.0.001 failed, reason: Layer4 connection problem, check
duration: 0ms.
Sep 24 23:04:33 localhost haproxy[24369]: Health check for server
Thousand_HTTP/127.0.0.001 failed, reason: Layer4 connection problem, check
duration: 0ms.
Sep 24 23:04:33 localhost haproxy[24369]: Server Thousand_HTTP/127.0.0.001 is
DOWN. 8 active and 0 backup servers left. 0 sessions active, 0 requeued, 0
remaining in queue.
There is no way to know if the log above contains a dup or
indicates two lost checks. This would be especially true for high
traffic sites where checks account for about 1/1000 to 1/10000 of
the traffic, and where log losses are common.
Good idea. Sure, I'll add this.
I've seen that you have maintained the LOG_NOTICE level, which is
fine because many setups use the log level to split between traffic
and UP/Downs.
OK.
One humble query though. You seem to have difficulties typing
"health" in doc and comments without eating letters ;-) I can't
blame you, I can't type "health-check" at once either ;-)
My bad, I make to many mistakes, I know. I should have check my patches
with ispell or at least read them more carefully. ;) I'll do my best next
time.
Best regards,
Krzysztof Olędzki