From f12cc78c04d6f2983f2ddb3df474fe1bac766c02 Mon Sep 17 00:00:00 2001 From: Neil Lathwood Date: Mon, 27 Apr 2015 09:39:11 +0100 Subject: [PATCH] Revert "Fix filename for rrdcached usage." --- includes/rrdtool.inc.php | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/includes/rrdtool.inc.php b/includes/rrdtool.inc.php index b9f81ba299..d00d5105ed 100644 --- a/includes/rrdtool.inc.php +++ b/includes/rrdtool.inc.php @@ -150,17 +150,10 @@ function rrdtool($command, $filename, $options) { global $config, $debug, $rrd_pipes, $console_color; + $cmd = "$command $filename $options"; if ($command != "create" && $config['rrdcached']) { - $filename = str_replace($config['install_dir'],"",$filename); - //Some people tend to end paths with '/', let's tolerate that - if( $filename[0] == "/" ) { - $filename = substr($filename,1); - } - $filename = str_replace("rrd/","",$filename); //Make sure you use -b /opt/librenms/rrd on your rrdcached! - $cmd = "$command $filename $options --daemon " . $config['rrdcached']; - } else { - $cmd = "$command $filename $options"; + $cmd .= " --daemon " . $config['rrdcached']; } if ($config['norrd'])