Network Simulation with OPNET

Download Report

Transcript Network Simulation with OPNET

Network Simulation
with Opnet
Simulation of Networks
• Computer experiment, alternative to building a
network
• Input network and traffic details
• Specify performance stats to be collected
• Run the simulation
• Examine the results – use graphs, spreadsheet
• Evaluate averages, min/max, deviation
Input details
• Components – PCs, workstations, LANs, links, link
speeds, protocols
• User profiles – applications, start/stop time, destination
servers
• Application details – transaction interarrival time,
transaction size
►Complex behaviour of networks
Difficult to predict (even simple sub-networks and single
links can have complex behaviour due to the large
number of interacting dynamic aspects).
C/S Database Application – link load example
Ratio of query to update 50-50
Mean (average) transaction interarrival time = Exponential (2 sec)
(Constant, Exponential are statistical distributions – discussed later)
Try calculating the load in bits/sec each way.
Query (C to S): 128 bytes,
Response (S to C) 2400 bytes
Client (C)
Server (S)
Update request (C to S) 2400 bytes,
Confirmation (S to C) 128 bytes
Video conferencing bandwidth requirements example
30 frames per second
Frame size: 800 x 640 pixels
Pixel resolution 12 bits
Load = [30 x 800 x 640 x 12] bits/sec
= 184,320,000 bits / second (approx 200Mb/s)
Performance statistics - examples
Output from the simulation experiment:
• Application response time, delay
• Voice/video packet end-to-end delay
• Network access delay
• No. of collisions
• Link/server utilisation, throughput
• Packet loss, retransmission
OPNET – Simulation Package
• Facilitates simulation of communications networks
• Enables determination of performance figures
• Is a complex and powerful package with many features:
Get started by doing some of the tutorials.
Then modify the library models, and compare
different scenarios.
Save your own version of the library model under a
different name (your-initials_LANs).
Save to your O: drive.
Then develop your own models, code etc.
OPNET Start up screen
•
•
•
Project may have multiple
(related) scenarios.
A scenario is a specific
configuration of a model.
You can open projects,
nodes etc. from the file
menu.
Documentation and
tutorials from the ‘help’
menu.
See ‘help’ menu for tutorials
Small Internetworks
Introduction
This tutorial shows how you can do organizational scaling to solve a
typical "what if" problem.
You will learn how to use OPNET Modeler features to build and
analyze network models. The tutorial focuses on the use of the Project
Editor, and how it will be used with the Node and Process editors in
later lessons.
Tutorial activities include:
• Build a network quickly
• Collect statistics about network performance
• Analyze these statistics
Tutorials for this course
Start with:
•
•
Small Internetworks: Create, simulate & analyse
the (star network, client server) model within the
project editor. Compare two scenarios.
M/M/1 Queue: Build a simple queuing system and
simulate it.
Workspace & documentation
• Opnet Workspace (various GUI components, inc.)
–
–
–
–
Menu bar
Action buttons
Message display
Tool Tips
• Documentation
– On line documentation (see ‘help’ menu)
– Comments within model components
– From the Opnet web site
• OPNET Website:
http://www.opnet.com/rpm_support/
Work Sequence when using OPNET
• Create the network model – nodes, links, processes – always save to
your drive (O:/)
• Specify traffic types (e.g. database, web browsing) and volumes
(how many packets, what size packets)
• Specify stats to collect – e.g. delays, buffer use, queue size, load,
utilisation for servers, links.
• Run the simulation – how long? Seed?
• Estimate performance parameters (utilisation, delays, throughput,
buffer use, loss/error rates).
– Average, min/max, standard deviation
– Export to Excel spreadsheet for better analysis and graphs
•
•
Main Components of OPNET
Project Editor: build a network model using various model libraries;
specify statistics (results) to collect, run the simulation and examine results
Node Editor: Nodes have modules (e.g. MAC, IP, TCP, ARP) &
processes (module behaviour, described by State Transition Diagrams STD
& Finite State Machines FSM).
•
Process Model Editor: Process functionality (C++).
•
Link Model Editor: Create data links, specify speed, protocol etc.
•
Packet Format Editor: Create different types of packets & frames
•
Probe Editor: To specify simulation statistics
•
•
Simulation Tool: To run multiple simulations, with different run
parameters, and other sophisticated features
Analysis Tool: More detailed analysis, comparisons etc.
Scenarios
• The project
describes the
model
• Scenarios are
slight variations
of a basic model.
E.g. Change in
link speed,
traffic
parameters etc.
Object Attributes
right click and edit attributes
Attributes of node30 (Central Switch)
3Com model, type
etc. included in the
name
Explanation
(‘details’) of
attributes can be
obtained
User Profiles
• Each profile
represents a
typical user
– a mix of
applications
• Start/stop times
are defined for
profiles
Applications
• Standard
applications
are defined
• Here is a
list of what
is available
• Actual
parameters
can be
modified
Application Parameters
Example traffic specification
Telnet (remote login) example shown on previous slide.
•
•
•
•
Enter command (interarrival) time (secs)
Command size (bytes) for terminal traffic
Command size (bytes) for host traffic
Distribution needed too – constant, exponential, uniform etc.
Note / recall:
Load (bits/sec) = commands/sec x command size (bytes) x 8
Commands/sec (rate) = 1/interarrival_time
Running the simulation
Guidelines
•
•
Duration or run length? Enough for 20k-30k messages of each type.
Values per statistic: if duration = 3600 seconds, values/statistic =
60, each value will be averaged over 3600/60 = 60 seconds.
•
Independent runs? Change the seed each time.
•
Results from different runs will be close, but not identical.
•
Enter parameters in the right units (e.g. seconds, bytes)
•
Report results, using appropriate units (e.g. 5 ms rather than 0.005
sec).
Results
• Graphs of delays,
utilisation etc. can be
obtained (Opnet
graphs are poor
quality for
coursework reports)
• Graph properties
can be changed if
you wish
• You can also export
to Excel spreadsheet
to analyse, such as
calculate averages,
and also generate
much better quality
graphs
More Results
• Multiple graphs
for comparison
• Separate
(stacked) or
overlaid (same
frame)
• Various types of
plots – as is,
average, time
average,
histograms
Checking Results
Estimate or calculate a sample of results to confirm your model,
its parameters etc. are correct.
Example: Message inter-arrival time = 10 seconds, message size
= 1000 bytes.
Selected output statistics:
• Messages/sec sent and/or received
• Bits/second sent and/or received
Results should be:
• Messages/sec sent or received = 0.1
• Bits/sec sent or received = 800
Example calculation of utilisation ( (Rho) )
Messages
• Pkt inter-arrival time 0.2s
• Pkt arrival rate = 1/0.2
• Pkt size
• Link/channel bitrate
• Number of bytes per sec
• Number of bits per second
• Link (channel) utilisation
= 5 packets per sec
= 1600 bytes
= 128 Kbits/s
= 5 x 1600
= 8 x 5 x 1600
= (8 x 5 x 1600)/128000
= 0.5 or 50%