From f590e2aebde729bf19de206203ab9bda60ce7561 Mon Sep 17 00:00:00 2001 From: Rene Zbinden Date: Thu, 7 Apr 2016 17:05:20 +0000 Subject: [PATCH] fix tests closes #939 --- CHANGELOG.md | 1 + README.md | 1 + plugins/inputs/sysstat/sysstat.go | 6 ++++-- plugins/inputs/sysstat/sysstat_test.go | 1 + 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 699d0f602..020a06cfe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ - [#979](https://github.com/influxdata/telegraf/pull/979): Reduce allocations in the TCP listener. - [#935](https://github.com/influxdata/telegraf/pull/935): AWS Cloudwatch input plugin. Thanks @joshhardy & @ljosa! - [#943](https://github.com/influxdata/telegraf/pull/943): http_response input plugin. Thanks @Lswith! +- [#939](https://github.com/influxdata/telegraf/pull/939): sysstat input plugin. Thanks @zbindenren! ### Bugfixes - [#968](https://github.com/influxdata/telegraf/issues/968): Processes plugin gets unknown state when spaces are in (command name) diff --git a/README.md b/README.md index 8621238dd..994c6803d 100644 --- a/README.md +++ b/README.md @@ -206,6 +206,7 @@ Currently implemented sources: * [zfs](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/zfs) * [zookeeper](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/zookeeper) * [win_perf_counters ](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/win_perf_counters) (windows performance counters) +* [sysstat](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/sysstat) * [system](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/system) * cpu * mem diff --git a/plugins/inputs/sysstat/sysstat.go b/plugins/inputs/sysstat/sysstat.go index d57bd10dc..c8c17ac45 100644 --- a/plugins/inputs/sysstat/sysstat.go +++ b/plugins/inputs/sysstat/sysstat.go @@ -72,8 +72,10 @@ func (*Sysstat) Description() string { var sampleConfig = ` ## Path to the sadc command. # - ## On Debian and Arch Linux the default path is /usr/lib/sa/sadc whereas - ## on RHEL and CentOS the default path is /usr/lib64/sa/sadc + ## Common Defaults: + ## Debian/Ubuntu: /usr/lib/sysstat/sadc + ## Arch: /usr/lib/sa/sadc + ## RHEL/CentOS: /usr/lib64/sa/sadc sadc_path = "/usr/lib/sa/sadc" # required # # diff --git a/plugins/inputs/sysstat/sysstat_test.go b/plugins/inputs/sysstat/sysstat_test.go index 3c8f93d04..e344d307d 100644 --- a/plugins/inputs/sysstat/sysstat_test.go +++ b/plugins/inputs/sysstat/sysstat_test.go @@ -15,6 +15,7 @@ import ( var s = Sysstat{ interval: 10, Sadc: "/usr/lib/sa/sadc", + Sadf: "/usr/bin/sadf", Group: false, Activities: []string{"DISK", "SNMP"}, Options: map[string]string{