Introduction
This is a continuation of the previous document of the case study on Computing accurately Overall Link Throughput.
When calculating interfaces Throughput; it is always beneficial to compare the throughput calculated directly with the registered errors on the same interface and at the same time instance. This can only be possible Using our SOSL POLL function to bind the counters and device timestamp necessary to calculate the throughput with the error counters using the same SNMP Get-Request message.
Solution Overview
This management solution focuses on managing ONLY Serial WAN type interfaces that are NOT in a down administrative state as is set by the network administrator on the managed network devices.
The solution defines a module name, description, and initiates the polling process under which the Devices in the specified AMZ are fed into the polling SNMP engine. interfaces descriptions ifDescr MIB Objects are polled and mapped to their corresponding interfaces indexes. A variable handler is then defined to store the values of the polled ifAdminStatus, ifType, and IfOperStatus MIB Objects. Interfaces ‘up’ and of type point-to-point serial with an operational state of ‘up’ will then have their inbound octet counters, system up time, discontinuity time polled along with the number of Errors and Discards for the particular interface all bundled in a single SNMP data unit representing the Get-Request message.
The MIB Objects values are then stored into the appropriate variable handlers for two consecutive polls which are subtracted form each other using the SOSL function CounterData which stores the results in the database.
Finally the management process script stores the second set of handler values in the first set of handler variables and polls the devices to populate the second set again. This process is repeated every 300 seconds (5 minutes).
SOSL Based Management Process Script Configuration
MODULE IfThroughput&Errors ();
DESCRIPTION "Interface Throughput Calculation With errors";
BEGIN
MSG-MGR("Interface Throughput Calculation with Errors..");
ALL-DEV (ZONE "RomeNet") BY DEV
{
SET-INDEX ifTable ( ifDescr [ ifIndex, INT ] );
WITH-INDEX ifTable
{
POLL (ifType; ifAdminStatus;ifOperStatus);
DEFINE ifType DB DISPL;
DEFINE ifAdminStatus DB DISPL;
DEFINE ifOperStatus DB DISPL;
IF ( ifAdminStatus == "^up$")
THEN
IF ( ifTypeVar == "^ppp$" )
THEN
IF ( ifOperStatus == "^up$")
THEN
DEFINE ifInOctetsT1 MAP INT;
DEFINE ifInErrorsT1 MAP INT;
DEFINE ifInDiscardsT1 MAP INT;
POLL ( ifInOctets;
ifInErrors;
ifInDiscards;
sysUpTime;
ifCounterDiscontinuityTime);
DEFINE ifInOctets DB INT;
DEFINE ifInErrors DB INT;
DEFINE ifInDiscards DB INT;
IfInOctetsT1 = ifInOctets;
ifInErrorsT1 = ifInErrors;
ifInDiscardsT1 = ifInDiscards;
DEFINE sysUpTime DB INT;
DEFINE ifCounterDiscontinuityTime DB INT;
DEFINE Time1 MAP INT;
DEFINE ifDisconTime1 MAP INT;
Time1 = sysUpTime;
ifDisconTime1= ifCounterDiscontinuityTime;
ENDIF;
ENDIF;
ENDIF;
};
};
POLL-FREQ 10
{
WAIT (3000);
ALL-DEV (ZONE "RomeNet") BY DEV
{
SET-INDEX ifTable ( ifDescr [ ifIndex, INT ] );
WITH-INDEX ifTable
{
POLL (ifType; ifAdminStatus;ifOperStatus);
DEFINE ifType DB DISPL;
DEFINE ifAdminStatus DB DISPL;
DEFINE ifOperStatus DB DISPL;
IF ( ifAdminStatus == "^up$")
THEN
IF ( ifTypeVar == "^ppp$" )
THEN
IF ( ifOperStatus == "^up$")
THEN
DEFINE ifInOctetsT2 MAP INT;
DEFINE ifInErrorsT2 MAP INT;
DEFINE ifInDiscardsT2 MAP INT;
POLL ( ifInOctets;
ifInErrors;
ifInDiscards;
sysUpTime;
ifCounterDiscontinuityTime);
DEFINE ifInOctets DB INT;
DEFINE ifOutOctets DB INT;
DEFINE ifInErrors DB INT;
DEFINE ifInDiscards DB INT;
ifInOctetsT2 = ifInOctets;
ifInErrorsT2 = ifInErrors;
ifInDiscardsT2 = ifInDiscards;
DEFINE sysUpTime DB INT;
DEFINE ifCounterDiscontinuityTime DB INT;
DEFINE Time2 MAP INT;
DEFINE ifDisconTime2 MAP INT;
Time2 = sysUpTime;
ifDisconTime2 = ifCounterDiscontinuityTime;
ENDIF;
ENDIF;
ENDIF;
CounterData ( ifInOctets, ifInOctetsT1, ifInOctetsT2);
CounterData ( ifInErrors, ifInErrorsT1, ifInErrorsT2);
CounterData ( ifInDiscards, ifInDiscardsT1, ifInDiscardsT2);
DEFINE DeltaT MAP INT;
DeltaT = Time2 – Time1;
DEFINE ifDisconTime MAP INT;
ifDisconTime = ifDisconTime2 – ifDisconTime1;
IF (ifDisconTime == 0)
THEN
DEFINE InThroughput DB INT;
InThroughput = (ifInOctets * 8) / DeltaT;
ifInOctetsT1 = ifInOctetsT2;
ifInErrorsT1 = ifInErrorsT2;
ifInDiscardsT1 = ifInDiscardsT2;
ENDIF;
};
};
};
END
[SOSL
Case Studies], [Management
Concepts], [NMS
Technology R&D]
[Home], [About], [Solutions
Center], [NMS
Market],
[Products & Services],
[Management Technology], [Technical Support],
[Contact us], [Site
Map]