From e060284c4c58549e6a0532cb56d5854f09b6c51e Mon Sep 17 00:00:00 2001 From: DeDe Morton Date: Wed, 14 Dec 2016 12:46:53 -0800 Subject: [PATCH 1/2] Edit haproxy module docs --- metricbeat/_meta/beat.full.yml | 2 +- metricbeat/docs/fields.asciidoc | 159 +++++++++--------- metricbeat/docs/modules/haproxy.asciidoc | 12 +- metricbeat/docs/modules_list.asciidoc | 2 +- metricbeat/metricbeat.full.yml | 2 +- metricbeat/module/haproxy/_meta/docs.asciidoc | 10 +- metricbeat/module/haproxy/_meta/fields.yml | 6 +- .../module/haproxy/info/_meta/docs.asciidoc | 4 +- .../module/haproxy/info/_meta/fields.yml | 26 +-- .../module/haproxy/stat/_meta/docs.asciidoc | 134 +-------------- .../module/haproxy/stat/_meta/fields.yml | 152 +++++++++-------- 11 files changed, 197 insertions(+), 312 deletions(-) diff --git a/metricbeat/_meta/beat.full.yml b/metricbeat/_meta/beat.full.yml index 61540ce5f20b..4f970f2db258 100644 --- a/metricbeat/_meta/beat.full.yml +++ b/metricbeat/_meta/beat.full.yml @@ -80,7 +80,7 @@ metricbeat.modules: #certificate: "/etc/pki/client/cert.pem" #key: "/etc/pki/client/cert.key" -#------------------------------- haproxy Module ------------------------------ +#------------------------------- HAProxy Module ------------------------------ #- module: haproxy #metricsets: ["info", "stat"] #enabled: true diff --git a/metricbeat/docs/fields.asciidoc b/metricbeat/docs/fields.asciidoc index d025cacf4509..6b0c03e4fa02 100644 --- a/metricbeat/docs/fields.asciidoc +++ b/metricbeat/docs/fields.asciidoc @@ -944,24 +944,24 @@ Total number of outgoing packets. [[exported-fields-haproxy]] -== haproxy Fields +== HAProxy Fields experimental[] -haproxy Module +HAProxy Module [float] == haproxy Fields -HAProx metrics. +HAProxy metrics. [float] == info Fields -General infomration collected on HAProxy process +General information about HAProxy processes. @@ -970,7 +970,7 @@ General infomration collected on HAProxy process type: long -Number of processes +Number of processes. [float] @@ -978,7 +978,7 @@ Number of processes type: long -Process number +Process number. [float] @@ -986,7 +986,7 @@ Process number type: long -Process ID +Process ID. [float] @@ -1008,7 +1008,7 @@ type: long type: long -Current uptime in seconds +Current uptime in seconds. [float] @@ -1018,7 +1018,7 @@ type: long format: bytes -Max number of memory usage in bytes (The 'Memmax_MB' value converted to bytes) +Maximum amount of memory usage in bytes (the 'Memmax_MB' value converted to bytes). [float] @@ -1026,7 +1026,7 @@ Max number of memory usage in bytes (The 'Memmax_MB' value converted to bytes) type: long -Max number of open files for process +Maximum number of open files for the process. [float] @@ -1100,7 +1100,7 @@ type: long type: long -Current Connections +Current connections. [float] @@ -1108,7 +1108,7 @@ Current Connections type: long -Total Connections +Total connections. [float] @@ -1116,7 +1116,7 @@ Total Connections type: long -Current ssl Connections +Current SSL connections. [float] @@ -1124,7 +1124,7 @@ Current ssl Connections type: long -Current Connections +Total SSL connections. [float] @@ -1132,7 +1132,7 @@ Current Connections type: long -Current Connections +Maximum SSL connections. [float] @@ -1140,7 +1140,7 @@ Current Connections type: long -Max connections +Maximum connections. [float] @@ -1347,7 +1347,7 @@ format: percent [float] == stat Fields -Stats collected from HAProxy process +Stats collected from HAProxy processes. @@ -1356,7 +1356,7 @@ Stats collected from HAProxy process type: keyword -status (UP/DOWN/NOLB/MAINT/MAINT(via)...) +Status (UP, DOWN, NOLB, MAINT, or MAINT(via)...). [float] @@ -1364,7 +1364,7 @@ status (UP/DOWN/NOLB/MAINT/MAINT(via)...) type: long -total weight (backend), server weight (server) +Total weight (for backends), or server weight (for servers). [float] @@ -1372,7 +1372,7 @@ total weight (backend), server weight (server) type: long -total downtime (in seconds). The value for the backend is the downtime for the whole backend, not the sum of the server downtime. +Total downtime (in seconds). For backends, this value is the downtime for the whole backend, not the sum of the downtime for the servers. [float] @@ -1380,7 +1380,7 @@ total downtime (in seconds). The value for the backend is the downtime for the w type: integer -(0=frontend, 1=backend, 2=server, 3=socket/listener) +Component type (0=frontend, 1=backend, 2=server, or 3=socket/listener). [float] @@ -1388,7 +1388,7 @@ type: integer type: integer -process id (0 for first instance, 1 for second, ...) +Process ID (0 for first instance, 1 for second, and so on). [float] @@ -1396,7 +1396,7 @@ process id (0 for first instance, 1 for second, ...) type: keyword -service name (FRONTEND for frontend, BACKEND for backend, any name for server/listener) +Service name (FRONTEND for frontend, BACKEND for backend, or any name for server/listener). [float] @@ -1406,7 +1406,7 @@ type: long format: bytes -bytes in +Bytes in. [float] @@ -1416,7 +1416,7 @@ type: long format: bytes -bytes out +Bytes out. [float] @@ -1424,7 +1424,7 @@ bytes out type: integer -number of seconds since the last UP<->DOWN transition +Number of seconds since the last UP->DOWN or DOWN->UP transition. [float] @@ -1434,7 +1434,7 @@ type: scaled_float format: percentage -current throttle percentage for the server, when slowstart is active, or no value if not in slowstart. +Current throttle percentage for the server when slowstart is active, or no value if slowstart is inactive. [float] @@ -1442,7 +1442,7 @@ current throttle percentage for the server, when slowstart is active, or no valu type: long -total number of times a server was selected, either for new sessions, or when re-dispatching. The server counter is the number of times that server was selected. +Total number of times a server was selected, either for new sessions, or when re-dispatching. For servers, this field reports the the number of times the server was selected. [float] @@ -1450,7 +1450,7 @@ total number of times a server was selected, either for new sessions, or when re type: long -id of proxy/server if tracking is enabled. +ID of the proxy/server if tracking is enabled. @@ -1459,7 +1459,7 @@ id of proxy/server if tracking is enabled. type: long -cumulative number of connections +Cumulative number of connections. [float] @@ -1467,7 +1467,7 @@ cumulative number of connections type: long -number of times a connection to a server was retried. +Number of times a connection to a server was retried. [float] @@ -1475,7 +1475,7 @@ number of times a connection to a server was retried. type: long -the average connect time in ms over the 1024 last requests +Average connect time in ms over the last 1024 requests. @@ -1484,9 +1484,10 @@ the average connect time in ms over the 1024 last requests type: long -requests denied because of security concerns. - * For tcp this is because of a matched tcp-request content rule. - * For http this is because of a matched http-request or tarpit rule. +Requests denied because of security concerns. + + * For TCP this is because of a matched tcp-request content rule. + * For HTTP this is because of a matched http-request or tarpit rule. [float] @@ -1494,7 +1495,7 @@ requests denied because of security concerns. type: long -current queued requests. For the backend this reports the number queued without a server assigned +Current queued requests. For backends, this field reports the number of requests queued without a server assigned. [float] @@ -1502,7 +1503,7 @@ current queued requests. For the backend this reports the number queued without type: long -max value of queued.current +Maximum value of queued.current. [float] @@ -1510,8 +1511,9 @@ max value of queued.current type: long -request errors. Some of the possible causes are: - * early termination from the client, before the request has been sent. +Request errors. Some of the possible causes are: + + * early termination from the client, before the request has been sent * read error from the client * client timeout * client closed connection @@ -1524,7 +1526,7 @@ request errors. Some of the possible causes are: type: long -number of times a request was redispatched to another server. The server value counts the number of times that server was switched away from. +Number of times a request was redispatched to another server. For servers, this field reports the number of times the server was switched away from. [float] @@ -1532,7 +1534,7 @@ number of times a request was redispatched to another server. The server value c type: long -number of requests that encountered an error trying to connect to a backend server. The backend stat is the sum of the stat for all servers of that backend, plus any connection errors not associated with a particular server (such as the backend having no active servers). +Number of requests that encountered an error trying to connect to a backend server. The backend stat is the sum of the stat for all servers of that backend, plus any connection errors not associated with a particular server (such as the backend having no active servers). [float] @@ -1546,7 +1548,7 @@ number of requests that encountered an error trying to connect to a backend serv type: long -HTTP requests per second over last elapsed second +Number of HTTP requests per second over the last elapsed second. [float] @@ -1554,7 +1556,7 @@ HTTP requests per second over last elapsed second type: long -max number of HTTP requests per second observed +Maximum number of HTTP requests per second. [float] @@ -1562,7 +1564,7 @@ max number of HTTP requests per second observed type: long -total number of HTTP requests received +Total number of HTTP requests received. @@ -1571,7 +1573,8 @@ total number of HTTP requests received type: long -response errors. srv_abrt will be counted here also. Some other errors are: * write error on the client socket (won't be counted for the server stat) * failure applying filters to the respons +Number of response errors. This value includes the number of data transfers aborted by the server (haproxy.stat.server.aborted). Some other errors are: +* write errors on the client socket (won't be counted for the server stat) * failure applying filters to the response [float] @@ -1579,7 +1582,7 @@ response errors. srv_abrt will be counted here also. Some other errors are: * wr type: long -the average response time in ms over the 1024 last requests (0 for TCP) +Average response time in ms over the last 1024 requests (0 for TCP). [float] @@ -1587,8 +1590,7 @@ the average response time in ms over the 1024 last requests (0 for TCP) type: integer -responses denied because of security concerns. - * For http this is because of a matched http-request rule, or "option checkcache". +Responses denied because of security concerns. For HTTP this is because of a matched http-request rule, or "option checkcache". [float] @@ -1602,7 +1604,7 @@ responses denied because of security concerns. type: long -http responses with 1xx code +HTTP responses with 1xx code. [float] @@ -1610,7 +1612,7 @@ http responses with 1xx code type: long -http responses with 2xx code +HTTP responses with 2xx code. [float] @@ -1618,7 +1620,7 @@ http responses with 2xx code type: long -http responses with 3xx code +HTTP responses with 3xx code. [float] @@ -1626,7 +1628,7 @@ http responses with 3xx code type: long -http responses with 4xx code +HTTP responses with 4xx code. [float] @@ -1634,7 +1636,7 @@ http responses with 4xx code type: long -http responses with 5xx code +HTTP responses with 5xx code. [float] @@ -1642,7 +1644,7 @@ http responses with 5xx code type: long -http responses with other codes (protocol error) +HTTP responses with other codes (protocol error). @@ -1651,7 +1653,7 @@ http responses with other codes (protocol error) type: long -current sessions +Number of current sessions. [float] @@ -1659,7 +1661,7 @@ current sessions type: long -max sessions +Maximum number of sessions. [float] @@ -1667,7 +1669,7 @@ max sessions type: long -configured session limit +Configured session limit. @@ -1676,7 +1678,7 @@ configured session limit type: integer -number of sessions per second over last elapsed second +Number of sessions per second over the last elapsed second. [float] @@ -1684,7 +1686,7 @@ number of sessions per second over last elapsed second type: integer -configured limit on new sessions per second +Configured limit on new sessions per second. [float] @@ -1692,7 +1694,7 @@ configured limit on new sessions per second type: integer -max number of new sessions per second +Maximum number of new sessions per second. [float] @@ -1706,7 +1708,8 @@ max number of new sessions per second type: keyword -status of last health check, one of: +Status of the last health check. One of: + UNK -> unknown INI -> initializing SOCKERR -> socket error @@ -1730,7 +1733,7 @@ status of last health check, one of: type: long -layer5-7 code, if available +Layer 5-7 code, if available. [float] @@ -1738,7 +1741,7 @@ layer5-7 code, if available type: long -time in ms took to finish last health check +Time in ms that it took to finish the last health check. [float] @@ -1767,7 +1770,7 @@ type: integer type: long -number of failed checks. (Only counts checks failed when the server is up.) +Number of checks that failed while the server was up. [float] @@ -1775,7 +1778,7 @@ number of failed checks. (Only counts checks failed when the server is up.) type: long -number of UP->DOWN transitions. The backend counter counts transitions to the whole backend being down, rather than the sum of the counters for each server. +Number of UP->DOWN transitions. For backends, this value is the number of transitions to the whole backend being down, rather than the sum of the transitions for each server. [float] @@ -1783,7 +1786,7 @@ number of UP->DOWN transitions. The backend counter counts transitions to the wh type: integer -number of data transfers aborted by the client +Number of data transfers aborted by the client. [float] @@ -1797,7 +1800,7 @@ number of data transfers aborted by the client type: integer -server id (unique inside a proxy) +Server ID (unique inside a proxy). [float] @@ -1805,7 +1808,7 @@ server id (unique inside a proxy) type: integer -number of data transfers aborted by the server (inc. in eresp) +Number of data transfers aborted by the server. This value is included in haproxy.stat.response.errors. [float] @@ -1813,7 +1816,7 @@ number of data transfers aborted by the server (inc. in eresp) type: integer -number of active servers (backend), server is active (server) +Number of active servers (backend), server is active (server). [float] @@ -1821,7 +1824,7 @@ number of active servers (backend), server is active (server) type: integer -number of backup servers (backend), server is backup (server) +Number of backup servers (backend), server is backup (server). [float] @@ -1837,7 +1840,7 @@ type: long format: bytes -number of HTTP response bytes fed to the compressor +Number of HTTP response bytes fed to the compressor. [float] @@ -1847,7 +1850,7 @@ type: integer format: bytes -number of HTTP response bytes emitted by the compressor +Number of HTTP response bytes emitted by the compressor. [float] @@ -1857,7 +1860,7 @@ type: long format: bytes -number of bytes that bypassed the HTTP compressor (CPU/BW limit) +Number of bytes that bypassed the HTTP compressor (CPU/BW limit). [float] @@ -1867,7 +1870,7 @@ type: long format: bytes -number of HTTP responses that were compressed +Number of HTTP responses that were compressed. [float] @@ -1881,7 +1884,7 @@ number of HTTP responses that were compressed type: integer -unique proxy id +Unique proxy ID. [float] @@ -1889,7 +1892,7 @@ unique proxy id type: keyword -proxy name +Proxy name. [float] @@ -1903,7 +1906,7 @@ proxy name type: integer -configured maxqueue for the server, or nothing in the value is 0 (default, meaning no limit) +Configured queue limit (maxqueue) for the server, or nothing if the value of maxqueue is 0 (meaning no limit). [float] @@ -1911,7 +1914,7 @@ configured maxqueue for the server, or nothing in the value is 0 (default, meani type: integer -the average queue time in ms over the 1024 last requests +The average queue time in ms over the last 1024 requests. [[exported-fields-kafka]] diff --git a/metricbeat/docs/modules/haproxy.asciidoc b/metricbeat/docs/modules/haproxy.asciidoc index 87add046406d..14fa204d3900 100644 --- a/metricbeat/docs/modules/haproxy.asciidoc +++ b/metricbeat/docs/modules/haproxy.asciidoc @@ -5,13 +5,15 @@ This file is generated! See scripts/docs_collector.py [[metricbeat-module-haproxy]] == HAProxy Module -This is the haproxy Module. To enable stats collection from HAProxy, you must enable the stats socket via TCP. -For example, placing the following statement under the `global` or `default` section of the haproxy config: +This module collects stats from http://www.haproxy.org/[HAProxy]. To configure +HAProxy to collect stats, you must enable the stats socket via TCP. For example, +to enable stats reporting via any local IP on port 14567, place this statement +under the `global` or `default` section of the haproxy config: `stats socket 127.0.0.1:14567` -will enable stats reporting via any local IP on port 14567. Please note that you should probably use an internal private IP -or secure this with a firewall rule so that only designated hosts can access this data. +NOTE: You should use an internal private IP, or secure this with a firewall +rule, so that only designated hosts can access this data. [float] === Compatibility @@ -22,7 +24,7 @@ The HAProxy metricsets were tested with HAProxy 1.6 and are expected to work wit [float] === Example Configuration -The haproxy module supports the standard configuration options that are described +The HAProxy module supports the standard configuration options that are described in <>. Here is an example configuration: [source,yaml] diff --git a/metricbeat/docs/modules_list.asciidoc b/metricbeat/docs/modules_list.asciidoc index 3229b250582a..a0396b7d7eac 100644 --- a/metricbeat/docs/modules_list.asciidoc +++ b/metricbeat/docs/modules_list.asciidoc @@ -4,7 +4,7 @@ This file is generated! See scripts/docs_collector.py * <> * <> - * <> + * <> * <> * <> * <> diff --git a/metricbeat/metricbeat.full.yml b/metricbeat/metricbeat.full.yml index 2da9b54fd16d..b007c311c8c3 100644 --- a/metricbeat/metricbeat.full.yml +++ b/metricbeat/metricbeat.full.yml @@ -80,7 +80,7 @@ metricbeat.modules: #certificate: "/etc/pki/client/cert.pem" #key: "/etc/pki/client/cert.key" -#------------------------------- haproxy Module ------------------------------ +#------------------------------- HAProxy Module ------------------------------ #- module: haproxy #metricsets: ["info", "stat"] #enabled: true diff --git a/metricbeat/module/haproxy/_meta/docs.asciidoc b/metricbeat/module/haproxy/_meta/docs.asciidoc index 780fd3920b6d..f6407ce40723 100644 --- a/metricbeat/module/haproxy/_meta/docs.asciidoc +++ b/metricbeat/module/haproxy/_meta/docs.asciidoc @@ -1,12 +1,14 @@ == HAProxy Module -This is the haproxy Module. To enable stats collection from HAProxy, you must enable the stats socket via TCP. -For example, placing the following statement under the `global` or `default` section of the haproxy config: +This module collects stats from http://www.haproxy.org/[HAProxy]. To configure +HAProxy to collect stats, you must enable the stats socket via TCP. For example, +to enable stats reporting via any local IP on port 14567, place this statement +under the `global` or `default` section of the haproxy config: `stats socket 127.0.0.1:14567` -will enable stats reporting via any local IP on port 14567. Please note that you should probably use an internal private IP -or secure this with a firewall rule so that only designated hosts can access this data. +NOTE: You should use an internal private IP, or secure this with a firewall +rule, so that only designated hosts can access this data. [float] === Compatibility diff --git a/metricbeat/module/haproxy/_meta/fields.yml b/metricbeat/module/haproxy/_meta/fields.yml index 2cd41422f569..fe6b56168085 100644 --- a/metricbeat/module/haproxy/_meta/fields.yml +++ b/metricbeat/module/haproxy/_meta/fields.yml @@ -1,13 +1,13 @@ - key: haproxy - title: "haproxy" + title: "HAProxy" description: > experimental[] - haproxy Module + HAProxy Module short_config: false fields: - name: haproxy type: group description: > - HAProx metrics. + HAProxy metrics. fields: diff --git a/metricbeat/module/haproxy/info/_meta/docs.asciidoc b/metricbeat/module/haproxy/info/_meta/docs.asciidoc index 1eb0c3c062b7..abb5442a0dde 100644 --- a/metricbeat/module/haproxy/info/_meta/docs.asciidoc +++ b/metricbeat/module/haproxy/info/_meta/docs.asciidoc @@ -1,3 +1,3 @@ -=== HAProxy info MetricSet +=== HAProxy Info Metricset -This is the info metricset of the haproxy module. +The HAProxy `info` metricset collects general information about HAProxy processes. diff --git a/metricbeat/module/haproxy/info/_meta/fields.yml b/metricbeat/module/haproxy/info/_meta/fields.yml index 6252c0cbc4f3..c8ff0ed331fd 100644 --- a/metricbeat/module/haproxy/info/_meta/fields.yml +++ b/metricbeat/module/haproxy/info/_meta/fields.yml @@ -1,22 +1,22 @@ - name: info type: group description: > - General infomration collected on HAProxy process + General information about HAProxy processes. fields: - name: processes type: long description: > - Number of processes + Number of processes. - name: process_num type: long description: > - Process number + Process number. - name: pid type: long description: > - Process ID + Process ID. - name: run_queue type: long @@ -29,18 +29,18 @@ - name: uptime.sec type: long description: > - Current uptime in seconds + Current uptime in seconds. - name: memory.max.bytes type: long format: bytes description: > - Max number of memory usage in bytes (The 'Memmax_MB' value converted to bytes) + Maximum amount of memory usage in bytes (the 'Memmax_MB' value converted to bytes). - name: ulimit_n type: long description: > - Max number of open files for process + Maximum number of open files for the process. - name: compress type: group @@ -89,32 +89,32 @@ - name: current type: long description: > - Current Connections + Current connections. - name: total type: long description: > - Total Connections + Total connections. - name: ssl.current type: long description: > - Current ssl Connections + Current SSL connections. - name: ssl.total type: long description: > - Current Connections + Total SSL connections. - name: ssl.max type: long description: > - Current Connections + Maximum SSL connections. - name: max type: long description: > - Max connections + Maximum connections. - name: hard_max type: long diff --git a/metricbeat/module/haproxy/stat/_meta/docs.asciidoc b/metricbeat/module/haproxy/stat/_meta/docs.asciidoc index c3c90f78d0f6..63e90104b3c4 100644 --- a/metricbeat/module/haproxy/stat/_meta/docs.asciidoc +++ b/metricbeat/module/haproxy/stat/_meta/docs.asciidoc @@ -1,133 +1,5 @@ -=== HAProxy stat MetricSet +=== HAProxy Stat Metricset -This is the stat metricset of the haproxy module. +The HAProxy `stat` metricset collects 'stat' fields from HAProxy processes. - -[float] -=== Official documentation for fields - -A list of the 'stat' fields along with a basic description can be found here: - -http://www.haproxy.org/download/1.6/doc/management.txt - -The following documentation bellow is an extract from the URL above, more specifically from section "9.1. CSV format" - -[source,log] ----- -In brackets after each field name are the types which may have a value for -that field. The types are L (Listeners), F (Frontends), B (Backends), and -S (Servers). - - 0. pxname [LFBS]: proxy name - 1. svname [LFBS]: service name (FRONTEND for frontend, BACKEND for backend, - any name for server/listener) - 2. qcur [..BS]: current queued requests. For the backend this reports the - number queued without a server assigned. - 3. qmax [..BS]: max value of qcur - 4. scur [LFBS]: current sessions - 5. smax [LFBS]: max sessions - 6. slim [LFBS]: configured session limit - 7. stot [LFBS]: cumulative number of connections - 8. bin [LFBS]: bytes in - 9. bout [LFBS]: bytes out - 10. dreq [LFB.]: requests denied because of security concerns. - - For tcp this is because of a matched tcp-request content rule. - - For http this is because of a matched http-request or tarpit rule. - 11. dresp [LFBS]: responses denied because of security concerns. - - For http this is because of a matched http-request rule, or - "option checkcache". - 12. ereq [LF..]: request errors. Some of the possible causes are: - - early termination from the client, before the request has been sent. - - read error from the client - - client timeout - - client closed connection - - various bad requests from the client. - - request was tarpitted. - 13. econ [..BS]: number of requests that encountered an error trying to - connect to a backend server. The backend stat is the sum of the stat - for all servers of that backend, plus any connection errors not - associated with a particular server (such as the backend having no - active servers). - 14. eresp [..BS]: response errors. srv_abrt will be counted here also. - Some other errors are: - - write error on the client socket (won't be counted for the server stat) - - failure applying filters to the response. - 15. wretr [..BS]: number of times a connection to a server was retried. - 16. wredis [..BS]: number of times a request was redispatched to another - server. The server value counts the number of times that server was - switched away from. - 17. status [LFBS]: status (UP/DOWN/NOLB/MAINT/MAINT(via)...) - 18. weight [..BS]: total weight (backend), server weight (server) - 19. act [..BS]: number of active servers (backend), server is active (server) - 20. bck [..BS]: number of backup servers (backend), server is backup (server) - 21. chkfail [...S]: number of failed checks. (Only counts checks failed when - the server is up.) - 22. chkdown [..BS]: number of UP->DOWN transitions. The backend counter counts - transitions to the whole backend being down, rather than the sum of the - counters for each server. - 23. lastchg [..BS]: number of seconds since the last UP<->DOWN transition - 24. downtime [..BS]: total downtime (in seconds). The value for the backend - is the downtime for the whole backend, not the sum of the server downtime. - 25. qlimit [...S]: configured maxqueue for the server, or nothing in the - value is 0 (default, meaning no limit) - 26. pid [LFBS]: process id (0 for first instance, 1 for second, ...) - 27. iid [LFBS]: unique proxy id - 28. sid [L..S]: server id (unique inside a proxy) - 29. throttle [...S]: current throttle percentage for the server, when - slowstart is active, or no value if not in slowstart. - 30. lbtot [..BS]: total number of times a server was selected, either for new - sessions, or when re-dispatching. The server counter is the number - of times that server was selected. - 31. tracked [...S]: id of proxy/server if tracking is enabled. - 32. type [LFBS]: (0=frontend, 1=backend, 2=server, 3=socket/listener) - 33. rate [.FBS]: number of sessions per second over last elapsed second - 34. rate_lim [.F..]: configured limit on new sessions per second - 35. rate_max [.FBS]: max number of new sessions per second - 36. check_status [...S]: status of last health check, one of: - UNK -> unknown - INI -> initializing - SOCKERR -> socket error - L4OK -> check passed on layer 4, no upper layers testing enabled - L4TOUT -> layer 1-4 timeout - L4CON -> layer 1-4 connection problem, for example - "Connection refused" (tcp rst) or "No route to host" (icmp) - L6OK -> check passed on layer 6 - L6TOUT -> layer 6 (SSL) timeout - L6RSP -> layer 6 invalid response - protocol error - L7OK -> check passed on layer 7 - L7OKC -> check conditionally passed on layer 7, for example 404 with - disable-on-404 - L7TOUT -> layer 7 (HTTP/SMTP) timeout - L7RSP -> layer 7 invalid response - protocol error - L7STS -> layer 7 response error, for example HTTP 5xx - 37. check_code [...S]: layer5-7 code, if available - 38. check_duration [...S]: time in ms took to finish last health check - 39. hrsp_1xx [.FBS]: http responses with 1xx code - 40. hrsp_2xx [.FBS]: http responses with 2xx code - 41. hrsp_3xx [.FBS]: http responses with 3xx code - 42. hrsp_4xx [.FBS]: http responses with 4xx code - 43. hrsp_5xx [.FBS]: http responses with 5xx code - 44. hrsp_other [.FBS]: http responses with other codes (protocol error) - 45. hanafail [...S]: failed health checks details - 46. req_rate [.F..]: HTTP requests per second over last elapsed second - 47. req_rate_max [.F..]: max number of HTTP requests per second observed - 48. req_tot [.F..]: total number of HTTP requests received - 49. cli_abrt [..BS]: number of data transfers aborted by the client - 50. srv_abrt [..BS]: number of data transfers aborted by the server - (inc. in eresp) - 51. comp_in [.FB.]: number of HTTP response bytes fed to the compressor - 52. comp_out [.FB.]: number of HTTP response bytes emitted by the compressor - 53. comp_byp [.FB.]: number of bytes that bypassed the HTTP compressor - (CPU/BW limit) - 54. comp_rsp [.FB.]: number of HTTP responses that were compressed - 55. lastsess [..BS]: number of seconds since last session assigned to - server/backend - 56. last_chk [...S]: last health check contents or textual error - 57. last_agt [...S]: last agent check contents or textual error - 58. qtime [..BS]: the average queue time in ms over the 1024 last requests - 59. ctime [..BS]: the average connect time in ms over the 1024 last requests - 60. rtime [..BS]: the average response time in ms over the 1024 last requests - (0 for TCP) - 61. ttime [..BS]: the average total session time in ms over the 1024 last - requests ----- +See section "9.1. CSV format" of the http://www.haproxy.org/download/1.6/doc/management.txt[official HAProxy Management Guide] for a full list of 'stat' fields. diff --git a/metricbeat/module/haproxy/stat/_meta/fields.yml b/metricbeat/module/haproxy/stat/_meta/fields.yml index 12beb8cb87c0..27735ec020f3 100644 --- a/metricbeat/module/haproxy/stat/_meta/fields.yml +++ b/metricbeat/module/haproxy/stat/_meta/fields.yml @@ -1,75 +1,75 @@ - name: stat type: group description: > - Stats collected from HAProxy process + Stats collected from HAProxy processes. fields: - name: status type: keyword description: > - status (UP/DOWN/NOLB/MAINT/MAINT(via)...) + Status (UP, DOWN, NOLB, MAINT, or MAINT(via)...). - name: weight type: long description: > - total weight (backend), server weight (server) + Total weight (for backends), or server weight (for servers). - name: downtime type: long description: > - total downtime (in seconds). The value for the backend - is the downtime for the whole backend, not the sum of the server downtime. + Total downtime (in seconds). For backends, this value is the downtime + for the whole backend, not the sum of the downtime for the servers. - name: component_type type: integer description: > - (0=frontend, 1=backend, 2=server, 3=socket/listener) + Component type (0=frontend, 1=backend, 2=server, or 3=socket/listener). - name: process_id type: integer description: > - process id (0 for first instance, 1 for second, ...) + Process ID (0 for first instance, 1 for second, and so on). - name: service_name type: keyword description: > - service name (FRONTEND for frontend, BACKEND for backend, any name for server/listener) + Service name (FRONTEND for frontend, BACKEND for backend, or any name for server/listener). - name: in.bytes type: long format: bytes description: > - bytes in + Bytes in. - name: out.bytes type: long format: bytes description: > - bytes out + Bytes out. - name: last_change type: integer description: > - number of seconds since the last UP<->DOWN transition + Number of seconds since the last UP->DOWN or DOWN->UP transition. - name: throttle.pct type: scaled_float format: percentage description: > - current throttle percentage for the server, when - slowstart is active, or no value if not in slowstart. + Current throttle percentage for the server when slowstart + is active, or no value if slowstart is inactive. - name: selected.total type: long description: > - total number of times a server was selected, either for new - sessions, or when re-dispatching. The server counter is the number - of times that server was selected. + Total number of times a server was selected, either for new + sessions, or when re-dispatching. For servers, this field reports the + the number of times the server was selected. - name: tracked.id type: long description: > - id of proxy/server if tracking is enabled. + ID of the proxy/server if tracking is enabled. - name: connection type: group @@ -78,17 +78,17 @@ - name: total type: long description: > - cumulative number of connections + Cumulative number of connections. - name: retried type: long description: > - number of times a connection to a server was retried. + Number of times a connection to a server was retried. - name: time.avg type: long description: > - the average connect time in ms over the 1024 last requests + Average connect time in ms over the last 1024 requests. - name: request type: group @@ -97,25 +97,28 @@ - name: denied type: long description: > - requests denied because of security concerns. - * For tcp this is because of a matched tcp-request content rule. - * For http this is because of a matched http-request or tarpit rule. + Requests denied because of security concerns. + + * For TCP this is because of a matched tcp-request content rule. + * For HTTP this is because of a matched http-request or tarpit rule. - name: queued.current type: long description: > - current queued requests. For the backend this reports the number queued without a server assigned + Current queued requests. For backends, this field reports the number + of requests queued without a server assigned. - name: queued.max type: long description: > - max value of queued.current + Maximum value of queued.current. - name: errors type: long description: > - request errors. Some of the possible causes are: - * early termination from the client, before the request has been sent. + Request errors. Some of the possible causes are: + + * early termination from the client, before the request has been sent * read error from the client * client timeout * client closed connection @@ -125,14 +128,14 @@ - name: redispatched type: long description: > - number of times a request was redispatched to another - server. The server value counts the number of times that server was + Number of times a request was redispatched to another server. For + servers, this field reports the number of times the server was switched away from. - name: connection.errors type: long description: > - number of requests that encountered an error trying to + Number of requests that encountered an error trying to connect to a backend server. The backend stat is the sum of the stat for all servers of that backend, plus any connection errors not associated with a particular server (such as the backend having no @@ -145,16 +148,16 @@ - name: value type: long description: > - HTTP requests per second over last elapsed second + Number of HTTP requests per second over the last elapsed second. - name: max type: long description: > - max number of HTTP requests per second observed + Maximum number of HTTP requests per second. - name: total type: long description: > - total number of HTTP requests received + Total number of HTTP requests received. - name: response @@ -164,22 +167,24 @@ - name: errors type: long description: > - response errors. srv_abrt will be counted here also. + Number of response errors. This value includes the number of data + transfers aborted by the server (haproxy.stat.server.aborted). Some other errors are: - * write error on the client socket (won't be counted for the server stat) - * failure applying filters to the respons + + * write errors on the client socket (won't be counted for the server stat) + * failure applying filters to the response - name: time.avg type: long description: > - the average response time in ms over the 1024 last requests (0 for TCP) + Average response time in ms over the last 1024 requests (0 for TCP). - name: denied type: integer description: > - responses denied because of security concerns. - * For http this is because of a matched http-request rule, or "option checkcache". + Responses denied because of security concerns. For HTTP this is + because of a matched http-request rule, or "option checkcache". - name: http type: group @@ -189,32 +194,32 @@ - name: 1xx type: long description: > - http responses with 1xx code + HTTP responses with 1xx code. - name: 2xx type: long description: > - http responses with 2xx code + HTTP responses with 2xx code. - name: 3xx type: long description: > - http responses with 3xx code + HTTP responses with 3xx code. - name: 4xx type: long description: > - http responses with 4xx code + HTTP responses with 4xx code. - name: 5xx type: long description: > - http responses with 5xx code + HTTP responses with 5xx code. - name: other type: long description: > - http responses with other codes (protocol error) + HTTP responses with other codes (protocol error). - name: session @@ -224,17 +229,17 @@ - name: current type: long description: > - current sessions + Number of current sessions. - name: max type: long description: > - max sessions + Maximum number of sessions. - name: limit type: long description: > - configured session limit + Configured session limit. - name: rate type: group @@ -242,17 +247,17 @@ - name: value type: integer description: > - number of sessions per second over last elapsed second + Number of sessions per second over the last elapsed second. - name: limit type: integer description: > - configured limit on new sessions per second + Configured limit on new sessions per second. - name: max type: integer description: > - max number of new sessions per second + Maximum number of new sessions per second. - name: check @@ -263,7 +268,8 @@ - name: status type: keyword description: > - status of last health check, one of: + Status of the last health check. One of: + UNK -> unknown INI -> initializing SOCKERR -> socket error @@ -284,12 +290,12 @@ - name: code type: long description: > - layer5-7 code, if available + Layer 5-7 code, if available. - name: duration type: long description: > - time in ms took to finish last health check + Time in ms that it took to finish the last health check. - name: health.last type: long @@ -306,20 +312,19 @@ - name: failed type: long description: > - number of failed checks. (Only counts checks failed when - the server is up.) + Number of checks that failed while the server was up. - name: down type: long description: > - number of UP->DOWN transitions. The backend counter counts - transitions to the whole backend being down, rather than the sum of the - counters for each server. + Number of UP->DOWN transitions. For backends, this value is the + number of transitions to the whole backend being down, rather than + the sum of the transitions for each server. - name: client.aborted type: integer description: > - number of data transfers aborted by the client + Number of data transfers aborted by the client. - name: server @@ -330,22 +335,23 @@ - name: id type: integer description: > - server id (unique inside a proxy) + Server ID (unique inside a proxy). - name: aborted type: integer description: > - number of data transfers aborted by the server (inc. in eresp) + Number of data transfers aborted by the server. This value is + included in haproxy.stat.response.errors. - name: active type: integer description: > - number of active servers (backend), server is active (server) + Number of active servers (backend), server is active (server). - name: backup type: integer description: > - number of backup servers (backend), server is backup (server) + Number of backup servers (backend), server is backup (server). - name: compressor @@ -357,25 +363,25 @@ type: long format: bytes description: > - number of HTTP response bytes fed to the compressor + Number of HTTP response bytes fed to the compressor. - name: out.bytes type: integer format: bytes description: > - number of HTTP response bytes emitted by the compressor + Number of HTTP response bytes emitted by the compressor. - name: bypassed.bytes type: long format: bytes description: > - number of bytes that bypassed the HTTP compressor (CPU/BW limit) + Number of bytes that bypassed the HTTP compressor (CPU/BW limit). - name: response.bytes type: long format: bytes description: > - number of HTTP responses that were compressed + Number of HTTP responses that were compressed. - name: proxy type: group @@ -385,12 +391,12 @@ - name: id type: integer description: > - unique proxy id + Unique proxy ID. - name: name type: keyword description: > - proxy name + Proxy name. - name: queue @@ -401,13 +407,13 @@ - name: limit type: integer description: > - configured maxqueue for the server, or nothing in the - value is 0 (default, meaning no limit) + Configured queue limit (maxqueue) for the server, or nothing if the + value of maxqueue is 0 (meaning no limit). - name: time.avg type: integer description: > - the average queue time in ms over the 1024 last requests + The average queue time in ms over the last 1024 requests. From e842beac9d55be3c3f6b8648ea5cbbd150494441 Mon Sep 17 00:00:00 2001 From: DeDe Morton Date: Tue, 10 Jan 2017 12:11:44 -0800 Subject: [PATCH 2/2] Add fixes from review feedback --- metricbeat/docs/fields.asciidoc | 6 +++--- metricbeat/module/haproxy/stat/_meta/fields.yml | 9 +++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/metricbeat/docs/fields.asciidoc b/metricbeat/docs/fields.asciidoc index 6b0c03e4fa02..1c4a79758d60 100644 --- a/metricbeat/docs/fields.asciidoc +++ b/metricbeat/docs/fields.asciidoc @@ -1534,7 +1534,7 @@ Number of times a request was redispatched to another server. For servers, this type: long -Number of requests that encountered an error trying to connect to a backend server. The backend stat is the sum of the stat for all servers of that backend, plus any connection errors not associated with a particular server (such as the backend having no active servers). +Number of requests that encountered an error trying to connect to a server. For backends, this field reports the sum of the stat for all backend servers, plus any connection errors not associated with a particular server (such as the backend having no active servers). [float] @@ -1816,7 +1816,7 @@ Number of data transfers aborted by the server. This value is included in haprox type: integer -Number of active servers (backend), server is active (server). +Number of backend servers that are active, meaning that they are healthy and can receive requests from the load balancer. [float] @@ -1824,7 +1824,7 @@ Number of active servers (backend), server is active (server). type: integer -Number of backup servers (backend), server is backup (server). +Number of backend servers that are backup servers. [float] diff --git a/metricbeat/module/haproxy/stat/_meta/fields.yml b/metricbeat/module/haproxy/stat/_meta/fields.yml index 27735ec020f3..98b90c3ad03d 100644 --- a/metricbeat/module/haproxy/stat/_meta/fields.yml +++ b/metricbeat/module/haproxy/stat/_meta/fields.yml @@ -136,8 +136,8 @@ type: long description: > Number of requests that encountered an error trying to - connect to a backend server. The backend stat is the sum of the stat - for all servers of that backend, plus any connection errors not + connect to a server. For backends, this field reports the sum of + the stat for all backend servers, plus any connection errors not associated with a particular server (such as the backend having no active servers). @@ -346,12 +346,13 @@ - name: active type: integer description: > - Number of active servers (backend), server is active (server). + Number of backend servers that are active, meaning that they are + healthy and can receive requests from the load balancer. - name: backup type: integer description: > - Number of backup servers (backend), server is backup (server). + Number of backend servers that are backup servers. - name: compressor