lab 2 traffic generator n.
Skip this Video
Download Presentation
Lab 2. Traffic Generator

Loading in 2 Seconds...

play fullscreen
1 / 70

Lab 2. Traffic Generator - PowerPoint PPT Presentation

  • Uploaded on

Lab 2. Traffic Generator. Chuan- Ching Sue DCNLAB, CSIE NCKU Outline. Recall Long-Range Dependence Initialization Experiment Requirement Basic Procedure Advance Method Pool Type Simulation Conclusion. Recall Long-range Dependence . Long-Range Dependence .

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
Download Presentation

PowerPoint Slideshow about 'Lab 2. Traffic Generator' - sumana

Download Now An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
lab 2 traffic generator

Lab 2. Traffic Generator

Chuan-Ching Sue


  • Recall Long-Range Dependence
    • Initialization
    • Experiment Requirement
    • Basic Procedure
    • Advance Method
    • Pool Type
  • Simulation
  • Conclusion
long range dependence
Long-Range Dependence
  • This is self-similar and long-range dependent traffic.
    • non-negligible probability
    • extremely large bursts of data (packet trains)
    • extremely long periods of silence (inter-burst gaps)
  • This traffic has bursty behavior at several timescales and most closely models the empirical traffic profiles observed in LANs.
experiment requirement
Experiment Requirement
  • PC client
    • Remote Desktop Connection
  • Simulation platform
    • OMNeT++ [3]
    • Xrdpserver
  • The installation of the simulation platform was introduced in the lab 1 slides.
traffic generation model
Traffic Generation Model
  • To simulate the real traffic in OMNeT++ simulator, the traffic generator will be introduced in the following slides.
traffic generation model1
Traffic Generation Model
  • The network traffic is aggregated by a number of sources with Pareto distributed ON/ OFF periods. [1]


Figure 1. traffic is aggregated by n sources

create testbed
Create Testbed
  • To simulate the interested traffic generation model, we create a testbed which is similar to the model.
  • Below figure is an example of the testbed.
submodules of testbed
Submodules of Testbed
  • The Testbed for testing traffic should include
    • Source module
    • Dispatcher module
    • User module
    • Sink module
  • The following slides will introduce the procedure of creating the testbed.
create testbed project
Create Testbed Project
  • Open OMNeT++
  • File -> New-> OMNeT++ Project
testbed project name
Testbed Project Name
  • Input project name, we take “Traffic_Generator” as example
initial contexts
Initial Contexts
  • Select “Empty project with src and simulations folders” for clearness
finish creating empty project
Finish Creating Empty Project
  • The initial contents should include
    • Includes
    • src folder
    • simulations folder
    • Makefile
create source
Create Source
  • Create source.ned in src folder
select template
Select Template
  • Select “NED file with one item”
ned component type
NED Component Type
  • Select “Simple module”
edit source code
Edit Source Code
  • Click “Source” to edit the empty Source module.
edit source code1
Edit Source Code
  • Write the topology property of source.
  • For example
    • Loading
    • Output
create dispatcher
Create Dispatcher
  • Similarly, create a dispatcher module in src folder.
initial contents select template
Initial Contents: Select Template
  • Select the “NED file with one item”
ned component type1
NED Component Type
  • Since that there will be no other modules inside dispatcher module, we select the “Simple module” type.
edit source code2
Edit Source Code
  • Now, an empty Dispatcher module is done.
  • Click “Source” to edit its source code.
edit source code3
Edit Source Code
  • Write the topology property of the dispatcher.
  • For example
    • Input from source
    • Output
create user module
Create User Module
  • Create a user module in src folder.
initial contents select template1
Initial Contents: Select Template
  • Select “NED file with item”
ned component type2
NED Component Type
  • Select the “Compound module”, because the user module should include the source modules and dispatcher module.
edit the source code
Edit the source code
  • Write the user topology in the source code.
  • For example:
    • Loading
    • Number of source
    • Connection between source and dispatcher
the sink
The Sink
  • To verify the simulation result, here we use a Sink module to catch packets from the user module and pre-process data before analysis.
create sink
Create Sink
  • As the procedure of creating the source module, we create the Sink module in src folder.
  • The Selection of initial contents is still “Simple module”.
edit source code4
Edit Source Code
  • Since the Sink module has to catch packets from user, it should carry at least one input gate.
  • The desire time scale is also required.
create network
Create Network
  • Now, we have all required modules. It’s time to create the network
    • In OMNeT++, a simulation must contain one network.
  • The network file should be created in the “simulations” folder.
  • Our example network file is “test_traffic.ned”.
initial contents
Initial Contents
  • Select the “An empty network” template.
  • The empty network “Test_traffic” was created.
edit network source code
Edit Network Source Code
  • In the Test_traffic network, there is a user which generate packet by its number of source and a sink which catch packets from user.
traffic generator implement
Traffic Generator Implement
  • The connected configure setting in the testbedwas done.
  • Now we will begin the introduction of the generator implementation.
on off bursty traffic generator
ON / OFF Bursty Traffic Generator
  • There are two states in each source module
    • ON period state
    • OFF period state
  • There will be multiple packets generated in ON period, and the OFF period happened when the source is silence.
on off bursty traffic generator1
ON / OFF Bursty Traffic Generator
  • When the packet is generated, it will be transmit to the dispatcher immediately.
  • A traffic generator can only transmit one packet at a time.
    • Thus, if there are two or more sources generate packets, those packets will be queued at the dispatcher.
traffic generation model example
Traffic Generation Model: Example
  • Though orange packet generated by source 2 attime t1. The source 1 has generated its first red packet before t1.
  • Thus, The orange packet should wait for the transmission of the red packet.
traffic generation model example1
Traffic Generation Model: Example
  • Therefore, the aggregated traffic is still the bursty.
  • The dispatcher time line shows the aggregated traffic from three source.
length of on off period
Length of ON/OFF Period
  • To represent the LRD of the real world traffic, the length of ON and OFF period should be generated by the Pareto distribution.
  • The generated number from Pareto distribution can be interpreted as the number of packets or the byte length in the ON period.
  • We call these two method
    • Packet number pool
    • Packet byte pool
packet number pool
Packet Number Pool
  • At the end of every OFF period, the source uses a Pareto distribution to generate the number of packets in the new ON period. After that, the source use uniform(64, 1518) to generates the length for each packet, since the packet length of an Ethernet frame is between 64 and 1518 bytes.
  • The packet is generated in the period time of ON, and the period time of OFF is silence. It indicates that there is no packet generated.
packet number pool1
Packet Number Pool
  • For example, the length of first ON and OFF period in source are 2 and 1 which indicates there are two packets will be generated in the ON period time and wait for one packet length of OFF period time.
packet byte pool
Packet Byte Pool
  • At the end of every OFF period, the source uses a Pareto distribution to generate the byte length of ON and OFF.
  • After that, the source uses uniform(64, 1518) to decide the packet length.
  • When a source generates a packet, the remainder period length will be subtracted by the new packet length.
  • Therefore, when the remainder period length is not enough to create a single packet, the remainder period length will be reserved tothe next ON period.
    • If the remainder ON period length is ignored in every ON period, the real load will lower than the offered load.
packet byte pool1
Packet Byte Pool
  • For example, the ON and OFF period length of source are 1100 and 600 at the first ON/OFF period.
  • The byte length of ON period is used to divide into packets.
  • The self-similar traffic is constructed by several Pareto distribution sources. They must not only be random each itself, but also be random to each other.
  • Initialization is to randomize sources at beginning.
three initialization methods
Three Initialization Methods
  • At the beginning of system, if the status of all sources is in the ON period, it could cause the high bursty and letting the simulation result is inaccurate.
  • There are three methods which distribute the ON period time of all source.
    • All sources are OFF at the beginning.
    • Some sources are initially in ON period, the percentage of ON sources is set according to the offered load. (Ex: 5% sources are ON initially at load 0.05)
    • Initially random the start of each source.[2]
all sources are off at the beginning
All Sources are OFF at The Beginning
  • All Pareto distribution sources are starting to generate packet after period time of OFF. Owing to period time of OFF in each sources are not equal, and each sources are not start in the same time.
all sources are off at the beginning cont d
All Sources are OFF at The Beginning (cont’d)
  • A big bursty comes after a period of silence.
  • Those sources are starting in OFF period time, so it has a silence period in the beginning.
  • Because those period time of OFF is not variance to much, so packets may be generated in the same time.
part of sources are initially on
Part of Sources are Initially ON
  • Some sources are starting at ON period time. The ratio of ON and OFF is depending on the network’s load.
  • For example, If the ONU’s load is 0.05, there are 5% sources starting at ON period time.
part of sources are initially on cont d
Part of Sources are Initially ON (cont’d)
  • Because part of sources are starting in ON period time. The big period of silence disappears, the burst is smaller than setting all source to be OFF status.
initially random the start timing of each source cont d
Initially Random the Start Timing of Each Source (cont’d)
  • According to the period time of ON and OFF in the cycle, the start time is selected by a random distribution. It can randomize the start point of each Pareto distribution sources.
initially random the start timing of each source cont d1
Initially Random the Start Timing of Each Source (cont’d)
  • Silence disappears, burst is smaller.
  • The start time is decided by a random distribution. Therefore, the part of Pareto distribution sources will start in ON period time and the other sources will start in OFF period time. The silence disappears in the beginning.
  • No matter which initialization method, there is still some bursty at the beginning. All source OFF at the beginning has the longest bursty time at the beginning.
  • The undesired burstywill result in an unsteady simulation result.
    • To make simulation result more steady, the warm-up period will be introduced in the lab 4.
implement source
Implement Source
  • Create two files in src folder
    • Source.h
      • Declaration of source
      • Definition of source
  • To write a LRD traffic generator and observe the number pool generated traffic
    • From three kinds of initialization method
      • All source OFF at the beginning.
      • Part of sources are initially ON, the ratio is load.
      • Initially random the start timing within an ON+OFF period of each source.
initialization experiment parameters
Initialization Experiment Parameters
  • OMNeT++ 4.1 simulation time 200 seconds
  • 1 user (self-similar traffic generators)
    • 128 sources
    • 100Mbps
    • Hurst parameter = 0.8
      • α=1.4
    • load 0.5
all sources off at the beginning
All sources OFF at the beginning
  • A big bursty after a period of silence
  • Without good initialization or warm up period setup, the high delay at the beginning may make the statistical average delay incorrect.
  • [1] W. Willinger, M.Taqqu, R. Sherman,and D. Wilson. “Selfsimilarity through high-variability: statistical analysis of Ethernet LAN traffic at the source level,” In Proc. ACM SIGCOMM '95, pp. 100-113, Feb 1995.
  • [2] G. Kramer, Ethernet Passive Optical Networks, McGraw-Hill Professional, ISBN: 0071445625, Publication, Mar 2005.
  • [3] “OMNeT++”, [Online]. Available: