On Thu, 23 Sep 2010, Guido Krause wrote:
Hello,
we use haproxy 1.3.22 an when a server goes down I see
in the log:
Aug 19 09:02:54 lbA haproxy[14478]: Server
webA/webA is DOWN. 1 active and 0 backup servers left.
0 sessions active, 0 requeued, 0 remaining in queue.
now we test the 1.4.8 and if a server goes down I see in the log:
Sep 21 17:41:19 lbB haproxy[27434]: Server webA/webA is DOWN, reason: Layer7 wrong
status, code: 503, info: "Service Unavailable", check duration: 106ms
why i cone not see -> 1 active and 0 backup servers left?
Please test the attached patch. It should restore the old behavior.
Best regards,
Krzysztof Olędzki
From 5b88610452727542b9cab6315570feb13e54f644 Mon Sep 17 00:00:00 2001
From: Krzysztof Piotr Oledzki <o...@ans.pl>
Date: Mon, 27 Sep 2010 13:10:50 +0200
Subject: [BUG] Restore info about available active/backup servers
Bug introduced by 5f5b7d2c1db1fabe3d372b0080a8773147762ee7
---
src/checks.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/checks.c b/src/checks.c
index d326625..ef7839b 100644
--- a/src/checks.c
+++ b/src/checks.c
@@ -170,7 +170,7 @@ static void server_status_printf(struct chunk *msg, struct
server *s, unsigned o
chunk_printf(msg, ", check duration: %ldms",
s->check_duration);
}
- if (xferred > 0) {
+ if (xferred >= 0) {
if (!(s->state & SRV_RUNNING))
chunk_printf(msg, ". %d active and %d backup servers
left.%s"
" %d sessions active, %d requeued, %d remaining
in queue",
--
1.6.4.2