ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/reports/rrdgraphing/watch.pl
(Generate patch)

Comparing projects/cms/source/reports/rrdgraphing/watch.pl (file contents):
Revision 1.6 by tdb, Mon Mar 10 11:34:43 2003 UTC vs.
Revision 1.8 by tdb, Sun Aug 1 10:40:32 2004 UTC

# Line 2 | Line 2
2  
3   #
4   # i-scream central monitoring system
5 < # http://www.i-scream.org.uk
5 > # http://www.i-scream.org
6   # Copyright (C) 2000-2002 i-scream
7   #
8   # This program is free software; you can redistribute it and/or
# Line 22 | Line 22
22  
23   # -----------------------------------------------------------
24   # i-scream graph generation scripts
25 < # http://www.i-scream.org.uk
25 > # http://www.i-scream.org
26   #
27   # Generates rrd databases for i-scream data by connecting to
28   # the i-scream server and collecting data.
# Line 31 | Line 31
31   # $Id$
32   #------------------------------------------------------------
33  
34 + BEGIN {
35 +    push (@INC, "/usr/local/packages/rrdtool/lib/perl5/site_perl/5.8.2/sun4-solaris");
36 + }
37 +
38   my($version) = '$Id$';
39  
40   $| = 1;
# Line 259 | Line 263 | sub processdata() {
263              # mem
264              @data = ( "packet.memory.free:free:GAUGE",
265                        "packet.memory.total:total:GAUGE",
266 +                      "packet.memory.cache:cache:GAUGE",
267                       );
268              &updaterrd($machine, "mem", $date, $rrdstep, \%xmlhash, @data);
269                      
# Line 328 | Line 333 | sub processdata() {
333                  @data = ( "packet.net.p$i.attributes.rx:rx:GAUGE",
334                            "packet.net.p$i.attributes.tx:tx:GAUGE",
335                           );
336 <                &updaterrd($machine, "net-$name", $date, $rrdstep, \%xmlhash,
337 < @data);
336 >                &updaterrd($machine, "net-$name", $date, $rrdstep, \%xmlhash, @data);
337 >                ++$i
338 >            }
339 >
340 >            # mailq
341 >            $i = 0;
342 >            while(defined $xmlhash{"packet.mailq.p$i.attributes.name"}) {
343 >                my($name) = $xmlhash{"packet.mailq.p$i.attributes.name"};
344 >                $name =~ s/\s+//g;
345 >                @data = ( "packet.mailq.p$i.attributes.size:size:GAUGE",
346 >                         );
347 >                &updaterrd($machine, "mailq-$name", $date, $rrdstep, \%xmlhash, @data);
348                  ++$i
349              }
350          }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines