Package: bindgraph
Version: 0.2-5
Severity: important
Hello,
i have problem graphing bind without escaping : in COMMENT line of rrd,
like in mailgraph(patch "stolen" from mailgraph)
(patch also enables commented out rendering of max values?)
cu
libor
-- System Information:
Debian Release: testing/unstable
APT prefers testing
APT policy: (500, 'testing')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.4.27-2-686-smp
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Versions of packages bindgraph depends on:
ii debconf [debconf-2.0] 1.4.30.10 Debian configuration management sy
ii libfile-tail-perl 0.98-5 File::Tail perl module
ii librrds-perl 1.2.11-0.5 Time-series data storage and displ
Versions of packages bindgraph recommends:
ii apache [httpd] 1.3.33-2 Versatile, high-performance HTTP s
ii apache-ssl [httpd] 1.3.33-2 Versatile, high-performance HTTP s
ii bind9 1:9.3.2-2 Internet Domain Name Server
-- debconf information:
* bindgraph/logfile: /var/log/bind9-query.log
* bindgraph/configure_bind:
* bindgraph/stay_on_purge: false
* bindgraph/start_on_boot: true
--- bindgraph.cgi.orig 2006-05-11 01:57:22.000000000 +0200
+++ bindgraph.cgi 2006-06-24 17:57:24.000000000 +0200
@@ -67,7 +67,7 @@
"DEF:$_=$rrd:$_:AVERAGE",
"DEF:m$_=$rrd:$_:MAX",
"CDEF:r$_=$_,60,*",
- # "CDEF:rm$_=m$_,60,*",
+ "CDEF:rm$_=m$_,60,*",
"CDEF:d$_=$_,UN,0,$_,IF,$step,*",
"CDEF:s$_=PREV,UN,d$_,PREV,IF,d$_,+"
) } @query_t;
@@ -93,6 +93,11 @@
}
}
+ my $date = localtime(time);
+ $date =~ s|:|\\:|g unless $RRDs::VERSION < 1.199908;
+ my $last = localtime(last_update($rrd));
+ $last =~ s|:|\\:|g unless $RRDs::VERSION < 1.199908;
+
my ($text, $xs, $ys) = RRDs::graph(
$file,
'--imgformat', 'PNG',
@@ -106,8 +111,7 @@
@rrdef,
@rrprint,
'COMMENT:\s',
- 'COMMENT:last update: ' . localtime(last_update($rrd))
- . ' graph created on ' . localtime(time) . '\r',
+ 'COMMENT:last update\: ' . $last . ' graph created on ' .
$date . '\r',
);
my $err = RRDs::error;
die_fatal("RRDs::graph($file, ...): $err") if $err;