From 5e93cd834b2f203d6adafc80a9eac603a116efd7 Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Wed, 23 Apr 2025 12:45:44 +0200 Subject: [PATCH] ids.cgi: Show graph only when all RRDs exist Signed-off-by: Michael Tremer --- html/cgi-bin/ids.cgi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/html/cgi-bin/ids.cgi b/html/cgi-bin/ids.cgi index 4eaf4911d..960e72ef1 100644 --- a/html/cgi-bin/ids.cgi +++ b/html/cgi-bin/ids.cgi @@ -1102,7 +1102,9 @@ END &Header::closesection(); # Throughput Graph - if (-e "/var/log/rrd/collectd/localhost/iptables-mangle-IPS/ipt_bytes-BYPASSED.rrd") { + if (-e "/var/log/rrd/collectd/localhost/iptables-mangle-IPS/ipt_bytes-BYPASSED.rrd" + && -e "/var/log/rrd/collectd/localhost/iptables-mangle-IPS/ipt_bytes-SCANNED.rrd" + && -e "/var/log/rrd/collectd/localhost/iptables-mangle-IPS/ipt_bytes-WHITELISTED.rrd") { &Header::graph("$Lang::tr{'ips throughput'}", "ids.cgi", "ips-throughput", "day"); } -- 2.39.5