From f0fb35113735f8fec011c35125e4496d0bb2e1a7 Mon Sep 17 00:00:00 2001 From: Christoph Neuhaus Date: Wed, 2 Oct 2019 18:40:38 +0200 Subject: [PATCH] detect ios-xe versions which use codenames (#359) * Cisco is using codenames for ios-xe > 16.x Example description: Cisco IOS Software [Everest], Catalyst L3 Switch Software (CAT3K_CAA-UNIVERSALK9-M), Version 16.6.6, RELEASE SOFTWARE (fc1) Technical Support: http://www.cisco.com/techsupport Copyright (c) 1986-2019 by Cisco Systems, Inc. Compiled Thu 11-Apr-19 02:24 * Gibraltar Codename added --- lib/SNMP/Info/CiscoStats.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/SNMP/Info/CiscoStats.pm b/lib/SNMP/Info/CiscoStats.pm index bd17ddb8..a1f729c2 100644 --- a/lib/SNMP/Info/CiscoStats.pm +++ b/lib/SNMP/Info/CiscoStats.pm @@ -105,6 +105,10 @@ sub os { # order here matters - there are Catalysts that run IOS and have catalyst # in their description field, as well as Catalysts that run IOS-XE. + return 'ios-xe' if ( $descr =~ /Denali/ ); + return 'ios-xe' if ( $descr =~ /Fuji/ ); + return 'ios-xe' if ( $descr =~ /Everest/ ); + return 'ios-xe' if ( $descr =~ /Gibraltar/ ); return 'ios-xe' if ( $descr =~ /IOS-XE/ ); return 'ios-xr' if ( $descr =~ /IOS XR/ ); return 'ios' if ( $descr =~ /IOS/ );