ComNet Opnet1 Introduction

Embed Size (px)

Citation preview

  • 7/30/2019 ComNet Opnet1 Introduction

    1/34

    )Opnet( 1

    :22//1391

    )Opnet.)2

    .

    :

    .5

    ((..

    3313Opnet

    .

    .

    1 http://ce.sharif.edu/courses/91-92/1/ce443-1/index.php

  • 7/30/2019 ComNet Opnet1 Introduction

    2/34

    Laboratory 1

    Introduction to Opnet

    Objective

    This laboratory is about basics of using Optimized Network Engineering Tools (OPNET).

    Overview

    The OPNET is a very powerful network simulator. Main purposes are to optimize cost,performance and availability.

    The goal of this laboratory is to learn the basics of how to use Modeler interface, as well

    as some basic modeling theory. The following tasks are considered:

    Build and analyze models. Configure the object palette with the needed models. Set up application and profile configurations. Model a LAN as a single node. Specify background utilization that changes over a time on a link. Simulate multiple scenarios simultaneously. Apply filter to graphs of results and analyze the results.

    Before starting working on the Exercisepart of this laboratory, one has to read the

    Preparationspart.

  • 7/30/2019 ComNet Opnet1 Introduction

    3/34

    Preparations

    To build a network model the workflow centers on the Project Editor. This is used tocreate network models, collect statistics directly from each network object or from the

    network as a hole, execute a simulation and view results. See Fig.1.

    Figure 1 - Workflow

  • 7/30/2019 ComNet Opnet1 Introduction

    4/34

    Project Editor

    The main staging area for creating a network simulation is the Project Editor. This is used

    to create a network model using models from the standard library, collect statistics about

    the network, run the simulation and view the results. Using specialized editors accessiblefrom the Project Editor via File! New one can create node and process models, buildpacket formats and create filters and parameters.

    Figure 2 - A network model built in the Project Editor

    Dependingon the type of network being modeled, a network model may consist of

    subnetworks and nodes connected by point-to-point, bus, or radio links. Subnetworks,nodes, and links can be placed within subnetworks, which can then be treated as single

    objects in the network model. This is useful for separating the network diagram into

    manageable pieces and provides a quick way of duplicating groups of nodes and links.

  • 7/30/2019 ComNet Opnet1 Introduction

    5/34

    The Node Editor

    The Node Editor is used to create models of nodes. The node models are then used to

    create node instances within networks in the Project Editor. Internally, OPNET node

    models have a modular structure. You define a node by connecting various modules with

    packet streams and statistic wires. The connections between modules allow packets andstatus information to be exchanged between modules. Each module placed in a node

    serves a specific purpose, such as generating packets, queuing packets, processing

    packets, or transmitting and receiving packets.

    Figure 3 - Node Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    6/34

    The Process Model Editor

    To create process models which control the underlying functionality of the node models

    created in the Node Editor one can use the Process Editor. Process models arerepresented by finite state machines (FSMs) and are created with icons that represent

    states and lines that represent transitions between states. Operations performed in eachstate or for a transition are described in embedded C or C++ code blocks.

    Figure 4 - Process Model Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    7/34

    The Link Model Editor

    This editor enables for the possibility to create new types of link objects. Each new type

    of link can have different attribute interfaces and representation. Specific comments and

    keywords for easy recognition are also possible.

    Figure 5 - Link Model Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    8/34

    The Path Editor

    The Path Editor is used to create new path objects that define a traffic route. Any protocol

    model that users logical connections or virtual circuits such as MPLS, ATM, Frame

    Relay, etc can use paths to route traffic.

    Figure 6 - Path Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    9/34

    The Packet Format Editor

    By making use of this editor it is possible to define the internal structure of a packet as a

    set of fields. A packet format contains one or more fields, represented in the editor as

    colored rectangular boxes. The size of the box is proportional to the number of bitsspecified as the fields size.

    Figure 7 - Packet Format Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    10/34

    The Probe Editor

    This editor is used to specify the statistics to be collected. By using different probes there

    are several different types of statistics that can be collected, including global statistics,

    link statistics, node statistics, attribute statistics, and several types of animation statistics.It is mentioned that similar possibilities for collecting statistics are also available under

    the Project Editor. These are however not as powerful as the Probe Editor.

    Figure 8 - Probe Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    11/34

    The Simulation Sequence Editor

    In the Simulation Sequence Editor additional simulation constrains can be specified.

    Simulation sequences are represented by simulation icons, which contain a set of

    attributes that control the simulations run-time characteristics.

    Figure 9 - Simulation Sequence Editor

  • 7/30/2019 ComNet Opnet1 Introduction

    12/34

    The Analysis Tool

    The Analysis Tool has several useful additional features like for instance one can create

    scalar graphics for parametric studies, define templates for statistical data, create analysis

    configurations to save and view later, etc.

    Figure 10 - Analysis Tool

  • 7/30/2019 ComNet Opnet1 Introduction

    13/34

    The Project Editor Workspace

    There are several areas in the Project Editor window (a.k.a. workspace) that are important

    for building an executing a model. See Figure 11 as an example.

    Figure 11 - Project Editor Workspace

    The Menu bar

    Each editor has its own menu bar. The menu bar shown below appears in the project

    editor.

    Buttons

    Several of the more commonly used menu bar can also be activated through buttons.Each editor has its own set of buttons. The buttons shown below appear in the Project

    Editor.

  • 7/30/2019 ComNet Opnet1 Introduction

    14/34

    1 2 3 4 5 6 7 8 9 10 11

    1. Open object palette2. Check link consistency3. Fail selected objects4. Recover selected object5. Return to parent subnet6. Zoom in7. Zoom out8. Configure discrete event simulation9. View simulation results10.View web-based reports11.Hide or show all graphs

    The message area

    The message area is located at the bottom of the Modeler window. It providesinformation about the status of the tool.

    Occasionally, the messages Modeler generates may be larger than the message area. You

    can left-click on the icon next to the message area to open the message buffer, wherethe entire message displays.

    Tool tips

    If you place your cursor over a button or a menu selection, a help balloon soon appears.

    Online Documentation. Select Help => Online Documentation

  • 7/30/2019 ComNet Opnet1 Introduction

    15/34

    Laboration

    The goal of the laboration is to model a WAN composed by several LANs.The task is is to model BTHs WAN. As known BTH stretches over three locations in

    Blekinge. These three locations are: Karlskrona, Ronneby and Karlshamn.Another task is to determine how the background traffic is affecting FTP traffic on the

    network. To do this the FTP performance on the network will be modeled, first withoutbackground traffic and then with background traffic.

    Because there is no interest in modeling the details of each LAN you will use available

    LAN models to model the individual LANs as single nodes.

    The first step in setting up the WAN is to specify the overall context for the network with

    the Startup Wizard.

    Steps:

    1) Begin by starting up Modeler and create a new project. Select File -> New and click

    OK

    2) Name the new project _LAN_Mod and the scenario no_back_util, thenclickOK. Write down your project name here:_____________________

    3) To create an empty scenario for the Initial Topology clicknext when prompted bythe Startup Wizard.

    4) Next you can specify a map to use as a background for your network. ClickChoose

    From Maps for Network Scale and clickNext.

    5) Choose Europe from the list and clickNext.

    6) Now select Lan_Mod_Model_List to be included in your network by clicking on the

    Include cell and changing the value from No to Yes. ClickNext.

    7) Finally review your settings and clickOKto finish the Startup Wizard.

    The workspace now shows the specified map and object palette.

    8) Zoom in Sweden from the Europe map (Zoom in until you are satisfied).

  • 7/30/2019 ComNet Opnet1 Introduction

    16/34

    To work with Modelers full set of node and link models would be overwhelming, so the

    object palette can be configured to show only a specific subset, or model list. Further youcan use the standard model list, adapt them for your own needs, or make your own list.

    For this lab we created LAN_Mod_Model_List. Now you will adapt that model list by

    adding the LAN node model to it.

    9) To open the Configure Palette dialog box click the Configure Palettebutton in the

    object palette.

    The Configure Palette dialog box lets you change the object palette and then save it

    10) Click the Node Modelsbutton in the Configure Palette dialog box.

    Select Included Entries dialog box appears.

    11) Find 10BaseT_LAN in the list and change its status from not included to included.

    12) ClickOK.

  • 7/30/2019 ComNet Opnet1 Introduction

    17/34

    The 10BaseT_LAN icon appears in the object palette.

    13) ClickOKto close the Configuration Palette dialog box, then clickOKagain to savethe model list as _LAN_Mod_Model_List-no_back_util .

  • 7/30/2019 ComNet Opnet1 Introduction

    18/34

    You will now configure the Application Configuration Object and the Profile

    Configuration Object. Before you begin constructing the network its a good idea topredefine the profiles and applications that will be used by the LAN.

    14) To configure the Application Configuration Object, open the object palette in the

    case it is not already open and drag an Application Config object to the projectworkspace.

    15) Right clickand select Edit Attributes from the pop up menu.

    15) Click on the question mark next to the name attribute to see a description of the

    attribute. When done close the attribute description dialog box.

    16) Set the name attribute to Application Configuration.

    17) Now change the Application Definitions attribute to Default by clicking in theattributes Value column and selecting Default from the pop-up list.

  • 7/30/2019 ComNet Opnet1 Introduction

    19/34

    Selecting Default configures the application definition object to have the eight standard

    applications which are: Database Access, Email, File Transfer, File Print, Telnet Session,Video conferencing, Voice over IP Call and Web Browsing.

    18) Close the Attributes dialog box by clicking OK.

    Now you will configure the Profile Configuration Object.

    19) Drag a Profile Configuration object from the object palette to project workspace.

    20) Right-click on the object and select Edit Attributes.

    21) Set the name attribute to Profile Configuration as shown in the box above.

    22) Change now the Profile Configuration attribute by clicking in its value column

    and selecting Edit from the drop down menu.

  • 7/30/2019 ComNet Opnet1 Introduction

    20/34

    The Profile Configuration Table box appears.

    Define a new profile and add it to the table.

    23) First change the number ofrows to 1.

    24) Name the new profile LAN Client.

    25) Click in the profiles Start Time (seconds) cell to open the Start Time Specification

    dialog box.

    26) Select constant from the Distribution Name pull-down menu.

    27) Set MeanOutcome to 100, the clickOK.

    Since you will be modeling FTP performance, that application should be included in the

    profile.

  • 7/30/2019 ComNet Opnet1 Introduction

    21/34

    28) Click in the LAN Clients Applications column and choose Edit from the pop-up

    menu

    29) Change the number ofrows to 1.

    30) Set the name to File Transfer (Heavy) by clicking in the cell and selecting theapplication from the pop-up menu.

    By selecting Default as the value for the Application Definition attribute in this object,you enable this list of applications. The list includes 16 entries, a heavy and a light

    version for each of the eight standard applications.

    31) Set the Start Time Offset to Uniform (0,300).

    32) The completed dialog box should look like this. Verify and then clickOKto close the

    Applications Table dialog box.

    33) ClickOKto close the Profile Configuration Table, then clickOKonce again to

    close the Attributes dialog box.

    You are now ready to begin the construction of the WAN. In this scenario the network

    contains 2 identical subnets in Karlskrona and Karlshamn. You can create the first subnetin Karlskrona , with its nodes inside it, and then copy the subnet to Karlshamn. You will

    also copy it to Ronneby and modify it further.

    Hint:A subnet is a single network object that contains other network objects (links,

    nodes and other subnets). Subnetworks allow you to simplify the display of a complexnetwork through abstraction.

    Subnets are useful when organizing your network model. Subnets can be nested within

    subnets to an unlimited degree.

    34) Open the object palette.

  • 7/30/2019 ComNet Opnet1 Introduction

    22/34

    35) Place a subnet over Karlskrona, Right-click to turn offnode creation.

    36) Right-click on the subnet and select set name. Change the name to Karlskrona.

    The extent of the subnet needs to be modified. The subnet extent is the geographic area

    covered by the subnet, which may be much larger than the actual area you wish to model.

    37) Right-click on the Karlskrona subnet and select Advanced Edit Attributes.

    38) Change the x span and y span attributes to 0,25.

    The unit of measure of these attributes is determined by the unit of measure of the top-level area, degrees in this case.

    39) ClickOK.

    In order to see whats inside subnets just double-click on that subnet icon and theModeler will change the view.

    By default a subnets grid properties is based on its parent subnet. You can change them

    to fit your network.

    40) Double-click on the Karlskrona Subnet.

    41) Select View => Set View Properties

    42) Set units to Meters.

    43) Set resolution to 10 pixels/m.

    45) Uncheck the Visible checkbox forSatellite orbits.

    46) Verify that Drawing is set to Dashed.

    47) Set division to 10.

  • 7/30/2019 ComNet Opnet1 Introduction

    23/34

    48) Click the Close button.

    The network in BTH does not require modeling the precise nature of each node in each

    subnet, so you can represent the subnets with a LAN model.

    49) Place a 10BaseT_LAN in the workspace.

    50) Right-click on the 10BaseT_LAN and choose the Edit Attribute menu item.

    You can change the attributes so that it represents a network with a certain number of

    workstations and a particular traffic profile.

    51) Change the LAN models name attribute to Office_LAN.

    52) Choose Edit for the Application: Supported Profiles attribute.

    53) Change the number ofrows to 1.

    54) Change the Profile Name to LAN Client, then clickOK.

    This LAN will now use the LAN Client profile you created earlier. This profile includes

    the File Transfer (Heavy) application. The LAN will send traffic that models heavy FTPuse.

    55) Change the Number of Workstations attribute to 10, then clickOK.

  • 7/30/2019 ComNet Opnet1 Introduction

    24/34

    56) Close the Edit Attributes dialog box.

    You have now modeled a 10 workstation LAN inside the Karlskrona subnet. Further

    because this LAN model is composed of workstations and links only, it must be

    connected to a router. The router can then be connected to other routers in the network.

    57) To create an router drag a BN_BLN_4s_e4_f_sl8_tr4 node from the object palette to

    the workstation near the Office_LAN node.

    58) After naming the new node router connect it to the Office_LAN nodes with a

    10BaseT link. Right click to turn off link creation.

    The Karlskrona subnet is now configured. Because the subnets in Karlshamn and

    Ronneby are identical, you can copy the Karlskrona subnet and place it appropriately.

    59) To copy the subnet you must first return to the parent subnet, this is done either by

    clicking on the Go to Parent Subnetworkbutton or right click on the workspaceto bring up the workspace pop-up menu, then choose Go to Parent subnetworkfrom the

    menu.

    60) After returning to the parent subnet, select the subnet and copy it, this is done either

    by clicking Edit=>Copy or by pressing +c.

    61) Now paste the subnet to Karlshamn and Ronneby by selecting Edit=>Paste or by

    pressing +v and then click on the Karlshamn and Ronneby region. When done

    the new subnets appears.

    62) You will now have to rename the subnets. To do so right-click on each of the two

    subnets and choose set name.

    63) Next you should connect the Karlshamn and the Karlskrona subnets to Ronneby.

    To do so select the LAN_Mod_PPP_DS0 link in the object palette.

    64) Draw a LAN_Mod_PPP_DS0 link from Karlskrona to Ronneby.

    Next a Select Nodes dialog box appears asking which nodes in each subnet are to be

    endpoints of the link.

    65) Fornode a, choose the Karlskrona.router node.

    66) Fornode b, choose the Ronneby.router node.

    67) ClickOKto establish the link

  • 7/30/2019 ComNet Opnet1 Introduction

    25/34

    68) Repeat this process, drawing link from Karlshamn to Ronneby as well. Specify the

    citys router as the links endpoints.

    69) When done right-click to turn of link creation.

    The network should resemble the one shown in the picture below.

    To complete the network, the main office in Ronneby needs to have a switch and a server

    added to it.

  • 7/30/2019 ComNet Opnet1 Introduction

    26/34

    70) To configure the network in Ronneby double-click on the Ronneby subnet to enter its

    subnet view.

    71) Place one switch and one ethernet_server node in the

    workspace.

    72) Rename the node to switch.

    This is done by right-clicking on each icon and select Set name from the menu.

    73) Rename the ethernet_server to FTP.

    74) Connect the router and the server to the switch with 10BaseT links. Right-click to

    turn off link creation, and close the object palette.

    The Server needs to be configured to support the FTP Application.

    75) Open the Attributes dialog box for the FTP server.

    76) Choose Edit for the Application: Supported Services

    77) Change number of rows to 1.

    78) Select File Transfer (Heavy) from the Name column pop-up menu.

    79) ClickOKto close the Supported Services dialog box, and then clickOKto close the

    FTP Attributes dialog box.

  • 7/30/2019 ComNet Opnet1 Introduction

    27/34

    80) Return to the parent subnet view.

    81) Save the project. File => Save.

    You have now created a model to act as a baseline for the performance of the network.Background traffic will now be added to the links connecting the cities. The results from

    the two scenarios will be compared.

    We begin with duplicating a scenario to be able to compare the results later.

    82) Select Scenarios => Duplicate Scenario

    83) Name the scenario back_util and clickOK.

  • 7/30/2019 ComNet Opnet1 Introduction

    28/34

    84) Select the link between Karlskrona-Ronneby. Right-click on the link and choose

    Similar Links from the pop-up menu.

    85) Display the Edit Attributes dialog box for the link between Karlskrona-Ronneby.

    86) Click in the Value cell for the Background Utilization attribute and select Edit...

    from the pop-up menu.

    87) Click on the Rows value and change it to 3. Press Return.

    Network studies show that traffic rises gradually over the course of the day as

    employees/students arrive.

    88) Complete the dialog box as shown. Then ClickOK.

    The last step in setting background utilization is to apply the changes made to theKarlskrona-Ronneby link to all the selected links.

    89) Check the Apply Changes to Selected objects check box in the Karlskorna-RonnebyAttributes dialog box.

  • 7/30/2019 ComNet Opnet1 Introduction

    29/34

    90) ClickOKto close the dialog box.

    Note that 2 objects changed appears in the message area.

    91) Save the project. File => Save.

    Now you have configured two scenarios, one without background utilization and one

    with background utilization. You are ready to collect data and analyze it.

    The relevant statistics for this network are:

    Utilization statistics for the links. Global FTP download time for the network.

    You will now collect statistics in the back_util scenario.

    92) Right-click in the workspace to display the workspace pop-up menu, and select

    Choose Individual Statistics.

    93) Select the Global Statistics => Ftp => Download Response Time (sec) statistic.

  • 7/30/2019 ComNet Opnet1 Introduction

    30/34

    94) Select the Link Statistics => point-to-point => untilization --> Statistic.

    95) ClickOKto close the dialog box.

    In order to compare the statistics in the back_util scenario to the no_back_util scenario,

    the same statistics must be collected in the no_back_util scenario.

    Change scenario and collect statistics.

    96) Select Scenarios => Switch To Scenario, then choose no_back_util.

  • 7/30/2019 ComNet Opnet1 Introduction

    31/34

    97) Collect the same statistics that you did in the back_util scenario:

    Global Statistics => Ftp => Download Response Time (sec) Link Statistics => point-to-point => untilization -->

    98) Close the Choose Results dialog box.

    99) Save the project.

    The statistics are now ready to be collected by running the simulations. Instead of

    running each simulation separately, you can batch them together to run consecutively.

    100) Select Scenarios => Manage Scenarios

    101) Click on the Results value for the no_back_util and back_util scenarios and

    change the value to .

    102) Set the Sim Duration value for each scenario to 30 and the Time Units to minutes.

    103) ClickOK.

  • 7/30/2019 ComNet Opnet1 Introduction

    32/34

    Modeler will now run simulations for both scenarios. A simulation Sequence dialog boxshows the simulation progress. Shut down the dialog box when the simulations are done.

    Hint: You are now ready to view the results of the two scenarios. To view the results

    from two or more different scenarios against each other, you can use the CompareResults feature. With this topic you can also apply different built-in filters to the graphs.

    104) Continue by comparing the results, to do so display the workspace pop-up menu andchoose Compare Results.

    105) In the Compare Results dialog box, select Object Statistics => Choose From

    Maps Network => Karlshamn Ronneby[0] => point to point => utilization ->.

    106) Further you will also have to change the filter from menu from As Is to

    time_average. This must be done because utilization varies over the course of a

    simulation and it is therefore helpful to look at time average for this statistic.

    107) ClickShow to display the graph. The graph should resemble the one below, though

    it will not match exactly.

  • 7/30/2019 ComNet Opnet1 Introduction

    33/34

    You may want to look at the utilization of other links to determine the maximum

    utilization of any link.

    Lets look at Global FTP response time.

    108) Click the Unselect button in the Compare Results dialog box.

    109) Check the Global Statistics => FTP => Download Response Time statistic in the

    Compare Statistics dialog box.

    110) Verify that the filter menu shows time_average, then clickShow.

    The graph should resemble the one below, though it will not match exactly.

  • 7/30/2019 ComNet Opnet1 Introduction

    34/34

    The laboration is now completed.

    Before you leave please remove your saved project from the computer.

    By default it is located on: C:\Documents and Settings\[your login name]\op_modelsRemove all your saved files.