Introduction
One of the highly sought after Statistics processes are those processes that calculates Link Throughput. Similar to link Bandwidth; link throughput is calculated primarily to study the network’s bottleneck points, in an attempt to anticipate those bottlenecks and avoid congestion and packet drops before they actually occur.
Throughput calculations accuracy could be compromised by the interface packets traffic overhead values according to the interface type. Hence, care must be taken to ensure that the value of the packets overhead is integrated into the final throughput calculation
Throughput calculations are inherently inaccurate when applied to the total link if the link is on full duplex mode; this is due to the fact that calculations would have to be applied to either inbound traffic or outbound traffic and not both. Therefore utilization should be calculated independently for both inbound and outbound traffic.
Following are the equations that should be used to calculate link utilizations in each direction:
InOctets * 8bits
Inbound Throughput = --------------------
Time Interval
OutOctets * 8bits
Outbound Throughput = ---------------------
Time Interval
Where;
InOctets :
Is the difference in the ifInOctets counter reading between consecutive poll cycles.
OutOctets :
Is the difference in the ifOutOctets counter reading between two consecutive poll cycles.
Time Interval :
Is the difference in the value of the sysUpTime MIB object varbinded to each poll of the relevant octets counter.
Integrating the Overhead into the formulas above:
InOctets * 8 * - (TotalInPkts * PktOVHead)
Inbound Throughput = -------------------------------------------------
Time Interval
OutOctets * 8 * - (TotalOutPkts * PktOVHead)
Outbound Throughput = ----------------------------------------------------
Time Interval
Where;
TotalInPkts:
Is the total number of packets inbound on the particular interface. The packets could include unicast, multicast, and broadcast packet types depending on the type of interface.
TotalOutPkts:
Is the total number of packets outbound on the particular interface. The packets could include unicast, multicast, and broadcast packet types depending on the type of interface.
PktOVHead:
Is the traffic overhead bits which includes interpacket delay bits and preamble bits. Overhead is also interface type dependant.
The Time Interval used in the formulas above deserves a closer look. While it is indeed the time difference between each Octets counter’s consecutive poll cycles; if used in the formulas above, it will compromise the accuracy of the final calculated value due to the time skew between both poll cycles. Time Skew is defined as the difference in the total delays between the Get-request/Get-response sets of the different polls across the time interval. Hence the actual time used in the formulas above should be derived from device being polled and not from the host NMS server.
In looking more closely at link utilization, broadcast and multicast traffic, and maybe management related traffic or indeed other protocols related traffic could be either discounted or indeed independently measured and compared to the overall utilization in each link direction to make data utilization calculations more accurate and more correct.
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 and description, then initiates the polling process under which the Devices in the specified AMZ are fed into the polling SNMP engine, where the 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. If the status for the particular interface is ‘up’ and the interface type is a point-to-point serial interface with an operational state of ‘up’ then the in/out octet counters along with the system up time and discontinuity time for the particular interface are polled in a bundled SNMP data unit.
The MIB Objects values are then stored into the appropriate variable handlers before the operation above is repeated again to produce an identical set of handlers storing the second poll data. The management process then subtract the values of the first set of handlers from those of the second set 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 ();
DESCRIPTION "Interface Throughput Calculation";
BEGIN
MSG-MGR("Interface Throughput Calculation ..");
ALL-DEV (ZONE "TokyoNet") 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 ifOutOctetsT1 MAP INT;
POLL ( ifInOctets;
ifOutOctets;
sysUpTime;
ifCounterDiscontinuityTime);
DEFINE ifInOctets DB INT;
DEFINE ifOutOctets DB INT;
IfInOctetsT1 = IfInOctets;
ifOutOctetsT1 = ifOutOctets;
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 "TokyoNet") 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 ifOutOctetsT2 MAP INT;
POLL ( ifInOctets;
ifOutOctets;
sysUpTime;
ifCounterDiscontinuityTime);
DEFINE ifInOctets DB INT;
DEFINE ifOutOctets DB INT;
IfInOctetsT2 = IfInOctets;
ifOutOctetsT2 = ifOutOctets;
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 ( ifOutOctets, ifOutOctetsT1, ifOutOctetsT2);
DEFINE DeltaT MAP INT;
DeltaT = Time2 – Time1;
DEFINE ifDisconTime MAP INT;
ifDisconTime = ifDisconTime2 – ifDisconTime1;
IF (ifDisconTime == 0)
THEN
DEFINE InThroughput DB INT;
DEFINE OutThroughput DB INT;
InThroughput = (ifInOctets * 8) / DeltaT;
OutThroughput = (ifOutOctets * 8) / DeltaT;
ifInOctetsT1 = ifInOctetsT2;
ifOutOctetsT1 = ifOutOctetsT2;
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]