Solutions

How to Calculate the Average Packet Size of Specific Class?

Solutions ID:    KB3808
Version:    1.0
Status:    Published
Published date:    05/24/2010
 

Problem Description

I want to identify which traffic class is having the smallest packet size.

Resolution

We can use the measurement variable bytes and pkts to calculate this. We can use ME dump of bytes and packets for all classes and write it to a file. Once we downloaded the CSV file, we can use the formula "=sum(bytes/pkts)" to get the average packet size for the class.

bytes Number of bytes that passed through the unit during the specified interval
pkts Packet count — number of packets that passed through the unit during the specified interval

The command used,

#
measure dump class all by time 1 15m to 9.258/15min.csv bytes pkts       
measure dump class all by time 1 1h to 9.258/hourly.csv bytes pkts  
measure dump class all by time 1 12h to 9.258/12hours.csv bytes pkts
#

The output file will be saved in 9.258/ directory in PacketShaper named 15min.csv, hourly.csv and 12hours.csv for different interval. 

Sample for the CSV output with addition column on average packet size. 

time class bytes pkts   byte/pkts
DD/MM/2010  11:21:00 PM /Inbound/Google-SafeBrowsing 141 3   47
DD/MM/2010  11:21:00 PM /Outbound/Google-SafeBrowsing 19824 139   142.618705
DD/MM/2010  11:21:00 PM /Inbound/QuickTime 20190 166   121.626506
DD/MM/2010  11:21:00 PM /Inbound/Symantec 19824 139   142.618705
DD/MM/2010  11:21:00 PM /Inbound/Facebook 3474 64   54.28125
DD/MM/2010  11:21:00 PM /Outbound/Facebook 23805 233   102.167382


Rate this Page

Please take a moment to complete this form to help us better serve you.

Did this document help answer your question?
 
 
If you are finished providing feedback, please click the RATE CONTENT button. Otherwise, please add more detail in the following text box and then click RATE CONTENT.
 
 

Your response will be used to improve our document content.

Ask a Question