[rrd-users] QOS Help
Cassie Bezuidenhout
cassieb at ifusion.co.za
Fri Dec 19 06:50:29 MET 2003
Content-Type: text/plain
Hi All
I created the attached script to pull information from our internet router
to get values for passing through to RRD. In principal it works but it is
extremely slow and I am a bit worried about the order. I need the script to
complete both walks before moving on to the second device as the same values
might appear. Currently the attached script walks through and gives me the
results, but it is taking far too long.
Any help would be much appreciated....
#!/usr/local/lib/perl
BEGIN {
open (STDERR, ">/usr/local/nmis/cbwfq/error.txt");
}
use lib "/usr/local/nmis/lib";
use SNMP::Util;
$SNMP::Util::Max_log_level = 'debug';
use BER;
#use SNMP_util "0.90";
use SNMP_util;
$BER::pretty_print_timeticks = 0; # Uptime in absolute value
@IP_array = ('my-ip-one',' my-ip-two ',' my-ip-three ');
$community = 'my-community';
$first = '1.3.6.1.4.1.9.9.166.1.7.1.1.1';
$second = '1.3.6.1.4.1.9.9.166.1.5.1.1.2';
foreach $IP (@IP_array) {
@Config1 = (&snmpwalk("$community\@$IP", $first));
foreach $Config1 (@Config1) {
($oid1, $Config1) = split(':', $Config1, 2);
# print "$oid1 = $Config1\n";
@Config2 = (&snmpwalk("$community\@$IP", $second));
foreach $Config2 (@Config2) {
($oid2, $Config2) = split(':', $Config2, 2);
# print "$oid2 = $Config2\n";
if ($oid1 == $Config2) {
print "$Config1 = $oid2\n";
}
}
}
}
Cassie Bezuidenhout
* +27 11 256-0531
* +27 83 677 0767
* cassieb at ifusion.co.za
-- Attached file removed by Ecartis and put at URL below --
-- Type: image/jpeg
-- Size: 3k (4088 bytes)
-- URL : http://www.ee.ethz.ch/~slist/p/11-image001.jpg
-- Attached file removed by Ecartis and put at URL below --
-- Type: image/jpeg
-- Size: 2k (3024 bytes)
-- URL : http://www.ee.ethz.ch/~slist/p/02-image002.jpg
--
Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
More information about the rrd-users
mailing list