Discussion:
Need to understand logs
Rajesh Kolli
2017-09-07 06:15:32 UTC
Permalink
Hello,

I am using HAProxy community version from a month, i need to understand
logs of HAProxy for the i need your help.

Here is a sample of my logs:
Sep 6 17:03:31 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4 check
passed, check duration: 0ms, status: 1/2 DOWN.
Sep 6 17:03:33 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4 check
passed, check duration: 0ms, status: 3/3 UP.
Sep 6 17:03:33 localhost haproxy[19389]: Server
Netrovert-sites/DS-11-81-R7-CLST-Node2 is UP. 2 active and 0 backup servers
online. 0 sessions requeued, 0 total in queue.

Here my doubts are, in first line health check is 1/2 DOWN and 2nd line it
is 3/3 UP, in both cases Layer4 check passed. How to understand it? what
exactly it is checking? what are these 1/2 & 1/3's?

Finally, is there any document to understand its logging?
--
*Thanks & RegardsRajesh Kolli*
Rajesh Kolli
2017-09-08 06:52:00 UTC
Permalink
Hi Aleksandar,

Thank you for your response. Yes, I am using "Log-health-checks" in my configuration and here is my HAProxy version information.

[***@DS-11-82-R7-CLST-Node1 ~]# haproxy -vv
HA-Proxy version 1.7.8 2017/07/07
Copyright 2000-2017 Willy Tarreau <***@haproxy.org>

Build options :
TARGET = linux2628
CPU = generic
CC = gcc
CFLAGS = -O2 -g -fno-strict-aliasing -Wdeclaration-after-statement -fwrapv
OPTIONS =

Default settings :
maxconn = 2000, bufsize = 16384, maxrewrite = 1024, maxpollevents = 200


Thanks & Regards
Rajesh Kolli

-----Original Message-----
From: Aleksandar Lazic [mailto:al-***@none.at]
Sent: Thursday, September 07, 2017 10:08 PM
To: Rajesh Kolli; ***@formilux.org
Subject: Re: Need to understand logs

Hi Rajesh.
Post by Rajesh Kolli
Hello,
I am using HAProxy community version from a month, i need to
understand logs of HAProxy for the i need your help.
Sep 6 17:03:31 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4 check
passed, check duration: 0ms, status: 1/2 DOWN.
Sep 6 17:03:33 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4 check
passed, check duration: 0ms, status: 3/3 UP.
Sep 6 17:03:33 localhost haproxy[19389]: Server
Netrovert-sites/DS-11-81-R7-CLST-Node2 is UP. 2 active and 0 backup
servers online. 0 sessions requeued, 0 total in queue.
Here my doubts are, in first line health check is 1/2 DOWN and 2nd
line it is 3/3 UP, in both cases Layer4 check passed. How to
understand it? what exactly it is checking? what are these 1/2 & 1/3's?
Finally, is there any document to understand its logging?
There is a logging part in the doc but I haven't seen such entries in the document.

http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#8

Maybe you have activated
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#4.2-option%20log-health-checks
in your config.


It would be nice to know which haproxy version you use.

haproxy -vv

--
Best Regards
Aleks
https://www.me2digital.com/
Rajesh Kolli
2017-09-11 08:32:01 UTC
Permalink
Hi Aleksandar,

Thank you for clarifying about "Layer 4" checks.

I am interested in knowing the values of these %d/%d, %s in line 319. Why it
is taking only 1/2, 1/3... values? What they are representing?

319 "chunk_appendf(&trash, ", status: %d/%d %s",
320 (check->health >= check->rise) ?
check->health - check->rise + 1 : check->health,
321 (check->health >= check->rise) ?
check->fall : check->rise,
322 (check->health >= check->rise) ?
(s->uweight ? "UP" : "DRAIN") : "DOWN");
323

Thanks & Regards
Rajesh Kolli

-----Original Message-----
From: Aleksandar Lazic [mailto:al-***@none.at]
Sent: Sunday, September 10, 2017 9:37 PM
To: Rajesh Kolli; ***@formilux.org
Subject: Re: Need to understand logs

Hi Rajesh.
Post by Rajesh Kolli
Hi Aleksandar,
Thank you for your response. Yes, I am using "Log-health-checks" in my
configuration and here is my HAProxy version information.
Thanks.

sorry to say that but for know you can only take a look into the source for
documenation.

http://git.haproxy.org/?p=haproxy-1.7.git&a=search&h=HEAD&st=grep&s=PR_O2_LO
GHCHKS

for example.

http://git.haproxy.org/?p=haproxy-1.7.git;a=blob;f=src/checks.c;hb=640d526f8
cdad00f7f5043b51f6a34f3f6ebb49f#l307

We are open for patches also for documentation to add this part to the docs
;-)

To answer your question below I think layer 4 checks are 'only' tcp checks
which sometimes are answered by some os when a service is listen on the
specific port.

This does not means that the App works properly.

I'm open for any correction when my assumption is wrong.

Regards
Aleks
Post by Rajesh Kolli
TARGET = linux2628
CPU = generic
CC = gcc
CFLAGS = -O2 -g -fno-strict-aliasing -Wdeclaration-after-statement -fwrapv
OPTIONS =
maxconn = 2000, bufsize = 16384, maxrewrite = 1024, maxpollevents = 200
Thanks & Regards
Rajesh Kolli
-----Original Message-----
Sent: Thursday, September 07, 2017 10:08 PM
Subject: Re: Need to understand logs
Hi Rajesh.
Post by Rajesh Kolli
Hello,
I am using HAProxy community version from a month, i need to
understand logs of HAProxy for the i need your help.
Sep 6 17:03:31 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 1/2 DOWN.
Sep 6 17:03:33 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 3/3 UP.
Sep 6 17:03:33 localhost haproxy[19389]: Server
Netrovert-sites/DS-11-81-R7-CLST-Node2 is UP. 2 active and 0 backup
servers online. 0 sessions requeued, 0 total in queue.
Here my doubts are, in first line health check is 1/2 DOWN and 2nd
line it is 3/3 UP, in both cases Layer4 check passed. How to
understand it? what exactly it is checking? what are these 1/2 & 1/3's?
Finally, is there any document to understand its logging?
There is a logging part in the doc but I haven't seen such entries in the document.
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#8
Maybe you have activated
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#4.2-optio
n%20log-health-checks
in your config.
It would be nice to know which haproxy version you use.
haproxy -vv
--
Best Regards
Aleks
https://www.me2digital.com/
--
Best Regards
Aleks
PiBa-NL
2017-09-11 11:36:22 UTC
Permalink
Hi Rajesh, Aleksander,
Post by Rajesh Kolli
Hi Aleksandar,
Thank you for clarifying about "Layer 4" checks.
I am interested in knowing the values of these %d/%d, %s in line 319. Why it
is taking only 1/2, 1/3... values? What they are representing?
Have you seen rise & fall in the documentation?
http://cbonte.github.io/haproxy-dconv/1.8/snapshot/configuration.html#rise
http://cbonte.github.io/haproxy-dconv/1.8/snapshot/configuration.html#5.2-fall
Basically it takes by default 3 consecutive failed checks to mark a
server down, and 2 passed checks to get it back up.
So 1/3 is 1 failed check but server status is still 'up'.
Then 2/3 failed check, but still marked up.
At 3/3 the server would be marked down, and removed from the backend pool.
Then after a while when the webserver is working again the following
will happen.
After the first successful 1/2 check the server is still marked 'down'.
And on the second 2/2 successful check it will be marked 'up' and is
added back into the backend server pool to take requests.
Post by Rajesh Kolli
319 "chunk_appendf(&trash, ", status: %d/%d %s",
320 (check->health >= check->rise) ?
check->health - check->rise + 1 : check->health,
321 (check->health >= check->rise) ?
check->fall : check->rise,
322 (check->health >= check->rise) ?
(s->uweight ? "UP" : "DRAIN") : "DOWN");
323
Thanks & Regards
Rajesh Kolli
-----Original Message-----
Sent: Sunday, September 10, 2017 9:37 PM
Subject: Re: Need to understand logs
Hi Rajesh.
Post by Rajesh Kolli
Hi Aleksandar,
Thank you for your response. Yes, I am using "Log-health-checks" in my
configuration and here is my HAProxy version information.
Thanks.
sorry to say that but for know you can only take a look into the source for
documenation.
http://git.haproxy.org/?p=haproxy-1.7.git&a=search&h=HEAD&st=grep&s=PR_O2_LO
GHCHKS
for example.
http://git.haproxy.org/?p=haproxy-1.7.git;a=blob;f=src/checks.c;hb=640d526f8
cdad00f7f5043b51f6a34f3f6ebb49f#l307
We are open for patches also for documentation to add this part to the docs
;-)
To answer your question below I think layer 4 checks are 'only' tcp checks
which sometimes are answered by some os when a service is listen on the
specific port.
This does not means that the App works properly.
I'm open for any correction when my assumption is wrong.
Regards
Aleks
Post by Rajesh Kolli
TARGET = linux2628
CPU = generic
CC = gcc
CFLAGS = -O2 -g -fno-strict-aliasing -Wdeclaration-after-statement
-fwrapv
Post by Rajesh Kolli
OPTIONS =
maxconn = 2000, bufsize = 16384, maxrewrite = 1024, maxpollevents = 200
Thanks & Regards
Rajesh Kolli
-----Original Message-----
Sent: Thursday, September 07, 2017 10:08 PM
Subject: Re: Need to understand logs
Hi Rajesh.
Post by Rajesh Kolli
Hello,
I am using HAProxy community version from a month, i need to
understand logs of HAProxy for the i need your help.
Sep 6 17:03:31 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 1/2 DOWN.
Sep 6 17:03:33 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 3/3 UP.
Sep 6 17:03:33 localhost haproxy[19389]: Server
Netrovert-sites/DS-11-81-R7-CLST-Node2 is UP. 2 active and 0 backup
servers online. 0 sessions requeued, 0 total in queue.
Here my doubts are, in first line health check is 1/2 DOWN and 2nd
line it is 3/3 UP, in both cases Layer4 check passed. How to
understand it? what exactly it is checking? what are these 1/2 & 1/3's?
Finally, is there any document to understand its logging?
There is a logging part in the doc but I haven't seen such entries in the
document.
Post by Rajesh Kolli
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#8
Maybe you have activated
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#4.2-optio
n%20log-health-checks
in your config.
It would be nice to know which haproxy version you use.
haproxy -vv
--
Best Regards
Aleks
https://www.me2digital.com/
--
Best Regards
Aleks
Regards,

PiBa-NL
Rajesh Kolli
2017-09-11 11:56:49 UTC
Permalink
Hi PiBa,

Thank you for clarifying my doubt, this is what I am expecting. My doubt is cleared.

Thanks to all of you for spending time for me.

Thanks & Regards
Rajesh Kolli

-----Original Message-----
From: PiBa-NL [mailto:***@gmail.com]
Sent: Monday, September 11, 2017 5:06 PM
To: Rajesh Kolli; 'Aleksandar Lazic'
Cc: ***@formilux.org
Subject: Re: Need to understand logs

Hi Rajesh, Aleksander,
Post by Rajesh Kolli
Hi Aleksandar,
Thank you for clarifying about "Layer 4" checks.
I am interested in knowing the values of these %d/%d, %s in line 319.
Why it is taking only 1/2, 1/3... values? What they are representing?
Have you seen rise & fall in the documentation?
http://cbonte.github.io/haproxy-dconv/1.8/snapshot/configuration.html#rise
http://cbonte.github.io/haproxy-dconv/1.8/snapshot/configuration.html#5.2-fall
Basically it takes by default 3 consecutive failed checks to mark a server down, and 2 passed checks to get it back up.
So 1/3 is 1 failed check but server status is still 'up'.
Then 2/3 failed check, but still marked up.
At 3/3 the server would be marked down, and removed from the backend pool.
Then after a while when the webserver is working again the following will happen.
After the first successful 1/2 check the server is still marked 'down'.
And on the second 2/2 successful check it will be marked 'up' and is added back into the backend server pool to take requests.
Post by Rajesh Kolli
319 "chunk_appendf(&trash, ", status: %d/%d %s",
320 (check->health >= check->rise) ?
check->health - check->rise + 1 : check->health,
321 (check->health >= check->rise) ?
check->fall : check->rise,
322 (check->health >= check->rise) ?
(s->uweight ? "UP" : "DRAIN") : "DOWN");
323
Thanks & Regards
Rajesh Kolli
-----Original Message-----
Sent: Sunday, September 10, 2017 9:37 PM
Subject: Re: Need to understand logs
Hi Rajesh.
Post by Rajesh Kolli
Hi Aleksandar,
Thank you for your response. Yes, I am using "Log-health-checks" in
my configuration and here is my HAProxy version information.
Thanks.
sorry to say that but for know you can only take a look into the
source for documenation.
http://git.haproxy.org/?p=haproxy-1.7.git&a=search&h=HEAD&st=grep&s=PR
_O2_LO
GHCHKS
for example.
http://git.haproxy.org/?p=haproxy-1.7.git;a=blob;f=src/checks.c;hb=640
d526f8
cdad00f7f5043b51f6a34f3f6ebb49f#l307
We are open for patches also for documentation to add this part to the docs
;-)
To answer your question below I think layer 4 checks are 'only' tcp
checks which sometimes are answered by some os when a service is
listen on the specific port.
This does not means that the App works properly.
I'm open for any correction when my assumption is wrong.
Regards
Aleks
Post by Rajesh Kolli
TARGET = linux2628
CPU = generic
CC = gcc
CFLAGS = -O2 -g -fno-strict-aliasing
-Wdeclaration-after-statement
-fwrapv
Post by Rajesh Kolli
OPTIONS =
maxconn = 2000, bufsize = 16384, maxrewrite = 1024, maxpollevents
=
200
Thanks & Regards
Rajesh Kolli
-----Original Message-----
Sent: Thursday, September 07, 2017 10:08 PM
Subject: Re: Need to understand logs
Hi Rajesh.
Post by Rajesh Kolli
Hello,
I am using HAProxy community version from a month, i need to
understand logs of HAProxy for the i need your help.
Sep 6 17:03:31 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 1/2 DOWN.
Sep 6 17:03:33 localhost haproxy[19389]: Health check for server
Netrovert-sites/DS-11-81-R7-CLST-Node2 succeeded, reason: Layer4
check passed, check duration: 0ms, status: 3/3 UP.
Sep 6 17:03:33 localhost haproxy[19389]: Server
Netrovert-sites/DS-11-81-R7-CLST-Node2 is UP. 2 active and 0 backup
servers online. 0 sessions requeued, 0 total in queue.
Here my doubts are, in first line health check is 1/2 DOWN and 2nd
line it is 3/3 UP, in both cases Layer4 check passed. How to
understand it? what exactly it is checking? what are these 1/2 & 1/3's?
Finally, is there any document to understand its logging?
There is a logging part in the doc but I haven't seen such entries in the
document.
Post by Rajesh Kolli
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#8
Maybe you have activated
http://cbonte.github.io/haproxy-dconv/1.7/configuration.html#4.2-opti
o
n%20log-health-checks
in your config.
It would be nice to know which haproxy version you use.
haproxy -vv
--
Best Regards
Aleks
https://www.me2digital.com/
--
Best Regards
Aleks
Regards,

PiBa-NL

Loading...