zpool_influxdb.8: modernise

Also rip out the section about potentially including in the OpenZFS
distribution and simplify -e description

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #12125
This commit is contained in:
наб 2021-05-26 16:14:04 +02:00 committed by Brian Behlendorf
parent f67a920a6d
commit 9d7c10388a
1 changed files with 73 additions and 68 deletions

View File

@ -18,76 +18,81 @@
.\" .\"
.\" CDDL HEADER END .\" CDDL HEADER END
.\" .\"
.\"
.\" Copyright 2020 Richard Elling .\" Copyright 2020 Richard Elling
.\" .Dd June 14, 2020 .\"
.TH zpool_influxdb 8 .Dd May 26, 2021
.SH NAME .Dt ZPOOL_INFLUXDB 8
zpool_influxdb \- collect zpool statistics in influxdb line protocol format .Os
.SH SYNOPSIS .
.LP .Sh NAME
.nf .Nm zpool_influxdb
\fBzpool_influxdb\fR [--execd] [--no-histogram] [--sum-histogram-buckets] .Nd collect ZFS pool statistics in InfluxDB line protocol format
[--tags key=value] [pool] .Sh SYNOPSIS
\fBzpool_influxdb\fR --help .Nm
.fi .Op Fl e Ns | Ns Fl -execd
.SH DESCRIPTION .Op Fl n Ns | Ns Fl -no-histogram
The \fBzpool_influxdb\fR command produces influxdb line protocol compatible .Op Fl s Ns | Ns Fl -sum-histogram-buckets
metrics from zpools. Like the \fBzpool\fR command, \fBzpool_influxdb\fR .Op Fl t Ns | Ns Fl -tags Ar key Ns = Ns Ar value Ns Op , Ns Ar key Ns = Ns Ar value Ns
reads the current pool status and statistics. Unlike the \fBzpool\fR .Op Ar pool
command which is intended for humans, \fBzpool_influxdb\fR formats the .
output in influxdb line protocol. The expected use is as a plugin to a .Sh DESCRIPTION
metrics collector or aggregator, such as telegraf. .Nm
produces InfluxDB-line-protocol-compatible metrics from zpools.
By default, \fBzpool_influxdb\fR prints pool metrics and status in the Like the
influxdb line protocol format. All pools are printed, similar to .Nm zpool
the \fBzpool status\fR command. Providing a pool name restricts the command,
output to the named pool. .Nm
reads the current pool status and statistics.
Like the \fBzpool\fR command, \fBzpool_influxdb\fR uses internal data Unlike the
structures that can change over time as new ZFS releases are made. .Nm zpool
Therefore, the \fBzpool_influxdb\fR command must be compiled against the command which is intended for humans,
ZFS source. It is expected that later releases of ZFS includes compatible .Nm
\fBzpool_influxdb\fR and \fBzpool\fR commands. formats the output in the InfluxDB line protocol.
The expected use is as a plugin to a
.SH OPTIONS metrics collector or aggregator, such as Telegraf.
.TP .Pp
\fB\--execd\fR, \fB-e\fR By default,
Run in daemon mode compatible with telegraf`s \fBexecd\fR plugin. .Nm
In this mode, the pools are sampled every time there is a [return] on stdin. prints pool metrics and status in the InfluxDB line protocol format.
Once a sample printed, \fBzpool_influxdb\fR waits for another [return]. All pools are printed, similar to the
When run on a terminal, use [ctrl+C] to exit. .Nm zpool Cm status
.TP command.
\fB\--no-histogram\fR, \fB-n\fR Providing a pool name restricts the output to the named pool.
Do not print latency and I/O size histograms. This can reduce the total .
.Sh OPTIONS
.Bl -tag -width "-e, --execd"
.It Fl e , -execd
Run in daemon mode compatible with Telegraf's
.Nm execd
plugin.
In this mode, the pools are sampled every time a
newline appears on the standard input.
.It Fl n , -no-histogram
Do not print latency and I/O size histograms.
This can reduce the total
amount of data, but one should consider the value brought by the insights amount of data, but one should consider the value brought by the insights
that latency and I/O size distributions provide. The resulting values that latency and I/O size distributions provide.
are suitable for graphing with grafana's heatmap plugin. The resulting values
.TP are suitable for graphing with Grafana's heatmap plugin.
\fB--sum-histogram-buckets\fR, \fB-s\fR .It Fl s , -sum-histogram-buckets
Accumulates bucket values. By default, the values are not accumulated and Accumulates bucket values.
the raw data appears as shown by \fBzpool iostat\fR. This works well for By default, the values are not accumulated and the raw data appears as shown by
grafana's heatmap plugin. Summing the buckets produces output similar to .Nm zpool Cm iostat .
prometheus histograms. This works well for Grafana's heatmap plugin.
.TP Summing the buckets produces output similar to Prometheus histograms.
\fB--tags\fR, \fB-t\fR .It Fl t , Fl -tags Ar key Ns = Ns Ar value Ns Op , Ns Ar key Ns = Ns Ar value Ns
Adds specified tags to the tag set. Tags are key=value pairs and multiple Adds specified tags to the tag set.
tags are separated by commas. No sanity checking is performed. No sanity checking is performed.
See the InfluxDB Line Protocol format documentation for details on escaping See the InfluxDB Line Protocol format documentation for details on escaping
special characters used in tags. special characters used in tags.
.TP .It Fl h , -help
\fB\--help\fR, \fB\-h\fR
Print a usage summary. Print a usage summary.
.El
.SH SEE ALSO .
.LP .Sh SEE ALSO
\fBzpool-status\fR(8) .Xr zpool-iostat 8 ,
\fBzpool-iostat\fR(8) .Xr zpool-status 8 ,
.PP .Lk https://github.com/influxdata/influxdb "InfluxDB" ,
Influxdb https://github.com/influxdata/influxdb .Lk https://github.com/influxdata/telegraf "Telegraf" ,
.PP .Lk https://grafana.com "Grafana" ,
Telegraf https://github.com/influxdata/telegraf .Lk https://prometheus.io "Prometheus"
.PP
Grafana https://grafana.com
.PP
Prometheus https://prometheus.io