From: Marc Fournier Date: Wed, 17 Jul 2013 09:59:57 +0000 (+0200) Subject: df: rename percentage types to a more generic name X-Git-Tag: collectd-5.4.0~16^2~1 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=26cad19ab2412d87fa01f75ab498054482a072d2;p=collectd.git df: rename percentage types to a more generic name --- diff --git a/src/df.c b/src/df.c index 540985d7..4936cc0c 100644 --- a/src/df.c +++ b/src/df.c @@ -309,11 +309,11 @@ static int df_read (void) { if (statbuf.f_blocks > 0) { - df_submit_one (disk_name, "df_complex_pct", "free", + df_submit_one (disk_name, "percent_bytes", "free", (gauge_t) ((float_t)(blk_free) / statbuf.f_blocks * 100)); - df_submit_one (disk_name, "df_complex_pct", "reserved", + df_submit_one (disk_name, "percent_bytes", "reserved", (gauge_t) ((float_t)(blk_reserved) / statbuf.f_blocks * 100)); - df_submit_one (disk_name, "df_complex_pct", "used", + df_submit_one (disk_name, "percent_bytes", "used", (gauge_t) ((float_t)(blk_used) / statbuf.f_blocks * 100)); } else return (-1); @@ -340,11 +340,11 @@ static int df_read (void) { if (statbuf.f_files > 0) { - df_submit_one (disk_name, "df_inodes_pct", "free", + df_submit_one (disk_name, "percent_inodes", "free", (gauge_t) ((float_t)(inode_free) / statbuf.f_files * 100)); - df_submit_one (disk_name, "df_inodes_pct", "reserved", + df_submit_one (disk_name, "percent_inodes", "reserved", (gauge_t) ((float_t)(inode_reserved) / statbuf.f_files * 100)); - df_submit_one (disk_name, "df_inodes_pct", "used", + df_submit_one (disk_name, "percent_inodes", "used", (gauge_t) ((float_t)(inode_used) / statbuf.f_files * 100)); } else return (-1); diff --git a/src/types.db b/src/types.db index 9ac3e0a9..f1d30f0d 100644 --- a/src/types.db +++ b/src/types.db @@ -30,8 +30,6 @@ delay value:GAUGE:-1000000:1000000 derive value:DERIVE:0:U df_complex value:GAUGE:0:U df_inodes value:GAUGE:0:U -df_complex_pct value:GAUGE:0:100.1 -df_inodes_pct value:GAUGE:0:100.1 df used:GAUGE:0:1125899906842623, free:GAUGE:0:1125899906842623 disk_latency read:GAUGE:0:U, write:GAUGE:0:U disk_merged read:DERIVE:0:U, write:DERIVE:0:U @@ -116,6 +114,8 @@ node_tx_rate value:GAUGE:0:127 objects value:GAUGE:0:U operations value:DERIVE:0:U percent value:GAUGE:0:100.1 +percent_bytes value:GAUGE:0:100.1 +percent_inodes value:GAUGE:0:100.1 pf_counters value:DERIVE:0:U pf_limits value:DERIVE:0:U pf_source value:DERIVE:0:U