++ed by:
KEEDI ABRAXXA INPHOBIA

3 PAUSE users
1 non-PAUSE user.

Author image Max Baker

NAME

SNMP::Info::CiscoStack - Intefaces to data from CISCO-STACK-MIB and CISCO-PORT-SECURITY-MIB

AUTHOR

Max Baker (max@warped.org)

SYNOPSIS

 # Let SNMP::Info determine the correct subclass for you. 
 my $ciscostats = new SNMP::Info(
                          AutoSpecify => 1,
                          Debug       => 1,
                          # These arguments are passed directly on to SNMP::Session
                          DestHost    => 'myswitch',
                          Community   => 'public',
                          Version     => 2
                        ) 
    or die "Can't connect to DestHost.\n";

 my $class      = $ciscostats->class();
 print "SNMP::Info determined this device to fall under subclass : $class\n";

DESCRIPTION

SNMP::Info::CiscoStack is a subclass of SNMP::Info that provides an interface to the CISCO-STACK-MIB. This MIB is used across the Catalyst family under CatOS and IOS.

Use or create in a subclass of SNMP::Info. Do not use directly.

Inherited Classes

none.

Required MIBs

CISCO-STACK-MIB
CISCO-PORT-SECURITY-MIB

MIBs can be found at ftp://ftp.cisco.com/pub/mibs/v2/v2.tar.gz or from Netdisco-mib package at netdisco.org.

GLOBALS

$stack->broadcast()

(sysBroadcast)

$stack->fan()

(chassisFanStatus)

$stack->model()

(chassisModel)

$stack->netmask()

(sysNetMask)

$stack->ps1_type()

(chassisPs1Type)

$stack->ps2_type()

(chassisPs2Type)

$stack->ps1_status()

(chassisPs1Status)

$stack->ps2_status()

(chassisPs2Status)

$stack->serial()

(chassisSerialNumberString) or (chassisSerialNumber)

$stack->slots()

(chassisNumSlots)

CISCO-PORT-SECURITY-MIB globals

See CISCO-PORT-SECURITY-MIB for details.

$stack->cps_clear()

cpsGlobalClearSecureMacAddresses

$stack->cps_notify()

cpsGlobalSNMPNotifControl

$stack->cps_rate()

cpsGlobalSNMPNotifRate

$stack->cps_enable()

cpsGlobalPortSecurityEnable

$stack->cps_mac_count()

cpsGlobalTotalSecureAddress

$stack->cps_mac_max()

cpsGlobalMaxSecureAddress

TABLE METHODS

Interface Tables

$stack->interfaces()

Crosses p_port() with i_index() to get physical names.

$stack->i_physical()

Returns a map to IID for ports that are physical ports, not vlans, etc.

$stack->i_type()

Crosses p_port() with p_type() and returns the results.

Overrides with ifType if p_type() isn't available.

$stack->i_name()

Crosses p_name with p_port and returns results.

$stack->i_duplex()

Crosses p_duplex with p_port and returns results.

$stack->i_duplex_admin()

Crosses p_duplex_admin with p_port.

Munges bit_string returned from p_duplex_admin to get duplex settings.

Module table

This table holds configuration information for each of the blades installed in the Catalyst device.

$stack->m_type()

(moduleType)

$stack->m_model()

(moduleModel)

$stack->m_serial()

(moduleSerialNumber)

$stack->m_status()

(moduleStatus)

$stack->m_name()

(moduleName)

$stack->m_ports()

(moduleNumPorts)

$stack->m_ports_status()

Returns a list of space separated status strings for the ports.

To see the status of port 4 :

    @ports_status = split(' ', $stack->m_ports_status() );
    $port4 = $ports_status[3];

(modulePortStatus)

$stack->m_ports_hwver()

(moduleHwVersion)

$stack->m_ports_fwver()

(moduleFwVersion)

$stack->m_ports_swver()

(moduleSwVersion)

$stack->m_ports_ip()

(moduleIPAddress)

$stack->m_ports_sub1()

(moduleSubType)

$stack->m_ports_sub2()

(moduleSubType2)

Modules - Router Blades

$stack->m_ip()

(moduleIPAddress)

$stack->m_sub1()

(moduleSubType)

$stack->m_sub2()

(moduleSubType2)

Port Entry Table (CISCO-STACK-MIB::portTable)

$stack->p_name()

(portName)

$stack->p_type()

(portType)

$stack->p_status()

(portOperStatus)

$stack->p_status2()

(portAdditionalStatus)

$stack->p_speed()

(portAdminSpeed)

$stack->p_duplex()

(portDuplex)

$stack->p_port()

(portIfIndex)

Port Capability Table (CISCO-STACK-MIB::portCpbTable)

$stack->p_speed_admin()

(portCpbSpeed)

$stack->p_duplex_admin()

(portCpbDuplex)

CISCO-PORT-SECURITY-MIB - Interface Config Table

See CISCO-PORT-SECURITY-MIB for details.

$stack->cps_i_limit_val()

cpsIfInvalidSrcRateLimitValue

$stack->cps_i_limit()

cpsIfInvalidSrcRateLimitEnable

$stack->cps_i_sticky()

cpsIfStickyEnable

$stack->cps_i_clear_type()

cpsIfClearSecureMacAddresses

$stack->cps_i_shutdown()

cpsIfShutdownTimeout

$stack->cps_i_flood()

cpsIfUnicastFloodingEnable

$stack->cps_i_clear()

cpsIfClearSecureAddresses

$stack->cps_i_mac()

cpsIfSecureLastMacAddress

$stack->cps_i_count()

cpsIfViolationCount

$stack->cps_i_action()

cpsIfViolationAction

$stack->cps_i_mac_static()

cpsIfStaticMacAddrAgingEnable

$stack->cps_i_mac_type()

cpsIfSecureMacAddrAgingType

$stack->cps_i_mac_age()

cpsIfSecureMacAddrAgingTime

$stack->cps_i_mac_count()

cpsIfCurrentSecureMacAddrCount

$stack->cps_i_mac_max()

cpsIfMaxSecureMacAddr

$stack->cps_i_status()

cpsIfPortSecurityStatus

$stack->cps_i_enable()

cpsIfPortSecurityEnable

CISCO-PORT-SECURITY-MIB::cpsIfVlanTable

$stack->cps_i_v_mac_count()

cpsIfVlanCurSecureMacAddrCount

$stack->cps_i_v_mac_max()

cpsIfVlanMaxSecureMacAddr

$stack->cps_i_v()

cpsIfVlanIndex

CISCO-PORT-SECURITY-MIB::cpsIfVlanSecureMacAddrTable

$stack->cps_i_v_mac_status()

cpsIfVlanSecureMacAddrRowStatus

$stack->cps_i_v_mac_age()

cpsIfVlanSecureMacAddrRemainAge

$stack->cps_i_v_mac_type()

cpsIfVlanSecureMacAddrType

$stack->cps_i_v_vlan()

cpsIfVlanSecureVlanIndex

$stack->cps_i_v_mac()

cpsIfVlanSecureMacAddress

CISCO-PORT-SECURITY-MIB::cpsSecureMacAddressTable

$stack->cps_m_status()

cpsSecureMacAddrRowStatus

$stack->cps_m_age()

cpsSecureMacAddrRemainingAge

$stack->cps_m_type()

cpsSecureMacAddrType

$stack->cps_m_mac()

cpsSecureMacAddress