diff --git a/etc/telegraf.conf b/etc/telegraf.conf index b0715a441..176b32f0f 100644 --- a/etc/telegraf.conf +++ b/etc/telegraf.conf @@ -1459,6 +1459,20 @@ # stats = ["MAIN.cache_hit", "MAIN.cache_miss", "MAIN.uptime"] +# # Read metrics of ZFS from arcstats, zfetchstats, vdev_cache_stats, and pools +# [[inputs.zfs]] +# ## ZFS kstat path. Ignored on FreeBSD +# ## If not specified, then default is: +# # kstatPath = "/proc/spl/kstat/zfs" +# +# ## By default, telegraf gather all zfs stats +# ## If not specified, then default is: +# # kstatMetrics = ["arcstats", "zfetchstats", "vdev_cache_stats"] +# +# ## By default, don't gather zpool stats +# # poolMetrics = false + + # # Reads 'mntr' stats from one or many zookeeper servers # [[inputs.zookeeper]] # ## An array of address to gather stats about. Specify an ip or hostname diff --git a/plugins/inputs/zfs/zfs_other.go b/plugins/inputs/zfs/zfs_other.go new file mode 100644 index 000000000..3f6ad3ef6 --- /dev/null +++ b/plugins/inputs/zfs/zfs_other.go @@ -0,0 +1,18 @@ +// +build !linux !freebsd + +package zfs + +import ( + "github.com/influxdata/telegraf" + "github.com/influxdata/telegraf/plugins/inputs" +) + +func (z *Zfs) Gather(acc telegraf.Accumulator) error { + return nil +} + +func init() { + inputs.Add("zfs", func() telegraf.Input { + return &Zfs{} + }) +}