2014-06-11 14:42:42 +00:00
|
|
|
--- a/src/rrdtool.c
|
|
|
|
+++ b/src/rrdtool.c
|
2014-09-09 16:45:14 +00:00
|
|
|
@@ -82,6 +82,7 @@ static const char *config_keys[] =
|
2014-06-11 14:42:42 +00:00
|
|
|
"HeartBeat",
|
|
|
|
"RRARows",
|
|
|
|
"RRATimespan",
|
|
|
|
+ "RRASingle",
|
|
|
|
"XFF",
|
|
|
|
"WritesPerSecond",
|
|
|
|
"RandomTimeout"
|
2014-09-09 16:45:14 +00:00
|
|
|
@@ -103,6 +104,8 @@ static rrdcreate_config_t rrdcreate_conf
|
2014-06-11 14:42:42 +00:00
|
|
|
/* timespans = */ NULL,
|
|
|
|
/* timespans_num = */ 0,
|
|
|
|
|
|
|
|
+ /* rrasingle = */ 0,
|
|
|
|
+
|
|
|
|
/* consolidation_functions = */ NULL,
|
2014-09-09 16:45:14 +00:00
|
|
|
/* consolidation_functions_num = */ 0,
|
|
|
|
|
2016-02-03 16:47:51 +00:00
|
|
|
@@ -1110,6 +1113,14 @@ static int rrd_config (const char *key,
|
2014-06-11 14:42:42 +00:00
|
|
|
|
|
|
|
free (value_copy);
|
|
|
|
}
|
|
|
|
+ else if (strcasecmp ("RRASingle", key) == 0)
|
|
|
|
+ {
|
|
|
|
+ if (IS_TRUE (value))
|
|
|
|
+ {
|
|
|
|
+ rrdcreate_config.rrasingle = 1;
|
|
|
|
+ NOTICE ("rrdtool plugin: RRASingle = true: creating only AVERAGE RRAs");
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
else if (strcasecmp ("XFF", key) == 0)
|
|
|
|
{
|
|
|
|
double tmp = atof (value);
|
|
|
|
--- a/src/utils_rrdcreate.c
|
|
|
|
+++ b/src/utils_rrdcreate.c
|
2016-02-03 16:47:51 +00:00
|
|
|
@@ -213,6 +213,9 @@ static int rra_get (char ***ret, const v
|
2014-06-11 14:42:42 +00:00
|
|
|
rts_num = rra_timespans_num;
|
|
|
|
}
|
|
|
|
|
|
|
|
+ if (cfg->rrasingle)
|
|
|
|
+ rra_types_num = 1;
|
|
|
|
+
|
|
|
|
rra_max = rts_num * rra_types_num;
|
2016-02-03 16:47:51 +00:00
|
|
|
assert (rra_max > 0);
|
2014-06-11 14:42:42 +00:00
|
|
|
|
|
|
|
--- a/src/utils_rrdcreate.h
|
|
|
|
+++ b/src/utils_rrdcreate.h
|
collectd: update to 5.5.0
Update collectd, base of Luci statistics, to 5.5.0.
Patches have been refreshed.
write-graphite plugin is now enabled. (see #1351)
I have compile-tested all plugins with ar71xx,
and real-life tested the following plugins:
Conntrack, Processor (CPU), DNS, Interfaces, Wireless, System Load,
Memory, Ping, Uptime
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2015-07-16 12:15:22 +00:00
|
|
|
@@ -41,6 +41,8 @@ struct rrdcreate_config_s
|
2014-06-11 14:42:42 +00:00
|
|
|
int *timespans;
|
|
|
|
size_t timespans_num;
|
|
|
|
|
|
|
|
+ int rrasingle;
|
|
|
|
+
|
|
|
|
char **consolidation_functions;
|
|
|
|
size_t consolidation_functions_num;
|
2014-09-09 16:45:14 +00:00
|
|
|
|