A class for performing SNMP V2 queries on Cisco devices

copyright Copyright (c) 2012, Open Source Solutions Limited, Dublin, Ireland
author Barry O'Donovan

 Methods

Get the device's RSTP port roles (by given vlan id)

rstpPortRole(int $vid, boolean $translate) : array

Only ports participating in RSTP for the given VLAN id are returned.

This function will also convert STP port IDs to the device proper port IDs. E.g. sample output:

Array ( [10101] => 3 [10103] => 3 [10105] => 3 [5048] => 2 )

see \$STP_X_RSTP_PORT_ROLES
see \STP_X_RSTP_PORT_ROLE_ROOT

Parameters

$vid

int

The RSTP VLAN ID to query port roles for

$translate

boolean

If true, return the string representation via self::$STP_X_RSTP_PORT_ROLES

Returns

arrayThe device's RSTP port roles (by given vlan id)

Get the device's VTP VLAN names (indexed by VLAN ID)

vlanNames() : array

Returns

arrayThe device's VTP VLAN names (indexed by VLAN ID)

Get the device's VTP VLAN States (indexed by VLAN ID)

vlanStates(boolean $translate) : array

see \$VTP_VLAN_STATES
see \VTP_VLAN_STATE_OPERATIONAL

Parameters

$translate

boolean

If true, return the string representation via self::$VTP_VLAN_TYPES

Returns

arrayThe device's VTP VLAN States (indexed by VLAN ID)

Get the device's VTP VLAN Types (indexed by VLAN ID)

vlanTypes(boolean $translate) : array

see \$VTP_VLAN_TYPES
see \VTP_VLAN_TYPE_ETHERNET

Parameters

$translate

boolean

If true, return the string representation via self::$VTP_VLAN_TYPES

Returns

arrayThe device's VTP VLAN types (indexed by VLAN ID)

 Properties

 

$STP_X_RSTP_PORT_ROLES

$STP_X_RSTP_PORT_ROLES 

 

$VTP_VLAN_STATES

$VTP_VLAN_STATES 

 

$VTP_VLAN_TYPES

$VTP_VLAN_TYPES 

 Constants

 

OID_STP_X_RSTP_PORT_ROLE

OID_STP_X_RSTP_PORT_ROLE 

 

OID_VTP_VLAN_NAME

OID_VTP_VLAN_NAME 

 

OID_VTP_VLAN_STATUS

OID_VTP_VLAN_STATUS 

 

OID_VTP_VLAN_TYPE

OID_VTP_VLAN_TYPE 

 

STP_X_RSTP_PORT_ROLE_ALTERNATE

STP_X_RSTP_PORT_ROLE_ALTERNATE 

 

STP_X_RSTP_PORT_ROLE_BACKUP

STP_X_RSTP_PORT_ROLE_BACKUP 

 

STP_X_RSTP_PORT_ROLE_BOUNDARY

STP_X_RSTP_PORT_ROLE_BOUNDARY 

 

STP_X_RSTP_PORT_ROLE_DESIGNATED

STP_X_RSTP_PORT_ROLE_DESIGNATED 

 

STP_X_RSTP_PORT_ROLE_DISABLED

STP_X_RSTP_PORT_ROLE_DISABLED 

 

STP_X_RSTP_PORT_ROLE_MASTER

STP_X_RSTP_PORT_ROLE_MASTER 

 

STP_X_RSTP_PORT_ROLE_ROOT

STP_X_RSTP_PORT_ROLE_ROOT 

 

VTP_VLAN_STATE_MTU_TOO_BIG_FOR_DEVICE

VTP_VLAN_STATE_MTU_TOO_BIG_FOR_DEVICE 

 

VTP_VLAN_STATE_MTU_TOO_BIG_FOR_TRUNK

VTP_VLAN_STATE_MTU_TOO_BIG_FOR_TRUNK 

 

VTP_VLAN_STATE_OPERATIONAL

VTP_VLAN_STATE_OPERATIONAL 

 

VTP_VLAN_STATE_SUSPENDED

VTP_VLAN_STATE_SUSPENDED 

 

VTP_VLAN_TYPE_DEPRECATED

VTP_VLAN_TYPE_DEPRECATED 

 

VTP_VLAN_TYPE_ETHERNET

VTP_VLAN_TYPE_ETHERNET 

 

VTP_VLAN_TYPE_FDDI

VTP_VLAN_TYPE_FDDI 

 

VTP_VLAN_TYPE_FDDI_NET

VTP_VLAN_TYPE_FDDI_NET 

 

VTP_VLAN_TYPE_TOKEN_RING

VTP_VLAN_TYPE_TOKEN_RING 

 

VTP_VLAN_TYPE_TR_NET

VTP_VLAN_TYPE_TR_NET