Skip Menu |
 

This queue is for tickets about the SNMP-Info CPAN distribution.

Report information
The Basics
Id: 86725
Status: resolved
Priority: 0/
Queue: SNMP-Info

People
Owner: OLIVER [...] cpan.org
Requestors: christopher.causer [...] it.ox.ac.uk
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



From christopher.causer [...] it.ox.ac.uk Fri Jul 5 05: 17:14 2013
MIME-Version: 1.0
X-Spam-Status: No, score=-6.9 tagged_above=-99.9 required=10 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5] autolearn=ham
Content-Disposition: inline
X-Spam-Flag: NO
content-type: text/plain; charset="utf-8"
Message-ID: <20130705091655.GA9202 [...] kubuntu-raring.oucs.ox.ac.uk>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Spam-Score: -6.9
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 60A54240ED4 for <cpan-bug+snmp-info [...] hipster.bestpractical.com>; Fri, 5 Jul 2013 05:17:14 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SMFXJoIMXkRi for <cpan-bug+snmp-info [...] hipster.bestpractical.com>; Fri, 5 Jul 2013 05:17:13 -0400 (EDT)
Received: from la.mx.develooper.com (x1.develooper.com [207.171.7.70]) by hipster.bestpractical.com (Postfix) with SMTP id B769C240ECF for <bug-snmp-info [...] rt.cpan.org>; Fri, 5 Jul 2013 05:17:12 -0400 (EDT)
Received: (qmail 21003 invoked by alias); 5 Jul 2013 09:17:12 -0000
Received: from relay14.mail.ox.ac.uk (HELO relay14.mail.ox.ac.uk) (163.1.2.162) by la.mx.develooper.com (qpsmtpd/0.28) with ESMTP; Fri, 05 Jul 2013 02:17:02 -0700
Received: from smtp2.mail.ox.ac.uk ([163.1.2.205]) by relay14.mail.ox.ac.uk with esmtp (Exim 4.80) (envelope-from <christopher.causer [...] it.ox.ac.uk>) id 1Uv28P-0007UC-jR for bug-snmp-info [...] rt.cpan.org; Fri, 05 Jul 2013 10:16:57 +0100
Received: from clom.oucs.ox.ac.uk ([129.67.102.16] helo=kubuntu-raring.oucs.ox.ac.uk) by smtp2.mail.ox.ac.uk with esmtps (TLSv1:AES128-SHA:128) (Exim 4.69) (envelope-from <christopher.causer [...] it.ox.ac.uk>) id 1Uv28O-0000li-98 for bug-snmp-info [...] rt.cpan.org; Fri, 05 Jul 2013 10:16:57 +0100
Delivered-To: cpan-bug+snmp-info [...] hipster.bestpractical.com
User-Agent: Mutt/1.5.21 (2012-12-30)
Subject: Cisco Catalyst 3850/IOS 15 wrong device type
Return-Path: <christopher.causer [...] it.ox.ac.uk>
X-RT-Mail-Extension: snmp-info
X-Original-To: cpan-bug+snmp-info [...] hipster.bestpractical.com
X-Spam-Check-BY: la.mx.develooper.com
Date: Fri, 5 Jul 2013 10:16:55 +0100
X-Spam-Level:
To: bug-snmp-info [...] rt.cpan.org
From: Christopher Causer <christopher.causer [...] it.ox.ac.uk>
X-RT-Original-Encoding: ascii
X-RT-Interface: Email
Content-Length: 2347
Download (untitled) / with headers
text/plain 2.2k
Hello SNMP::Info maintainers, I was having some difficulty using our instance of Netdisco, which was not recognizing native vlans for a port for some of our switches. Digging through the source, I noticed that switches that did have native vlans for ports were all Cisco Catalyst 3750s whereas the one I was troubleshooting was a 3850. Digging further, I saw that there was a regex to match a 3750 to a device type SNMP::Info::Layer3::C6500. The sysdesc of the offending 3850 switch is -------------------------------------->8------ "Cisco IOS Software, Catalyst L3 Switch Software (CAT3K_CAA-UNIVERSALK9-M), Version 15.0(1)EX1, RELEASE SOFTWARE (fc1) Technical Support: http://www.cisco.com/techsupport Copyright (c) 1986-2013 by Cisco Systems, Inc. Compiled Wed 20-Mar-13 17:10 by pro" -------------------------------------->8------ which means it is palmed off to SNMP::Info::Layer3::Cisco by the function &SNMP::Info::device_type. In the SNMP::Info::Layer3::Cisco module, &i_vlan returns {} for this particular switch, which is why netdisco thinks that the switch has no access ports for any vlans. However, if I added a regex into the device_type function mentioned above to try to coerce this switch into a C6500, everything worked fine (or at least it fixed the problem we were experiencing.) -------------------------------------->8------ diff --git a/Info.pm b/Info.pm index 5860be3..48388fd 100644 --- a/Info.pm +++ b/Info.pm @@ -1454,6 +1454,11 @@ sub device_type { $objtype = 'SNMP::Info::Layer3::C6500' if ( $desc =~ /cisco/i and $desc =~ /3750/ ); + # IOS 15 on a Catalyst 3850 + $objtype = 'SNMP::Info::Layer3::C6500' + if ( $desc =~ /cisco/i and $desc =~ /CAT3K/ ); + # Cisco 2970 $objtype = 'SNMP::Info::Layer3::C6500' if ( $desc =~ /(C2970|C2960)/ ); -------------------------------------->8------ This diff is against the latest stable release downloaded from CPAN. I will be the first to admit my limited skills with SNMP, Cisco IOS and pretty much everything inbetween. As such, if I have omitted anything from this bug report please let me know and I will try my best to answer. -- Christopher Causer IT Services, University of Oxford Network Support and Development Officer 13 Banbury Road, Oxford, OX2 6NN
MIME-Version: 1.0
In-Reply-To: <20130705091655.GA9202 [...] kubuntu-raring.oucs.ox.ac.uk>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <20130705091655.GA9202 [...] kubuntu-raring.oucs.ox.ac.uk>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.13-17467-1373315861-1947.86725-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 223
Download (untitled) / with headers
text/plain 223b
Hi Christopher, I've added your patch, and pushed a new release (with some other changes): http://cpan.metacpan.org/authors/id/O/OL/OLIVER/SNMP-Info-3.02.tar.gz Many thanks indeed for your contribution! regards, oliver.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.