From c8ba28a1e3007930b0f34483c0388a95a7e9535e Mon Sep 17 00:00:00 2001 From: Richard Mayhew Date: Sat, 4 Feb 2017 20:19:46 +0200 Subject: [PATCH] feature: updated rrdcached stats app to support Fedora/Centos (#5768) * feature: updated rrdcached stats app to support Fedora/Centos * tabs to spaces --- includes/polling/applications/rrdcached.inc.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/polling/applications/rrdcached.inc.php b/includes/polling/applications/rrdcached.inc.php index c71e6dd7a5..c727c93780 100644 --- a/includes/polling/applications/rrdcached.inc.php +++ b/includes/polling/applications/rrdcached.inc.php @@ -38,9 +38,11 @@ if ($agent_data['app'][$name]) { $sock = fsockopen($device['hostname'], 42217, $errno, $errstr, 5); - if (!$sock && $device['hostname'] == 'localhost') { + if (!$sock) { if (file_exists('/var/run/rrdcached.sock')) { $sock = fsockopen('unix:///var/run/rrdcached.sock'); + } elseif (file_exists('/var/run/rrdcached/rrdcached.sock')) { + $sock = fsockopen('unix:///var/run/rrdcached/rrdcached.sock'); } elseif (file_exists('/run/rrdcached.sock')) { $sock = fsockopen('unix:///run/rrdcached.sock'); } elseif (file_exists('/tmp/rrdcached.sock')) {