Discussion:
[rancid] Cisco APs and RANCID 3.1 => traffic counters in output
Howard Jones
2014-06-17 14:25:51 UTC
Permalink
I've just upgraded from 2.8.x to 3.1, and it's nice that I don't get
hourly updates on files on our ASRs anymore. However, what I get now
instead is byte counters per-VLAN from our Cisco WAPs :-)

- !VLAN:21689 packets, 8176753 bytes output

- !VLAN:Other0173501

- !VLAN:25937 packets, 10671062 bytes input

- !VLAN:151812 packets, 11928977 bytes output

+ !VLAN:22023 packets, 8302671 bytes output

+ !VLAN:Other 0176177

+ !VLAN:26337 packets, 10835508 bytes input

+ !VLAN:154154 packets, 12113161 bytes output


Before I dig in to fix it, has anyone already done that?

Cheers,

Howie
Howard Jones
2014-06-18 12:56:29 UTC
Permalink
Answering my own question, here's a small patch to remove the counter
data from 'show vlan' for a Cisco Aironet WAP.

--- rancid-3.1/lib/ios.pm 2014-05-28 10:39:39.000000000 +0100
+++ lib/rancid/ios.pm 2014-06-17 19:37:17.000000000 +0100
@@ -393,7 +393,10 @@
$type = "12000";
} elsif ($proc =~ /1240[48]\/(GRP|PRP)/ || $proc =~
/1241[06]\/(GRP|PRP)/) {
$type = "12400";
- } else {
+ } elsif ($proc =~ /AIR-L?AP1[12][1234][[1234]/ ) {
+ $type="Aironet";
+ $device="wireless access point";
+ } else {
$type = $proc;
}

@@ -1786,6 +1789,10 @@
}

next if (/total.*packets.*(input|output)/i);
+ # Aironet AP's traffic counters
+ next if (/\d+\s+bytes.*(input|output)/i);
+ next if (/^\s*Other\s+\d+\s+\d+\s*$/i);
+ next if (/^\s*Bridging\s+Bridge.Group.\d+\s+\d+\s+\d+\s*$/i);

ProcessHistory("COMMENTS","keysort","IO","!VLAN: $_");
}

Loading...