mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-27 03:07:43 +02:00
fixed collection deamon integration
git-svn-id: http://svn.ipfire.org/svn/ipfire/branches/2.1/trunk@1175 ea5c0bd1-69bd-2848-81d8-4f18e57aeed8
This commit is contained in:
@@ -51,7 +51,6 @@ if ($cgigraphs[1] =~ /(cpu)/) {&Graphs::updatecpugraph ("hour");&Graphs::updatec
|
||||
if ($cgigraphs[1] =~ /(memory|swap)/) {&Graphs::updatememgraph ("hour");&Graphs::updatememgraph ("week");&Graphs::updatememgraph ("month");&Graphs::updatememgraph ("year");}
|
||||
if ($cgigraphs[1] =~ /disk/){
|
||||
my @devices = `kudzu -qps -c HD | grep device: | cut -d" " -f2 | sort | uniq`;
|
||||
push(@devices,"uba");
|
||||
foreach (@devices) {
|
||||
my $device = $_;
|
||||
chomp($device);
|
||||
|
||||
@@ -151,10 +151,10 @@ sub graphbox {
|
||||
|
||||
&Header::openbox('100%', 'center', "$graph $Lang::tr{'graph'}");
|
||||
if (-e "$graphdir/mbmon-$graph-week.png"){
|
||||
my $ftime = localtime((stat("$graphdir/mbmon-$graph-day.png"))[9]);
|
||||
my $ftime = localtime((stat("$graphdir/mbmon-$graph-week.png"))[9]);
|
||||
print "<center>";
|
||||
print "<b>$Lang::tr{'the statistics were last updated at'}: $ftime</b></center><br />\n";
|
||||
print "<img src='/graphs/mbmon-$graph-day.png' border='0' /><hr />";
|
||||
print "<img src='/graphs/mbmon-$graph-week.png' border='0' /><hr />";
|
||||
}
|
||||
else{print $Lang::tr{'no information available'};}
|
||||
&Header::closebox();
|
||||
|
||||
@@ -51,7 +51,7 @@ $cgiparams[1] = '' unless defined $cgiparams[1];
|
||||
if ($cgiparams[1] =~ /red/) {
|
||||
&Header::openpage($Lang::tr{'network traffic graphs external'}, 1, '');
|
||||
push (@graphs, ($netsettings{'RED_DEV'}));
|
||||
push (@graphs, ("ipsec0"));
|
||||
if (-e "/var/log/rrd/collectd/localhost/interface/if_octets-ipsec0.rrd") {push (@graphs, ("ipsec0"));
|
||||
}elsif ($cgiparams[1] =~ /other/) {
|
||||
&Header::openpage($Lang::tr{'network traffic graphs others'}, 1, '');
|
||||
push (@graphs, ("lq"));
|
||||
|
||||
Reference in New Issue
Block a user