OPNET Modeler. Tommy Svensson Alex Popescu

Size: px
Start display at page:

Download "OPNET Modeler. Tommy Svensson Alex Popescu"

Transcription

1 OPNET Modeler Development of laboratory exercises based on OPNET Modeler Tommy Svensson This thesis is presented as a part of the Master of Science Degree in Electrical Engineering with emphasis on Telecommunications and Signal Processing. Blekinge Institute of Technology June 2003 Master of Science Programme in Electrical Engineering Blekinge Institute of Technology Department of Telecommunications and Signal Processing I.T.S Supervisor: Prof: Arne Nilsson and Docent: Adrian Popescu I.T.S Examiner: Prof: Arne Nilsson and Docent: Adrian Popescu I.T.S

2 Abstract The primary purpose of this thesis is to develop laboratory exercises for use with several courses at the Blekinge Institute of Technology and to offer an insight in how real networks and protocols behave. All laboratories are developed in OPNET Modeler 9.0 simulation environment which is a network simulator that offers the tools for model design, simulation, data mining and analysis. The software package is licensed by OPNET technologies Inc [1]. The instructional material consists of a set of laboratory exercises, namely: Introduction to OPNET Modeler 9.0 environment, M/M/1, Aloha, CSMA, CSMA-CD, Slow Start, Congestion Avoidance, Fast Retransmit, Fast Recovery and OSPF, Queuing policies, Selfsimilar. Keywords: OPNET Modeler, Lab, M/M/1, Aloha, CSMA, CSMA-CD, Slow Start, Congestion Avoidance, Fast Retransmit, Fast Recovery, OSPF, Areas, Balanced traffic flow, Ethernet, FIFO, Preemptive priority queuing, Non preemptive queuing, WFQ, Selfsimilar. Tommy Svensson, t98tsv@student.bth.se, t98apo@student.bth.se Tommy Svensson 2

3 Table of contents Abstract...2 Introduction...6 General...6 Purpose...6 Laboratory Introduction to Opnet...7 Objective...7 Overview...7 Preparations...8 Project Editor...9 The Process Model Editor...11 The Link Model Editor...12 The Path Editor...13 The Packet Format Editor...14 The Probe Editor...15 The Simulation Sequence Editor...16 The Analysis Tool...17 The Project Editor Workspace...18 Begin the laboratory...20 Laboratory M/M/1 Queue simulation...41 Objective...41 Overview...41 Procedure...42 Creation of the node model...43 Laboratory Ethernet simulation...62 Objective...62 Overview...62 Procedure...63 Designing the Aloha Transmitter Process Model...63 Creating the Aloha Transmitter Node Model...70 Creating the Generic Receiver Node Process Model...73 Creating the Generic Receiver Node Model...77 Creating a new link model...79 Creating the network model...80 Executing the Aloha Simulation...83 Creating the CSMA transmitter process model...87 Creating the CSMA transmitter node model...89 Redefining the network model...91 Configuring CSMA Simulations...92 Analyzing the CSMA results...93 Viewing Both Results on the Same Graph...94 Ethernet network model...97 Laboratory TCP simulation Objective Overview Procedure Slow start and congestion avoidance Slow start and congestion avoidance simulation Create the network Create the Paris subnet Tommy Svensson 3

4 Create the Stockholm subnet Create the IP Cloud Choose Statistics Slow start and Congestion avoidance simulation View the results Fast retransmit Fast recovery Fast Retransmit and Fast Recovery simulation Create the Tahoe scenario Create the Reno scenario Simulate the scenarios View results Laboratory OSPF simulation Objective Overview Procedure Create the network Configure router interfaces Assign addresses to the router interfaces Configure routing cost Configure the traffic demands Configure Simulation Duplicate the scenario Run the simulation View the results Laboratory Queuing policies Objective Overview Procedure Copy files FIFO queuing Create the FIFO network Duplicate scenario Collect statistics Run the simulation View the results Priority queuing Create the Non-preemptive priority network, infinite buffer Create the Preemptive priority network, infinite buffer Run the infinite buffer simulation View the infinite buffer simulation results Create the Preemptive priority network, Finite buffer Create the Preemptive priority network, Finite buffer Run the finite buffer simulation View the finite buffer simulation results Weighted Fair Queuing Create the Weighted Fair Queuing infinite buffer network Run the Weighted Fair Queuing infinite buffer simulation View the Weighted Fair Queuing infinite buffer results Create the Weighted Fair Queuing finite buffer network Run the Weighted Fair Queuing finite buffer simulation View the Weighted Fair Queuing finite buffer results Laboratory Self-Similar Tommy Svensson 4

5 Objective Overview Procedure Create the self similar network model Run the simulation View the results Conclusions throughput Conclusions delay Concluding Remarks Acknowledgments Glossary References Appendix Appendix Appendix Appendix Tommy Svensson 5

6 Introduction General Today the field of computer networks all over the world has entered an exponential growth phase. These demands have made the necessity of capable network engineers extremely covet. It is therefore crucial for universities to offer networking courses that are both educational and up to date. Due to different obstacles it is unpractical for a university to be able to offer several types of networks to its students. An invaluable tool in this case consists of the network simulator OPNET Modeler that offers the tools for model design, simulation, data mining and analysis for, considering the alternatives, a reasonable cost. OPNET Modeler can simulate a wide variety of different networks which are link to each other. The students can therefore just by sitting at their workstations exercise various options available to network nodes and visually see the impact of their actions. Data message flows, packet losses, control/routing message flows, link failures, bit errors; etc can be seen by the students at visible speed. This is the most cost effective solution for universities to demonstrate the behavior of different networks and protocols. Purpose This thesis will implement five laboratory exercises using the OPNET Modeler simulation environment, namely: Lab1 Introduction (Introduction to OPNET environment) Lab2 M/M/1 (Construct an M/M/1 queue model) Lab3 Ethernet (Aloha, CSMA, CSMA-CD) Lab4 TCP (SlowStart, Congestion Avoidance, Fast Retransmit, Fast Recovery) Lab5 OSPF (Areas, Balanced traffic flow) Finally after concluding these laboratory exercises the student s comprehension of protocols, networks and routing implementation and interaction will be expanded. This plays a fundamental roll in understanding how Internet works. Tommy Svensson 6

7 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 Exercise part of this laboratory, one has to read the Preparations part. Tommy Svensson 7

8 Preparations To build a network model the workflow centers on the Project Editor. This is used to create 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 Tommy Svensson 8

9 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 accessible from the Project Editor via File New one can create node and process models, build packet formats and create filters and parameters. Figure 2 - A network model built in the Project Editor Depending on 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. Tommy Svensson 9

10 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 and status 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 Tommy Svensson 10

11 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 are represented by finite state machines (FSMs) and are created with icons that represent states and lines that represent transitions between states. Operations performed in each state or for a transition are described in embedded C or C++ code blocks. Figure 4 - Process Model Editor Tommy Svensson 11

12 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 Tommy Svensson 12

13 The Path Editor The Path Editor is used to create new path objects that define a traffic route. Any protocol model that uses logical connections or virtual circuits such as MPLS, ATM, Frame Relay, etc can use paths to route traffic. Figure 6 - Path Editor Tommy Svensson 13

14 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 bits specified as the field s size. Figure 7 - Packet Format Editor Tommy Svensson 14

15 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 Tommy Svensson 15

16 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 simulation s run-time characteristics. Figure 9 - Simulation Sequence Editor Tommy Svensson 16

17 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 Tommy Svensson 17

18 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. Figure 12 - Menu Bar 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. Tommy Svensson 18

19 Figure 13 Project Editor Buttons 1. Open object palette 2. Check link consistency 3. Fail selected objects 4. Recover selected object 5. Return to parent subnet 6. Zoom in 7. Zoom out 8. Configure discrete event simulation 9. View simulation results 10. View web-based reports 11. Hide or show all graphs The message area The message area is located at the bottom of the Modeler window. It provides information about the status of the tool. Figure 14 - Message area 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, where the entire message displays. Tool tips If you place your cursor over a button or a menu selection, a help balloon soon appears. Figure 15 - Tool tips Online Documentation. Select Help => Online Documentation Tommy Svensson 19

20 Begin the laboratory The goal of the laboration is to model a WAN composed by several LANs. The task is is to model BTH s 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 without background 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 <initials>_lan_mod and the scenario no_back_util, then click OK. Write down your project name here: 3) To create an empty scenario for the Initial Topology click next when prompted by the Startup Wizard. 4) Next you can specify a map to use as a background for your network. Click Choose From Maps for Network Scale and click Next. 5) Choose Europe from the list and click Next. 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. Click Next. 7) Finally review your settings and click OK to 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). Tommy Svensson 20

21 To work with Modeler s 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 you can 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 Palette button in the object palette. Figure 16 - Configure Palette dialog The Configure Palette dialog box lets you change the object palette and then save it 10) Click the Node Models button 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. Figure 17 - Select technologies dialog 12) Click OK. Tommy Svensson 21

22 Figure 18 - Object Palette The 10BaseT_LAN icon appears in the object palette. 13) Click OK to close the Configuration Palette dialog box, then click OK again to save the model list as <initials>_lan_mod_model_list-no_back_util. Tommy Svensson 22

23 You will now configure the Application Configuration Object and the Profile Configuration Object. Before you begin constructing the network it s a good idea to predefine 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 project workspace. 15) Right click and 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. Figure 19 - Application Configuration Attributes 16) Set the name attribute to Application Configuration. 17) Now change the Application Definitions attribute to Default by clicking in the attribute s Value column and selecting Default from the pop-up list. Tommy Svensson 23

24 Figure 20 - Application Configuration Attributes Selecting Default configures the application definition object to have the eight standard applications which are: Database Access, , 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. Figure 21 - Profile Configuration Attributes 21) Set the name attribute to Profile Configuration as shown in the box above. Tommy Svensson 24

25 22) Change now the Profile Configuration attribute by clicking in its value column and selecting Edit from the drop down menu. The Profile Configuration Table box appears. Figure 22 - Profile Configuration Table Define a new profile and add it to the table. 23) First change the number of rows to 1. 24) Name the new profile LAN Client. 25) Click in the profile s Start Time (seconds) cell to open the Start Time Specification dialog box. 26) Select constant from the Distribution Name pull-down menu. Figure 23 - LAN Client Start Time Attributes Tommy Svensson 25

26 27) Set Mean Outcome to 100, the click OK. Since you will be modeling FTP performance, that application should be included in the profile. 28) Click in the LAN Client s Applications column and choose Edit from the pop-up menu 29) Change the number of rows to 1. 30) Set the name to File Transfer (Heavy) by clicking in the cell and selecting the application 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 click OK to close the Applications Table dialog box. Figure 24 Heavy File Transfer Application table 33) Click OK to close the Profile Configuration Table, then click OK once 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 subnet in Karlskrona, with its nodes inside it, and then copy the subnet to Karlshamn. You will also copy it to Ronneby and modify it further. Tommy Svensson 26

27 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 complex network 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. 35) Place a subnet over Karlskrona, Right-click to turn off node 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 toplevel area, degrees in this case. 39) Click OK. In order to see what s inside subnets just double-click on that subnet icon and the Modeler will change the view. By default a subnet s 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 for Satellite orbits. 46) Verify that Drawing is set to Dashed. 47) Set division to 10. Tommy Svensson 27

28 Figure 25 - View Properties 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 model s name attribute to Office_LAN. 52) Choose Edit for the Application: Supported Profiles attribute. 53) Change the number of rows to 1. 54) Change the Profile Name to LAN Client, then click OK. 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 FTP use. Tommy Svensson 28

29 55) Change the Number of Workstations attribute to 10, then click OK. 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 Subnetwork button or right click on the workspace to bring up the workspace pop-up menu, then choose Go to Parent subnetwork from 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 <Control>+c. 61) Now paste the subnet to Karlshamn and Ronneby by selecting Edit=>Paste or by pressing <Control>+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) For node a, choose the Karlskrona.router node. 66) For node b, choose the Ronneby.router node. Tommy Svensson 29

30 67) Click OK to establish the link Figure 26 - Select Nodes dialog 68) Repeat this process, drawing link from Karlshamn to Ronneby as well. Specify the city s 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. Figure 27 - Network overview Tommy Svensson 30

31 To complete the network, the main office in Ronneby needs to have a switch and a server added to it. 70) To configure the network in Ronneby double-click on the Ronneby subnet to enter its subnet view. 71) Place one <Bay Network Accelar1050> switch and one ethernet_server node in the workspace. 72) Rename the <Bay Network Accelar1050> 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. Figure 28 - Application Supported Services 79) Click OK to close the Supported Services dialog box, and then click OK to close the FTP Attributes dialog box. Tommy Svensson 31

32 Figure 29 - Ronneby subnet 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 click OK. Tommy Svensson 32

33 Figure 30 - Scenarios menu 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 Click OK. Figure 31 - Background Utilization dialog The last step in setting background utilization is to apply the changes made to the Karlskrona-Ronneby link to all the selected links. 89) Check the Apply Changes to Selected objects check box in the Karlskorna-Ronneby Attributes dialog box. Tommy Svensson 33

34 Figure 32 - Link Attributes 90) Click OK to 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. Tommy Svensson 34

35 Figure 33 - Results dialog 94) Select the Link Statistics => point-to-point => untilization --> Statistic. Figure 34 - Results dialog 95) Click OK to 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. Tommy Svensson 35

36 96) Select Scenarios => Switch To Scenario, then choose no_back_util. Figure 35 - Scenarios menu 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 <collect>. 102) Set the Sim Duration value for each scenario to 30 and the Time Units to minutes. Tommy Svensson 36

37 Figure 36 - Manage Scenarious 103) Click OK. Modeler will now run simulations for both scenarios. A simulation Sequence dialog box shows 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 Compare Results 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 and choose 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. Tommy Svensson 37

38 Figure 37 - Compare Results dialog 107) Click Show to display the graph. The graph should resemble the one below, though it will not match exactly. Tommy Svensson 38

39 Figure 38 - Utilization graph You may want to look at the utilization of other links to determine the maximum utilization of any link. Let s 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 click Show. The graph should resemble the one below, though it will not match exactly. Tommy Svensson 39

40 Figure 39 - Download Response Time graph 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_models Remove all your saved files. Tommy Svensson 40

41 Laboratory 2 M/M/1 Queue simulation Objective This laboratory is important for understanding OPNET system and user interface. The lab contains a step-by-step example that shows how to use OPNET to construct an M/M/1 queue design and analysis. Overview The task is to construct an M/M/1 queue model and observe the performance of the queuing system as the packet arrival rates, packet sizes, and service capacities change. Two classes of statistics will be measured, Queue Delay and Queue Size. A graph of the confidence interval will also be produced. This laboratory also introduces the use of: Node Model Probe Model Simulation Tool Analysis Tool Tommy Svensson 41

42 Procedure An M/M/1 queue consists of a First-in First-Out (FIFO) buffer (queue) with packet arriving randomly according to a Poisson arrival process, and a processor, that retrieves packets from the buffer at a specified service rate. Three main parameters affects the performance of an M/M/1 queue, namely: Packet arrival rate, λ Packet size, 1/µ Service capacity, C [7] Figure 40 - M/M/1 overview OPNET models are hierarchical. At the lowest level, the behavior of an algorithm or a protocol is encoded by a state/transition diagram, called state machine, with embedded code based on C-type language constructs. At the middle level, discrete functions such as buffering, processing, transmitting and receiving data packets are performed by separate objects. Some of these objects rely on underlying process models. In OPNET, these objects are called modules and they are created, modified and edited in the Node Editor. Modules are connected to form a higher-level node model. At the highest level, node objects are deployed and connected by links to form a network model. The network model defines the purpose of the simulation. The lower-level objects for M/M/1 queue are provided by OPNET, but they need to be combined to form a node model. Tommy Svensson 42

43 Creation of the node model The M/M/1 queue consists of several objects in the Node Editor, namely 2 processors and a queue. One processor is used for (source) packet generation. The second processor is used for the sink module. The source module generates packets and the sink module disposes the packets generated by the source. The queuing system is composed by an infinite buffer and a server. The source module generates packets at an exponential rate. 1) Start OPNET. 2) Open a new project and a new scenario. Name the new project <initials>_mm1net and the scenario MM1. 3) Click Quit in the wizard. 4) Select File => New, then select Node Model from the pull-down list and click OK. The Node Editor appears. 5) Click on the Create Processor button. 6) Place a processor module in the workspace. Right-click to end the operation. 7) Right-click on the processor and select Edit attributes. 8) Change the name attribute to Source. 9) Change the process model attribute to simple_source. Some new generator attributes appears in the attribute list. 10) Left-click in the Value Column of the Packet Interarrival Time attribute to open the Packet Interarrival Time Specification dialog box. 11) From the Distribution Name pop-up menu select Exponential, as in a Poisson process. 12) Set the Mean Outcome to 1.0 and click OK. This sets the mean interarrival time, λ, of a packet to 1 second. Tommy Svensson 43

44 13) Change the Packet Size attribute so that Distribution Name is exponential and Mean Outcome is Click OK. Figure 41 - Processor Model Attributes 14) Click OK to close the Attributes dialog box. In your design you will somehow have to represent the infinite buffer and the server, this will be done by the queue module. 15) To create the queue model click first on the Create Queue Module button and place then a module in the workspace to the right of the generator. 16) When done right click to end the operation. 17) Further right-click on the queue module and select Edit Attributes to bring up its attributes. Tommy Svensson 44

45 Figure 42 Queue Process Model Attributes 18) Change the name attribute to queue. 19) Change the process model attribute to acb_fifo The acb_fifo process is an OPNET-supplied process model that provides service in the packets arriving in the queue according to FIFO discipline. Note that when a process model is assigned to a module, the process model attributes appear in the module s attribute menu. The acb_fifo process model has an attribute called service_rate. When you select the acb_fifo process model, the service_rate attribute appears in the queue module s attribute menu with the default value 9600 bits per second. The name of the model acb_fifo reflects its major characteristics: Characteristics Indicates A Active, acts as its own server C Concentrates multiple incoming packet streams into its single internal queuing resource B Service time is a function of the number of bits in the packet fifo First in first out service ordering discipline 20) Right click on service rate in the attribute column. 21) Select Promote attribute to higher level. The value for this will be set later in the Simulation Set dialog box. 22) Click OK to close the dialog box. Further a sink module should be used although it is not a part of the M/M/1 queue system. The reason for using a sink is for proper memory management, packets should be Tommy Svensson 45

46 destroyed when no longer needed. The OPNET-supplied sink process module destroys the packet sent to it. 23) To create the sink module, activate the Create Processor Module button and then place a processor module to the right of the queue model on the workspace. 24) Open the attribute box for the processor module by right clicking the icon. 25) Change the name attribute to sink. Notice that the default value for the process model attribute is sink. 26) Close the dialog box. Figure 43 - Processor Model Attributes To transfer packets between the generator module, the queue module and the sink module, it will be necessary to connect them together. This is done by packet streams that provide a path for the transfer of packets between modules. They serve as one-way paths and are depicted by solid arrowed lines. 27) Activate the Create Packet Stream button. 28) Connect the source module with the queue module by clicking the source icon, then clicking the queue icon. Remember that the first module you click becomes the source, and the second one the destination. 29) Connect the queue module and the sink module. Remember to end the Create Packet Stream operation by right-clicking anywhere in the window. 30) Select Interface => Node Interfaces. Tommy Svensson 46

47 Figure 44 - Node Types dialog 31) In the Node Types table, click in the Supported cell for the fixed node type. This toggles the value to yes. Make sure mobile and satellite nodes are not supported. 32) Click OK to close the Node Interfaces dialog box. The M/M/1 node model definition is complete. You are now ready to create the network model, but first you should save your work. 33) To save select File => Save. Name the node <initials>_mm1, then click OK and close the Node Editor. The first step in creating the network model is to create a new model list. You can customize the palette to display only the models needed. 34) Click on Open Object Palette button. 35) Click on the Configure Palette button in the object palette. 36) Click on the Model List radio button. 37) Click on the Clear button. 38) Click on the Node Models button. A list on available node models appears. 39) Scroll in the table until you find the <initials>_mm1 node model. Change the status from not included to included. 40) Click OK to close the table. 41) Click the Save button. Enter the name <initials>_mm1_palette. 42) Click OK. Tommy Svensson 47

48 The node model you created is now included in the object palette. Now you can create the network model. 43) Click and drag the <initials>_mm1 node model to the workspace. Right-click to end the operation. 44) Change the name. Right-click and select Set Name. 45) Enter the name m1 and choose OK. Figure 45 - M/M/1 Node Model 46) Save your model. File => Save. We will use the Probe Editor to set the statistics to collect during simulation. This could also be done by the Choose Result option in the object pop-up menu. The Probe Editor is a more powerful collection tool. The Probe Editor will be used to collect queue delay and queue size statistics. 47) Select File => New,then select Probe Model and click OK. You must specify the network model from which the Probe Model should collect statistics. 48) Select Objects => Set Network Model. 49) Choose the <initials>_mm1net-mm1 network model. We will now set the probes. Specifying appropriate probes causes the statistics to be recorded at simulation time. 50) Click the Create Node Statistics Probe button and a probe appears below. Figure 46 Probe Attributes We will use the automatic selection method to type in the attributes for the probe. Tommy Svensson 48

49 51) Right-click on the probe and select Choose Probed Object from the pop-up menu. 52) Expand the m1 node. 53) Select the queue module and click OK. Figure 47 - Probe Objects top.m1.queue appears in the Object column. Figure 48 - Probe Object 54) Right click on the probe and select Edit Attributes from the pop-up menu. 55) Set the name to Queue Delay. 56) Set the submodule attribute to Subqueue[0]. 57) Left-click in the Value column of the statistics row. The Available Statistics dialog box shows the statistics, the group it belongs to and a description. 58) Select queue.queuing delay from the list and click OK. The group attributes changes to queue and the statistics attribute changes to queuing delay in the Edit Attributes dialog box. 59) Set scalar data to enable. 60) Set scalar type to sample mean. 61) Set scalar start to This is done to eliminate the unwanted initial oscillations. 62) Set scalar stop to This equals one hour. Tommy Svensson 49

50 63) Set capture mode to all values. 64) Click OK to close the probe s Attribute dialog box. 65) Click the Create Node Statistics Probe button and a probe appears below. 66) You will now have to set new values to the attributes of the probe, to do so right click on the new probe and select Edit Attributes. The values should be set as follows: name = Queue Size subnet = top node = mm1 module = queue submodule = subqueue [0] group = queue statistic = queue size (packets) scalar data = enabled scalar start = scalar stop = capture mode = all values 67) When done close the probe s Attribute dialog box by clicking OK. The changes will then appear in the Probe Editor. Figure 49 - Probe Model 68) Click on the create attribute button. 69) Right click and select choose attributed object in the pop-up menu. Tommy Svensson 50

51 70) Select top => mm1 =>queue then click OK. 71) Right click on the attribute probe and select edit attributes. 72) Set attribute to service_rate. The probes are now set up correctly and will collect the desired statistics. 73) Save the probe file. File => Save. Name it <initials>_mm1probe. 74) Close the Probe Editor. It s time to begin the simulation. We will use the Simulation Sequence Editor instead of running the simulation form the Project Editor. 75) To open the Simulation Sequence Editor choose Simulation => Configure Discrete Event Simulation (Advanced). 76) Now place the simulation set icon in the workspace and change its values by selecting Edit Attributes. 77) The simulation Duration should be set to 7 hours and the Seed to ) Change the value per statistic to The seed is an initial value for the random generator. You can choose your own arbitrary value. 79) Now select the Advanced tab and then set the probe file to <your initials>_mm1probe. 80) Set Scalar File to <initials>_mm1scalar. 81) Select the Object Attributes tab. 82) Click the Add button. An Add Attributes dialog box appears. 83) Mark Add in the column next to m1.queue.service_rate. 84) Click OK to close the dialog box. 85) Select the m1.queue.service_rate attribute in the Simulation Set dialog box and click the values button. Tommy Svensson 51

52 An Attribute: m1.queue.service_rate dialog box appears. 86) Set the value to ) Set the Limit to ) Set Step to 50. Figure 50 - Simulation Attributes 89) Click OK to close the Attribute: m1.queue.service_rate dialog box. Notice that the number of runs has changed to 4. Figure 51 - Simulation dialog 90) Click OK to close the Simulation Set dialog box. 91) Click on the scenario to mark it. 92) Select Edit => Copy in the menu. 93) Select Edit => Paste. 94) Place the new scenario to the right of its parent. 95) Right click on the new scenario and select Edit Attributes. 96) Change the Seed number to a different value, when done click OK to close the dialog box. Tommy Svensson 52

53 97) Create eight more scenarios by repeating steps 91 to 96. Notice: It s very important that each scenario has different Seed numbers. 98) When finished creating all the scenarios begin the simulation by clicking on the Execute Simulation Sequence button. Wait until the simulation is completed. In this last portion of lab you will learn how to view your results. The tool used for this task is the Analysis Tool. 99) Select File => New from the Project Editor. 100) From the pull-down menu in the dialog box change the file type to Analysis Configuration, then click OK. The Analysis Tool opens in a new window. During the simulation the packets always experience some delay. This delay is named the mean queuing delay and is the first statistic that we are going to take a closer look at. 101) To view the mean queuing delay left-click on the create a graph of a statistic button. 102) When done the View Results dialog box opens. Expand now the following hierarchy: File Statistics => <your initials>_mm1net-mm1 => Object Statistics => mm1 => queue => subqueue [0] => queue. 103) Select the queuing delay statistic. 104) From the list of filters select average. 105) Finally to show the graph click on the Show button. Tommy Svensson 53

54 Figure 52 - View results dialog Compare your graph with the one below, and se if it matches. Tommy Svensson 54

55 Figure 53 - Queue Delay graph The large deviations early in the simulation depends on the sensitivity of averages to the relatively small number of samples collected, as you can see the average stabilizes towards the end of the simulation. The results need to be validated. Calculate the following: 1 Mean arrival rate, λ = = meanint erarrivaltime 1 Mean service requirement, = µ Service capacity, C = Mean service rate, µ C = 1 Mean Delay, W = = µc λ Does the analytic value agree with the simulated result? Tommy Svensson 55

56 Another statistic of interest is the time-averaged queue size. 106) In the View results dialog box, remove the check next to the queuing delay. 107) Place a check next to the queue size (packets) statistic. 108) Select time-average from the pull-down list. 109) Click Show. Figure 54 - View Results dialog Figure 55 - Queue Size graph Tommy Svensson 56

57 From this graph we can draw the conclusion that the system is stable. It reaches steady state after about 2 hours. Validate the result. Calculate the following: λ Ratio of Load to Capacity ρ = = µ C ρ Average Queue Size = 1 ρ Does the analytic value agree with the simulated results? We will produce a queue size versus time averaged queue size graph. 110) Set focus on the time averaged queue size window. 111) Right-click on the graph and choose Add statistics. 112) Place a check next to File Statistics => <initials>_mm1net-mm1 => Object Statistics => m1 => queue => subqueue [0] => queue => queue size (packets). 113) Left-click on the Add box. 114) Save the analysis configuration as <initials>_mm1net-mm1. Tommy Svensson 57

58 Figure 56 - Queue Size, As Is and Average overlapped graph It s important to know the confidence intervals of the simulation results. We will now graph the confidence interval. 115) Load the Scalar file. File => Load output scalar file 116) Select <initials>_mm1scalar. 117) Click the Create graph of two scalars button. 118) Select top.queue.service_rate on the Horizontal roll-down menu. 119) Select top.queue.subqueue[0].queue.queue size (packets).mean on the Vertical roll-down menu. 120) Right click on the graph and select Edit Graph Properties. Tommy Svensson 58

59 121) Check the Show Confidence Interval check box. Figure 57 - Graph Plot properties 122) Click OK to close the dialog. Tommy Svensson 59

60 The graph should resemble the one below. Figure 58 - Queue Size Confidence Intervall graph Tommy Svensson 60

61 In order to get better confidence intervals you need to run more scenarios. The graph below shows the confidence interval of 40 scenarios. The service rate is between 1024 and 1300 with step size 10. Figure 59 - Queue Size Confidence Interval graph Congratulations! You have finished the lab. Tommy Svensson 61

62 Laboratory 3 Ethernet simulation Objective Networks can be generally divided into two broad categories, which are based on using point-to-point connections and on using broadcast channels. In the broadcast channel case, there could be competition for the use of the channel between two or more stations. In the common literature, broadcast channels are referred to as multi-access channels, or random-access channels. The problem of media access is therefore the most important one for this case. Multiple access protocols are implemented primarily in Local Area Networks (LANs). Today s personal computers and workstations are connected by Local Area Networks (LANs), which use a multi-access channel as the basis of their communication. An example of a popular LAN is the Ethernet which uses a random-access scheme for media access. The random-access technique was first used by the ALOHA protocol developed at the University of Hawaii in the 1970s. Another popular random-access protocol is the Carrier Sensing Multiple Access (CSMA) scheme which was developed by XEROX Parc. Further the Ethernet, which is using the Carrier Sensing Multiple Access with Collision Detection (CSMA-CD) scheme, was developed by Dr. Robert M. Metcalfe in [4] Overview In this laboratory we will study Multiple Access Protocols. We will look at the ALOHA, CSMA and Ethernet (CSMA-CD) protocols. The ALOHA is the simplest Multiple Access Protocol and implements therefore only the most basic functionality, which is to send packets. ALOHA has no built mechanism to check if the channel is free before it continues transmitting packets, neither the possibility to detect any collisions on the channel. These flaws limit the use of the bus. By adding carrier sense capability to the Aloha random access protocol the performance is improved. The carrier sense capability is employed in the CSMA (Carrier Sense Multiple Access) protocol. The process waits until the channel is free before transmitting a packet. Because of finite signal propagation times, it is possible for a node to be transmitting before it detects an existing transmission signal. This results in some collisions. [4] Finally the Ethernet protocol implements the capability of both transmitting and monitoring a connected bus link at the same time. It has fullduplex capability. By monitoring the bus link it can determine whether a collision condition exists. If that is the Tommy Svensson 62

63 case a retransmission sequence will commence. This operational mode is commonly referred to as Carrier-Sense Multiple Access with Collision Detection (or CSMA/CD). The objectives of our study are: To take a look at the performance, which s main objective is the throughput. To study various parameters that characterizes the multi-access protocols. To assess via simulation the performance of ALOHA, CSMA and CSMA-CD protocols and to study the throughput of each of them. Procedure OPNET uses the Finite State Machine (FSM) to implement the behavior of a module. FSMs determine a module s behavior when an event occurs, detailing the actions taken in response to every possible event. A process model is a Finite State Machine (FSM). It represents a module s logic and behavior. An FSM consists of any number of states that a module may be in and the necessary criteria for changing states. A state is the condition of a module. For example the module may be waiting for a link to recover. A transition is a change of state in response of an event. Designing the Aloha Transmitter Process Model The Aloha transmitter process must only receive packets from the generator and send them further onto the transmitter. This process model has only two states, idle and tx_pkt. The idle state is an unforced state. That means it returns control to the simulation kernel after executing its executives. The simulation begins in the idle state where it waits for packets to arrive. In this model the FSM (Finite State Machine) begins in an unforced state. Because of that the process needs to be activated with a begin simulation interrupt. When the simulation starts the FSM will execute the idle state and will then be ready to transition with the first arriving packet. The tx_pkt state is a forced state. That means it does not return control to the simulation kernel, but instead immediately executes the exit executives and transitions to another state. The only interrupt expected is the packet arrival interrupt (the arrival of generated packets). It is therefore safe to omit the unforced state a default transition. When a packet interrupt is delivered the FSM should perform executives to acquire and transmit the packet in the tx_pkt state, then transition back to the idle state. 1) Start Opnet. 2) Select File New then Process model. 3) Click on the Create State button and place two states in the workspace. Tommy Svensson 63

64 The first state created is automatically the initial state and indicated by a heavy black arrow pointed towards it (figure 60). Any state can be changed to initial state by right clicking on the state and choose Make Initial state in the pop-up menu. Figure 60 - A initial state 4) Right click on the initial state and choose Edit attributes. 5) Change the name to idle. 6) Make sure the status is unforced. Figure 61 - State Attributes 7) Click OK to accept the changes. 8) Right click on the other state and choose Edit attributes. 9) Change the name to tx_pkt and the status to forced. It is now time to specify the code for the process model starting with the header block. In the header block one usually specify macros to replace more complicated expressions in transition conditions and executives. The use of macros saves place but the key advantage is that it simplifies the task of interpreting an FSM diagram. The header block may also contain #include statements, struct and typedef definitions, extern and global variable declarations, function declarations and C-style comments. 10) Click on the Header Block button. 11) Type in the definitions shown below. Tommy Svensson 64

65 /* Input stream from generator module */ #define IN_STRM 0 /* Output stream to bus transmitter module */ #define OUT_STRM 0 /* Conditional macros */ #define PKT_ARVL (op_intrpt_type () == OPC_INTRPT_STRM) /* Global variable */ extern int subm_pkts; 12) Close the header block editor to save the definitions. IN_STRM and OUT_STRM will be used later to specify which stream to get packets from and to which to send the packets to. In this process model only stream number 0 will be used. It is possible to select any stream number between 0-8. To achieve the desired functionality these stream indices must be consistent with those defined in the node model later. PKT_ARVL is used to determine when a packet interrupt occurred by comparing the value returned by the Simulation Kernel Procedure op_intrpt_type() with the OPNET constant of OPC_INTRPT_STRM. If the comparison evaluates to true, this indicates that the interrupt is due to a packet arriving on an input stream. In this model there is no need to determine which input stream received the packet. A packet in only expected on input stream 0. The global variable subm_pkts will be used to keep track of the number of submitted packets. 13) Create two transitions, one from idle state to tx_pkt state and the second one from tx_pkt state to idle state. Use the create transition button. 14) Right click on the idle tx_pkt transition and select edit attributes. 15) Change the condition attribute to PKT_ARVL. The finished configuration should look like in figure 62. Tommy Svensson 65

66 Figure 62 - Process Model The condition PKT_ARVL is the macro that just has been defined in the header block. The next step is to create state executives needed in the FSM. OPNET allows one to attach code to each part of an FSM. This code is called Proto-C. There are three primary places to use Proto-C, namely: Enter Executives: Code executed when the module moves into a state. Exit Executives: Code executed when the module leaves a state. Transition Executives: Code executed in response to a given event. Although the enter executives and exit executives of forced states are executed without interruption, standard practice is to place all forced state executives in the enter executives block. To bring up the enter executives editor one double clicks on the upper half of the state. Double clicking on the lower half of the state will bring up the exit executives editor. (figure 63) Figure 63 - executives editor click zones Tommy Svensson 66

67 Next step is to define the actions for the idle state. 16) Double-click on the top of the idle state to open the enter executives block 17) Enter the code shown below. /* Get the maximum packet count, */ /* set at simulation run-time. */ op_ima_sim_attr_get (OPC_IMA_INTEGER,"max packet \ count", &max_packet_count); 18) Save your changes to close the text edit pad. op_ima_sim_attr_get (attr_type, attr_name, value_pointer) function takes three arguments. attr_type argument specifies the type of the attribute-of-interest. The acceptable values of this argument are OPC_IMA_INTEGER, OPC_IMA_DOUBLE, OPC_IMA_TOGGLE, or OPC_IMA_STRING. attr_name argument specifies the name of the attribute-of-interest. This value must specify an attribute defined in the simulation environment, or a prompt will be issued for the attribute s value. value_pointer argument specifies a pointer to a variable to be filled with the specified attribute s value. It can accept a pointer to an integer, a double, or a character string. In the last case, the array of characters must be large enough to contain the attribute s value. The data type of the argument pointer must match the data type of the specified attribute, or an error will occur. The max_packet_count variable is not yet defined. The variable will hold the maximum number of packets to be processed in the simulation before it terminates. Variables can be declared in two places. Variables declared in the temporary variables block do not retain their values between invocations of the FSM. Variables declared in the state variables block retain their values from invocation to invocation. The max_packet_count variable value should be retained between invocations and therefore declared in the state variable block. 19) Click the state variable block button. 20) Add the max_packet_count variable. The default type, int, is acceptable. When you are finished click OK to close the dialog box. Tommy Svensson 67

68 Figure 64 - State variable block This value is set later in the simulation attributes. To be able to set the value at simulation run-time it needs to be defined. 21) Select Interface Simulation Attributes and enter an attribute into the dialog box table. Figure 65 - Simulation Attributes dialog box 22) To save your changes click on the OK button. Specify the actions for the tx_pkt state. 23) Double-click on the upper half of the tx_pkt state to open the enter executives block. 24) Enter the code shown below. /* A packet has arrived for transmission. Acquire */ /* the packet from the input stream, send the packet*/ /* and update the global submitted packet counter.*/ out_pkt = op_pk_get (IN_STRM); op_pk_send (out_pkt, OUT_STRM); ++subm_pkts; /*Compare the total number of packets submitted with*/ /*the maximum set for this simulation run.if equal*/ /* end the simulation run. */ if (subm_pkts == max_packet_count) op_sim_end ("Simulation ended when max packet count \ reached.", "", "", ""); Tommy Svensson 68

69 23) Save your changes to close the text edit pad. op_pk_get(instream_index) function returns a pointer to the packet taken from the input stream, instream_index. If the specified input stream does not contain any packets, the value OPC_NIL will be returned by this KP. This situation can be avoided by first calling op_strm_empty() to determine if a stream contains any packets. op_pk_send(packet_pointer, outstream_index ) function takes two arguments. packet_pointer argument specifies a pointer to the packet-of-interest. outstream_index argument specifies the index of an output packet stream. op_sim_end (line0, line1, line2, line3) function takes four arguments. These arguments are message lines. This function terminates the simulation. subm_pkts variable is declared in the header block. It is increased every time a packet is sent. The out_pkt variable is a packet pointer. This variable has not been declared yet. Since the process model acquires packets from the generator stream and immediately transmits them, it is not necessary to retain the packet pointer between process invocations. This variable will be declared in the temporary variable block. Enter the temporary variable block and state variables. 25) Click the temporary variable block button. 26) Enter the following declarations. /* Outgoing packet */ Packet* out_pkt; 27) Save your changes to close the text edit pad. The out_pkt entry in the temporary variable block creates a temporary packet pointer. This is used to extract packets from one stream and insert them into another. The packet pointers existence is only temporary. Since the packet is sent directly there is no need for the pointer to be retained between process invocations. The model is now complete, except for the model interface attribute. To control the attributes visible at the node level, edit the Process Interfaces. You can set initial attribute values or hide attributes. 28) Select Interface Process Interfaces. 29) Change the Initial Value for the begsim intrpt attribute to enabled. Tommy Svensson 69

70 30) Verify that the Initial Value for each of the following attributes is set to disabled. endsim intrpt failure intrpts intrpt interval recovery intrpts super priority 31) Verify that the Initial value of the priority attribute is 0. 32) Change the status attribute to hidden for all attributes Figure 66 - Process Interfaces attributes 33) Click OK to close the dialog box. All process models must be compiled before they can be used in a simulation. Compiling a model makes its object code available to a processor module s process model attribute. 34) Compile the model by clicking on the compile process model action button. 35) Save the model as <initials>_aloha_tx. 36) Close the Process Model Editor when the compilation of the process model has finished. Creating the Aloha Transmitter Node Model 37) Select File New then Node Model from the pull down menu. To accept click OK. 38) Using the create processor action button create two processor modules. 39) Create one bus transmitter by using the bus transmitter action button. Tommy Svensson 70

71 40) Connect the modules with packet streams using the packet stream action button. Figure 67 - Node model overview 41) Right click on the first processor module and select Edit attribites. 42) Set the name to gen and process model to simple_source. The value for the generator s interarrival time needs to be promoted to make it possible to assign different values at simulation time. 43) Click on Packet Interarrival Time in the left column to highlight the Attribute name, then right-click and select Promote Attribute to Higher Level from the pop-up menu. 44) Click OK. Figure 68 - Generator process attributes 45) Right click on the second processor module and select Edit attributes 46) Set the name to tx_proc and process model to <initials>_aloha_tx. 47) Click OK. 48) Change the bus transmitter s name to bus_tx. Tommy Svensson 71

72 Figure 69 - Alhoa transmitter node model Double check the module connectivity to make sure all objects in the model has been connected in the correct order. 49) Right click on the tx_proc module and choose Show Connectivity from the Object pop-up menu. The objects should be connected as shown in figure 70. Figure 70 Connectivity The node interfaces needs to be defined. 50) Select Interfaces Node interfaces. 51) In the Node Types table, change the Supported value to no for the mobile and satellite types. 52) Change the Status of all the attributes to hidden, except for the one with promoted status, gen.packet Interarrival Time. 53) Click OK to save the changes. 54) Save the node model as <initials>_cct_tx. Aloha node model is completed. 55) Close the editor. Tommy Svensson 72

73 Creating the Generic Receiver Node Process Model The generic receiver node process model is responsible for handling received packets for statistics gathering purposes. The goal is to count packets and record statistics. It can be used to monitor network performance whether the packets are transmitted in accordance with the Aloha or the CSMA channel access methods. To process received packets for statistics collection, the cct_rx process needs one unforced state where it waits to receive collision-free packets. Collisions are detected later in the link model. The process records the channel throughput and channel traffic values for analysis at the end of the simulation. It also handles the statistics gathering variables, which should be initiated at the simulation start. 56) Select File New then choose process model. 57) Click on the Create State button and place two states in the workspace. 58) Right click on the initial state and choose Edit attributes. 59) Change the name to init and the status to forced. Click OK. 60) Right click on the second state and choose Edit attributes. 61) Change the name to idle and leave the status as unforced. Click OK. 62) Draw the transitions as shown below. Figure 71 - Transitions overview Tommy Svensson 73

74 Enter the code for the header block. 63) Click the header block action button. 64) Type in the definitions shown below. /* Input stream from bus receiver */ #define IN_STRM 0 /* Conditional macros */ #define PKT_RCVD (op_intrpt_type () == OPC_INTRPT_STRM) #define END_SIM (op_intrpt_type () == OPC_INTRPT_ENDSIM) /* Global variable */ int subm_pkts = 0; 65) Save the header block definitions. IN_STRM is the input stream definition. The macro PKT_RCVD is used to detect received packets. The END_SIM macro determines if the interrupt received by the process is associated with an end-of simulation interrupt delivered by the Simulation Kernel. The global variable subm_pkts is established so that all transmitting nodes can contribute their individual transmission attempts to this accumulator. Declaring a variable in a process model header block causes it to behave as a global variable within the executable simulation. Define the following state variable: 66) Click the state variable action button. 67) Set the name to rcvd_pkts. 68) Set the type to int. 69) Click OK. The rcvd_pkts variable is used to keep track of the number of valid received packets. It needs to be initiated at simulation start. 70) Double-click on the top of the init state to open the enter executives block, and enter the following code: /* Initialize accumulator */ rcvd_pkts = 0; 71) Save the changes to close the dialog. Two functions are needed. One that receives packets and one to write statistics to a scalar file. Tommy Svensson 74

75 72) Open the function block and enter the following code. /* This function gets the received packet, destroys it, */ /* and then logs the incremented received packet total. */ void proc_pkt () Packet* in_pkt; /* Get packet from bus receiver input stream */ in_pkt = op_pk_get (IN_STRM); /* Destroy the received packet */ op_pk_destroy (in_pkt); /* Increment the count of received packets */ ++rcvd_pkts; /* This function writes the end-of-simulation channel */ /* traffic and channel throughput statistics to a */ /* scalar file */ void record_stats () /* Record final statistics */ op_stat_scalar_write ("Channel Traffic G", (double) subm_pkts / op_sim_time ()); op_stat_scalar_write ("Channel Throughput S", (double) rcvd_pkts / op_sim_time ()); The proc_pkt() function acquires each received packet as it arrives, destroys it, and increments the count of received packets. The record_stats() function is called when the simulation terminates. The op_stat_scalar_write function sends the channel throughput and traffic data to a scalar file that is specified in the simulation attributes. The macro definitions and the functions have been defined. There is now a good idea to change the transition conditions. 73) For the first transition between the states, change the condition attribute to PKT_RCVD and the executive attribute to proc_pkt(). 74) For the second transition between the states, change the condition attribute to END_SIM and the executive attribute to record_stats(). 75) For the first transition from idle back to itself, change the condition attribute to PKT_RCVD and the executive attribute to proc_pkt(). 76) For the second transition from idle back to itself, change the condition attribute to default. Tommy Svensson 75

76 77) For the third transition from idle back to itself, change the condition attribute to END_SIM and the executive attribute to record_stats(). Define the process interfaces. 78) Select Interfaces Process Interfaces 79) Change the Initial value of the endsim intrpt attribute to enabled. 80) Change the status of all the attributes to hidden. Figure 72 - Generic Receiver process interfaces attributes 81) Click OK. 82) Click on the Compile Process Model action button. 83) Supply the filename <initials>_cct_rx and click OK. 84) Close the process model editor. Tommy Svensson 76

77 Creating the Generic Receiver Node Model The next step is to create a generic receiver node model. 85) Begin by selecting File New then Node Model from the pull down menu. Click OK to accept. 86) Click on the create processor action button and place one processor in the workspace. 87) Create also a bus receiver module in the workspace to the right of the processor by clicking on its action button. 88) Connect the two modules from the bus receiver to the processor by using a packet stream. 89) Change the name of the processor to rx_proc and the name of the bus receiver to bus_rx. The finished configuration should look like the picture below: Figure 73 - Generic reciever model overview 90) Open the processors attribute dialog box and set the process model attribute to <initials>_cct_rx. Close the dialog box when finished. The interface attributes remains to be set before the node model is completed. 91) Select Interfaces Node Interfaces. 92) The supported value should be changed to no for the mobile and satellite types in the Node types table. Figure 74 - Supported node types Tommy Svensson 77

78 93) Further, in the Attributes table change the status to hidden for all the attributes. Figure 75 - Node interfaces attibutes 94) Close the node model editor after saving the node model as <initials>_cct_rx. Tommy Svensson 78

79 Creating a new link model The behavior of a bus link is defined by its Transceiver Pipeline stages. The pipeline is a series of C or C++ procedures which can be modified to customize the link model. This bus link model will use the default pipeline stages. Default pipeline stages are denoted by the dbu_ prefix. The table below lists pipeline stages by function. Model txdel closure propdel coll error ecc Bus Transceiver Pipeline Model Stages Function Computes the transmission delay associated with the transmission of a packet over a bus link (transmission delay is the time required to transmit the packet at the bit rate defined in the relevant bus transmitter module). Determines the connectivity between any two stations on the bus. Calculates the propagation delay between a given transmitter and a receiver. Determines whether a packet has collided on the bus. Calculates the number of bit errors in a packet. Rejects packets exceeding the error correction threshold as well as any collided packets. 95) Select File New then choose Link model. Click OK. This link model supports only the bus and bus tap types. 96) In the Link Types table, change the Supported value to no for the ptsimp and ptdup types. Figure 76 - Supported Link Types 97) Save the file as <initials>_cct_link and close the Link Model Editor. Tommy Svensson 79

80 Creating the network model The network model will be built so that it can be used when analyzing both the Aloha and CSMA protocols. This will be done by defining the nodes so that they reference the generic node models, and later changing the referenced process models at the node level. The analytical Aloha model assumes that packets are always introduced into the network at exponentially distributed interarrival times. This network model will contain a finite number of nodes. To closely follow the analytical model s assumptions, a relatively large number of transmitter nodes must exist on the bus. The network model will be constructed within a subnet so that a small scale coordinate system can be used. 98) Select File New then choose Project and click OK. 99) Name the project <initials>_cct_network and the scenario aloha, then click OK. 100) In the Startup Wizard, use the following settings: Dialog Box Name Initial Topology Choose Network Scale Specify Size Select Technologies Review Value Default value: Create Empty Scenario Office ( Use Metric Units enabled) 700 m x 700 m None Check values, then click OK In order to easily build your network, one needs a custom palette that contains the necessary objects for your network. 101) Open the Object palette if it s not already opened. 102) Click on the Configure Palette button. 103) Click on the Clear button in the Configure Palette dialog. 104) Click on the Node Models button and add <initials>_cct_tx and <initials>_cct_rx from the list of available node models. 105) Click OK. 106) Click on the Link Models button and add <initials>_cct_link from the list of available link models. Tommy Svensson 80

81 107) Click OK. 108) Click on the Save button in the Configure Palette dialog and save the palette as <initials>_cct. 109) Click OK to close the Configure Palette dialog box. The next step is to create bus network. Instead of creating the entire bus network by hand, you can use rapid configuration to build it quickly. 110) Select Topology Rapid Configuration. 111) Choose Bus and click OK. In the Model area. 112) Select <initials>_cct_tx in the Node model pull-down list. 113) Select <initials>_cct_link in the Link model pull-down list. 114) Enter the value 20 in the Number field. 115) Select <initials>_cct_link in the Tap model pull-down list. In the Placement area. 116) Select Horizontal radio button. 117) Check the Top of bus and Bottom of bus check boxes. 118) Enter X: 100 and Y: 200 for Head of bus. 119) Enter the value 500 for the Bus Size. 120) Enter the value 100 for Tap Size. Tommy Svensson 81

82 Figure 77 - Rapid Configuration dialog All the transmitter nodes have been created. The network needs a receiver node. 121) Click and drag the receiver node <initials>_cct_rx from the palette into the left side of the tool area. 122) Click on the <initials>_cct_link tap link in the palette and draw a tap from the bus to the receiver node. Drawing a tap from the node to the bus may produce different results. Tommy Svensson 82

83 The completed bus model should resemble the one below. Figure 78 - Bus model overview 124) Save the project as <initials>_cct_network. Executing the Aloha Simulation The goal is to observe how the performance of the protocol varies as a function of channel traffic. The interarrival time input parameter will be varied in a series of simulations to produce different levels of traffic so that one can observe different levels of throughput. 123) Select Simulation Configure Discrete Event Simulation (Advanced) 124) Right-click and choose Edit attributes 125) Change the values in the common tab: Duration to sec and seed to an arbitrary integer. 126) Click on the Global Attributes tab and set max packet count value to ) Click on the Object Attributes tab and click on the Add button. 128) Add Office Network. *.gen.packet Interarrival Time and click OK. 129) Click the on the Values button. 130) Click in the value column and choose exponential (mean) in the pop-up list. Tommy Svensson 83

84 131) Set the value 1000 by replacing mean with the value. (see figure 79) Figure 79 - Setting exponential value 132) Repeate the last 2 steps to enter the following values: 200, 150, 100, 80, 50, 35, 30, 25, 20, 18,15 Figure 80 - Interarrival time values 133) Click OK. 134) Click on the Advanced tab. 135) Set Network to <initials>_cct_network-aloha. 136) Set Probe file to NONE. 137) Set Scalar file to <initials>_cct_a. 138) Click OK. Tommy Svensson 84

85 If the output scalar file <initials>_cct_a does not exist when the simulation sequence begins, it will be created so that scalar results may be recorded. If the file already exists, the simulation executables will append their scalar results to this file. To avoid viewing obsolete results which may already exist in a similarly named file, the output scalar file <initials>_cct_a must be deleted if it exists. 139) Select File Model Files Delete Model Files... A list of delete able file types appears. 140) Select the Output Scalars item. A list of available scalar files appears. 141) If the list contains the output scalar file <initials>_cct_a, select the entry to delete the file. 142) Close the open dialog boxes. The simulation is now ready for execution. 143) Click on the Execute Simulation Sequence action button. 144) Click OK to confirm execution. 145) When the simulations are complete, close the Simulation Sequence dialog box and the Simulation Sequence editor. Aloha channel performance can be measured according to the number of successfully received packets as a function of the number of packets submitted. In this network, channel throughput is a typical measurement of network performance. The results of each simulation are stored as two scalar values in the output scalar file. That allows us to view the network s performance as a function of an input parameter rather than a function of time. The channel throughput as a function of the channel traffic across all simulations can be viewed in the Analysis Configuration Editor. 146) Select File New and then choose Analysis Configuration. Click OK. 147) Select File Load Output Scalar File. 148) Select <initials>_cct_a. 149) Click on the Create graph of two scalars file action button. Tommy Svensson 85

86 150) Select Channel Traffic G from the Horizontal pull-down menu. 151) Select Channel Throughput S from the Vertical pull-down menu. 152) Click OK. Figure 81- Create graph of two scalars dialog The graph should resemble the one below. Figure 82 - Aloha channel throughput as a function of Channel traffic The Aloha bus simulation is now completed. Tommy Svensson 86

87 Creating the CSMA transmitter process model By adding carrier sense capability to the Aloha random access protocol the performance is improved. The process waits until the channel is free before transmitting a packet. Because of finite signal propagation times, there is a risk for a node to transmit before it detects an existing transmission signal. This results in some collisions. The carrier sense capability is employed in the CSMA (Carrier Sense Multiple Access) protocol. 153) Select File Open then Process Model from the pull down menu in the Project Editor. 154) Select the <initials>_aloha_tx model then click OK. Modifications have to be made for adjusting the process model to CSMA. 155) Click on the Header Block button. 156) Add the following lines to the end of the existing code. /* Input statistic indices */ #define CH_BUSY_STAT 0 /* Conditional macros */ #define FREE (op_stat_local_read (CH_BUSY_STAT) == 0.0) #define PKTS_QUEUED (!op_strm_empty (IN_STRM)) #define CH_GOES_FREE (op_intrpt_type () == OPC_INTRPT_STAT) The Macro FREE makes the process verify that the channel is free before transmitting. The Macro PKTS_QUEUED checks if the queue is empty. The Macro CH_GOES_FREE keeps track of when the channel becomes empty and ready for a new transmission. 157) Select File Save to save and exit the Header Block. 158) Now create a new state in the Process Model and name it wt_free. 159) Create a transition from wt_free to tx_pkt, and change the condition to CH_GOES_FREE. 160) Create a transition from the wt_free state back to itself and set the condition to default. 161) Create a transition from the idle state to wt_free and change the condition to PKT_ARVL &&!FREE. Tommy Svensson 87

88 162) Add a transition from the idle state back to itself with a condition of default. 163) Change the condition on the transition from idle state to the tx_pkt state to PKT_ARVL && FREE. 164) Change the unconditional transition from tx_pkt to idle to conditional by setting the condition attribute to default. 165) Create a transition from tx_pkt back to itself, and set the condition to PKTS_QUEUED && FREE. 166) Finally, create a transition from tx_pkt to wt_free and set the condition to PKTS_QUEUED &&!FREE. The finished configuration should look like in the picture below. Figure 83 - CSMA process model overview 167) Select File Save As and rename the model <initials>_csma_tx. 168) Compile the model then close the Process Editor. Tommy Svensson 88

89 Creating the CSMA transmitter node model The Aloha transmitter node model will now be enhanced so that it supports CSMA. A bus receiver module and a sink processor will be added to the existing Aloha model. The bus receiver module delivers a falling edge statistic interrupt to the processor module when the receiver busy statistic changes from busy to free. The sink processor accepts and destroys the packets received by the receiver module. The enhancements also include an inactive statistic wire which will both inform the process (contained in the tx_proc module) of the busy status of the channel as well as provide interrupts to the process when the channel condition changes. 169) Select File Open and choose Node Model in the roll-down list. 170) Select the <initials>_cct_tx model in the list and click OK. 171) Click on the create processor action button. 172) Place a processor on the workspace above the existing model. 173) Click on the create bus receiver action button. 174) Place a bus receiver next to the new processor. 175) Change the name of the new processor module to sink and the name of the bus receiver to bus_rx. 176) Click on the create packet stream button 177) Make a connection form the bus_rx receiver to the sink processor. Figure 84 -New modules in the CSMA node model 178) Click on the create static wire action button. Tommy Svensson 89

90 179) Connect bus_rx module with tx_proc module. 180) Right click on the static wire and choose Edit Attributes 181) Set the falling edge trigger attribute to enabled and rising edge trigger attribute to disabled. Click OK. Figure 85 - Static wire attributes 182) Right click on the tx_proc module and choose Edit attributes ) Change the process model attribute to <initials>_csma_tx. Click OK. The processor now uses the CSMA process model created previously. 184) Select File Save As... and rename the model <initials>_cct_csma_tx. 185) Close the Node Editor. Tommy Svensson 90

91 Redefining the network model The appropriate models needed to support CSMA are now created. The existing network model needs to be modified to use the new models. Instead of creating an entirely new model, one can duplicate the existing scenario (including the network model) and make the appropriate changes. 186) Select Scenarios Duplicate Scenario in the project editor. 187) Name the new scenario CSMA. The only change to the network model is to use the new CSMA transmitter node model. It needs to be added to the object palette. 188) Open the Object palette if it s not already opened and click on the configure palette action button. 189) Click on the Node models action button. 190) Include <initials>_cct_csma_tx node model and click OK. 191) Click on the save button and save the palette with the default name. All transmitter nodes in the network model need to be changed to use the new transmitter model. 192) Right-click on one of the transmitter nodes and choose Select Similar Nodes from the Object pop-up menu. All 20 transmitter nodes are selected. 193) Right-click on any of the selected nodes and choose Edit Attributes from the pop-up menu. 194) Change the model attribute to <initials>_cct_csma_tx. 195) Check Apply Changes to Selected Objects check box in the bottom left, then click OK. The nodes are now modified to use the new node model. Tommy Svensson 91

92 Configuring CSMA Simulations Configure a series of simulations for the CSMA model. 196) Save the project. File Save. 197) Select Simulation Configure Discrete Event Simulation (Advanced). 198) Right-click on the simulation set and select Edit Attributes from the pop-up menu. 199) Change the seed to any arbitrary integer. 200) Click on the Advanced tab. 201) Change the Scalar file to <initials>_cct_c. 202) Set Probe file to NONE. 203) Click OK. 204) Save the simulation sequence, File Save. 205) Delete any existing output scalar files with the name <initials>_cct_c. 206) Execute the simulation. 207) Close the simulation sequence editor when the simulation is finished. Tommy Svensson 92

93 Analyzing the CSMA results The simulation is now complete and the results can be viewed. 208) Open the Analysis Configuration Editor, File New then Analysis Configuration. Click OK. 209) Choose File Load Output Scalar File. 210) Select <initials>_cct_c from the list of available files. 211) Click on the Create a graph of two scalars action button. 212) Select Channel Traffic G from the Horizontal pull-down menu. 213) Select Channel Throughput S from the Vertical pull-down menu. Your graph should resemble the one below: Figure 86 - CSMA channel throughput as a function of Channel traffic The goal is to compare the Aloha and CSMA protocols. The easiest way to do so is to display both traces on the same graph. Tommy Svensson 93

94 Viewing Both Results on the Same Graph To view both results on a single graph panel, we need to first create a scalar graph for the Aloha results and then create a vector graph that displays both results. Create a scalar graph for the Aloha results. 214) Select File Load Output Scalar File. 215) Select <initials>_cct_a from the menu. 216) Click on the Create a graph of two scalars action button. 217) Select Channel Traffic G from the Horizontal pull-down menu. 218) Select Channel Throughput S from the Vertical pull-down menu. 219) Click OK. Create a vector graph that displays both results. 220) Select Panels Create Vector Panel. 221) Open the Displayed Statistics menu, and select both displayed statistics. 222) Change the display mode to Statistics Overlaid. Figure 87 - Create Vector Panel dialog 223) Click Show. Tommy Svensson 94

95 The graph should resemble the one below. Figure 88 - Aloha and CSMA traffic overlaid 224) Right-click on the multiple vector graph and select Edit Graph Properties. Notice the pop-up menu of active traces in the top section of the dialog box. Click and hold this menu to see the list of active traces. Both are named Channel Throughput S. Which is the CSMA trace and which the Aloha trace? Figure 89 - Active traces pop-up menu In this pop-up menu, traces are listed in the order in which they were added to the multitrace graph. The first trace listed in the pop-up menu is the CSMA trace. Change the labels for the CSMA trace. 225) Change the Custom Title to CSMA Channel Throughput. Tommy Svensson 95

96 226) Click on the Apply button. Change the labels for the Aloha trace. 227) Select the second active trace in the pop-up menu. 228) Change the Custom Title to Aloha Channel Throughput. 229) Click OK. Figure 90 - Aloha and CSMA renamed traces overlaid The CSMA protocol is shown to be superior to the Aloha protocol at all channel traffic loads. 230) Close the graphs and the Analysis Configuration Editor. Tommy Svensson 96

97 Ethernet network model The Ethernet protocol implements the capability of both transmitting and monitoring a connected bus link at the same time. It has fullduplex capability. By monitoring the bus link it can determined whether a collision occurs. This operational mode is commonly referred to as Carrier-Sense Multiple Access with Collision Detection (CSMA/CD). This is accurately modeled by an OPNET-supplied example model. The Ethernet model is to complex too be modeled in this lab. Instead we will use the OPNET-supplied example model. Our Ethernet network consists of a multi-tap bus network populated by eight nodes. The nodes employ the node model ethcoax_station_adv. The ethcoax_station_adv node model is significantly more complex than the Aloha or CSMA node models. It has four processor modules, a queue module which performs the bulk of the channel access processing, and a pair of bus receiver and transmitter modules. (Figure 91) Figure 91 - Ethcoax_station_adv node model The bus_tx and bus_rx modules serve as the bus link interface. These modules are set to transmit and receive at a data rate of 10 Mbits/second by default. Figure 92 - bus_tx attributes Tommy Svensson 97

98 The sink processor represents higher layers and simply accepts incoming packets that have been processed through the mac (medium access control) process. The defer processor independently monitors the link s condition and maintains a deference flag that the mac process reads over a statistic wire to decide whether transmission is allowed. The bursty_gen module represents higher layer users who submit data for transmission. It uses an ON-OFF pattern for traffic generation. The mac process handles both incoming and outgoing packets. Incoming packets are decapsulated from their Ethernet frames and delivered to a higher level process. Outgoing packets are encapsulated within Ethernet frames and when the deference flag goes low, a frame is sent to the transmitter. This process also monitors for collisions, and if one occurs, the transmission is appropriately terminated and rescheduled for a later attempt. 231) Open a new project. File New and choose project. 232) Name the project <initials>_ethernet and the scenario bus. 233) Create an empty scenario. Click next. 234) Choose Office. Click next. 235) Choose X span 100 and Y span 100. Click next. 236) Include ethcoax. Click next. 237) Review the settings then click OK. Proceed by constructing the network. 238) Use the rapid configuration tool. Topology Rapid configuration. 239) Choose bus. Click OK. Tommy Svensson 98

99 240) Make the following configuration: Node model: ethcoax_station Link model: eth_coax Tap model: eth_tap Number: 8 Placement: Horizontal, Top of bus and Bottom of bus. Head of bus: X=10 and Y=50 Bus: 80 Tap: 20 Figure 93 - Rapid Configuration dialog 241) Click OK. 242) Right click on one node and choose select similar nodes from the pop-up menu. 243) Right click on a node and select edit attributes. Tommy Svensson 99

100 244) Make the following configuration: Traffic Generation Parameters Start Time: constant (5.0) ON State Time: Exponential (100) OFF State Time: Exponential (0) Packet Generation Arguments Interarrival time: Exponential ( ) Packet Size: Constant (1250) Segmentation size: No segmentation Stop time: Never Figure 94 - Node attributes 245) Check the Apply Changes to Selected Objects check box. (figure 95) Figure 95 Apply Changes to Selected Objects check box 246) Save the project with the default name. File Save. The network model is completed. To gather the statistics of interest a probe model is needed. 247) Select File New and choose probe model from the menu. Click OK. The statistic of interest is the bus utilization. 248) Add a link statistic probe. Click on the add link statistic probe action button. 249) Choose network model to probe. Select Object Set Network Model. 250) Click on <initials>_ethernet-bus in the list. Tommy Svensson 100

101 251) Right click on the link probe and select choose probed link. 252) Expand the tree and then select top.office Network.bus 0. Click OK. Figure 96 - Link object tree 253) Right click on the link probe and choose edit attributes. 254) Set the name attribute to Bus Utilization. 255) Set the statistic attribute to bus.utilization. 256) Save the probe as <initials>_ethernet-probe. The probe model is now completed. Proceed by executing the simulation. 257) In the project window, select Simulation Configure Discrete Event Simulation (Advanced). 258) Right click on the scenario and select edit attributes. 259) In the common tab set: Duration: 60 seconds Seed: Any arbitrary integer. 260) In the advanced tab set: Network: <initials>_ethernet-bus Probe file: <initials>_ethernet-probe Vector file: <initials>_ethernet-vector 261) Click on the Run action button to execute the simulation. 262) Close the simulation sequence window when the simulation is completed. 263) Open the Analysis Configuration tool. File New and then Analysis Configuration. 264) Click on the create graph of a statistic action button. 265) Expand File statistic.<initials>_ethernet-vector.object statistics.office Network.bus_0 [0].bus. 266) Check the utilization statistic. Tommy Svensson 101

102 267) Choose Average from the menu and click Show. Figure 97 - View results dialog Tommy Svensson 102

103 The graph should resemble the one below. As you can see, the throughput after 30 seconds of simulation stabilizes near 5.5 Mbps/sec. This demonstrates the superiority of the carrier-sensing, collisiondetection, and backoff strategies used by Ethernet over the less sophisticated methods used by the pure Aloha and CSMA protocols. The lab is now completed. Tommy Svensson 103

104 Laboratory 4 TCP simulation Objective The purpose of this lab is to demonstrate the functioning of TCP, and particularly the four algorithms used for congestion control: slow start, congestion avoidance, fast retransmit and fast recovery. The lab provides a number of scenarios to simulate and compare these algorithms. Overview In this lab we will study TCP s four intertwined congestion control algorithms, namely: slow start, congestion avoidance, fast retransmit and fast recovery. The objectives are: To study the behavior and implementation of slow start and congestion avoidance algorithms. To study modifications to the congestion avoidance algorithm, namely fast retransmit and fast recovery. Procedure Slow start and congestion avoidance Previous versions of TCP start a connection with the sender injecting multiple segments into the network, up to the windows size advertised by the receiver. This is ok when the hosts are placed on the same LAN. But if there are routers and slower links between the sender and the receiver different problems can arise. Some intermediate router must queue the packets and it is possible for the router to run out of space in the queue. The algorithm to avoid this is called slow start. Beginning transmission into a network with unknown conditions requires TCP to slowly probe the network to determine the available capacity, in order to avoid congesting the network with an inappropriate large burst of data. Slow start adds another window to the sender s TCP: the congestion window, called cwnd. When a new connection is established with a host on another network, the congestion window is initialized to one segment (typically 536 bytes or 512 bytes). The sender starts by transmitting one segment and waiting for its ACK. When that ACK is received, the congestion window is increased from one to two, and two segments can be sent. When each of those two segments is acknowledged, the congestion window is increased to four. This provides an exponential growth, although it is not exactly exponential because the receiver may delay its ACK s, typically sending one ACK every two segments that it receives. The sender can transmit up to the minimum of the congestion window and the advertised window. The congestion window is flow control Tommy Svensson 104

105 imposed by the sender, while the advertised window is flow control imposed by the receiver. At some point the capacity of the internet can be reached and an intermediate router will start discarding packets. This tells the sender that its congestion window has gotten too large. Congestion avoidance is a way to deal with lost packets. Congestion can occur when data arrives on a big pipe (a fast LAN) and outputs on a smaller pipe (a slower WAN). Congestion can also occur when multiple input streams arrive at a router whose output capacity is less than the sum of the inputs. There are two indications of packet loss at a sender: a timeout occurring and the receipt of duplicate ACK s. However, the overall assumption of the algorithm is that packet loss caused by damage is very small (much less than 1%), therefore the loss of a packet signals congestion somewhere in the network between the source and destination. Although congestion avoidance and slow start are independent algorithms with different objectives, in practice they are implemented together. When congestion occurs TCP must slow down its transmission rate of packets into the network, and then invokes slow start to get things going again. [3] The combined congestion avoidance and slow start algorithms require that two variables are maintained for each connection: A congestion window (cwnd). A slow start threshold size (ssthresh). The combined algorithm operates as follows: a) Initialization for a given connection sets cwnd to one segment and sstresh to bytes. The initial value of cwnd must be less than or equal to 2*SMSS bytes and must not be more than 2 segments. SMSS, Sender Maximum Segment Size, is the size of the largest segment that the sender can transmit. The initial value of cwnd may be arbitrarily high (some implementations use the size of the advertised window), but it may be reduced in response to congestion. b) The TCP output routine never sends more than the minimum of cwnd and receiver s advertised window. c) When congestion occurs one-half of the current window size is saved in ssthresh. Additionally, if the congestion is indicated by a timeout, cwnd is set to one segment. Congestion is indicated by a timeout or the reception of duplicate ACK s. d) When new data is acknowledged by the other end, increase cwnd. The way in which cwnd is increased depends on whether TCP is performing slow start or congestion avoidance. If cwnd is less than or equal to ssthresh, TCP is in slow start, otherwise TCP is performing congestion avoidance. Slow start continues until TCP is halfway to where it Tommy Svensson 105

106 was when congestion occurred, and then congestion avoidance takes over. This is done due to the recorded half of the window size that caused the problem. As mentioned earlier slow start increases congestion window (cwnd) exponentially. Congestion avoidance on the other hand dictates that congestion window (cwnd) be incremented by segsize * segsize / cwnd each time an ACK is received, where segsize is the segment size and cwnd is maintained in bytes. This results in a linear growth of cwnd, compared to slow start s exponential growth. The increase in cwnd should be at most one segment each round-trip time (regardless how many ACK s are received in that RTT) whereas slow start increments cwnd by the number of ACK s received in a round-trip time. [2] Slow start and congestion avoidance simulation This network setup utilizes TCP as its End-to-End transmission protocol. One server is placed in Paris and one client is placed in Stockholm. The Congestion window size will be analyzed with different mechanism. This network is assumed to be perfect with no packet loss. Tommy Svensson 106

107 Create the network 1) Start OPNET and create a new project. File New and choose project in the pop-up window. 2) Name the project <initials>_tcp and the scenario NoDrop. Click OK. 3) Select Create Empty Scenario and click next. 4) Select Choose From Maps and click next. 5) Choose Europe from the maps and click next. 6) Do not include any technologies and click next. 7) Review the values and click OK. 8) Open the Object palette if it s not already open and make sure that the opened palette is internet_toolbox. Figure 98 - Internet toolbox selected in the object palette 9) Add an Application Config object to the workspace and rename it to Applications. 10) Right click on the Applications node and choose Edit Attributes. 11) Click in the value column on the Application Definitions row. Choose Edit Figure 99 - Applications attributes 12) Set the Rows attribute value to 1. 13) Set the Application name to FTP_Application. Click OK. 14) Go to Application definitions Row 0 Description FTP and choose Edit 15) Set the following values: Tommy Svensson 107

108 Attribute Value Command Mix (Get/Total) 100% Inter-Request Time (seconds) constant (3600) File Size (bytes) constant ( ) Symbolic Server Name FTP Server Type of service Best Effort (0) RSVP Parameters None Back-End Custom Application Not Used 16) Click OK. 17) Click OK to close Application Attributes. 18) Add a Profile Config object to the workspace and rename it to Profiles. 19) Right click on the Profile node and choose Edit attributes 20) Click in the value column on the Profile Configuration row. Choose Edit Figure Profiles attribute 21) Set the Rows attribute to 1. 22) Set Profile Name to FTP_Profile. 23) Set Operation Mode to Serial (Ordered). 24) Set Start Time to constant (100) and Duration to End of Simulation. 25) Set Repeatability to Once at Start Time. 26) Click in the Applications column and choose Edit 27) Set the Rows attribute to 1. 28) Set Name to FTP_Application. 29) Set Start Time Offset to constant (5) and Duration to End of Profile. 30) Set Repeatability to Once at Start Time. 31) Click OK to close the Applications Table. Tommy Svensson 108

109 32) Click OK to close the Profile Configuration Table. The Profiles Attributes should look like the picture below: Figure Profiles Attributes 33) Click OK to close the Profiles Attributes dialog. Tommy Svensson 109

110 Create the Paris subnet 34) Place a subnet in Paris. 35) Set the name to Paris. 36) Double click on the Paris subnet node. 37) Place an ethernet_server in the workspace. Rename it to Server_Paris. 38) Place an ethernet4_slip8_gtwy router in the workspace next to the server. 39) Rename it to Router_Paris. 40) Connect the server and the router with a 100BaseT cable. 41) Right click on Server_Paris and choose Edit Attibutes 42) Go to the Application: Supported Services attribute and choose Edit Figure Server Paris attributes 43) Set the Rows attribute to 1. 44) Choose the name FTP_Application and click OK. 45) Edit the Server Address attribute and set value to Server_Paris. 46) Expand TCP Parameters. 47) Disable both Fast Retransmit and Fast Recovery. 48) Click OK. 49) Save the project. File Save. Tommy Svensson 110

111 Figure Paris Subnet nodes 50) Click the Go to next higher level action button. The Paris subnet is now configured. Tommy Svensson 111

112 Create the Stockholm subnet 51) Place a subnet in Stockholm. 52) Set the name to Sthlm. 53) Double click on the Sthlm subnet node. 54) Place an ethernet_wkstn in the workspace. Rename it to Client_Sthlm. 55) Place an ethernet4_slip8_gtwy router in the workspace next to the client. 56) Rename it to Router_Sthlm. 57) Connect the client and the router with a 100BaseT cable. 58) Right click on the Client_Sthlm node and choose Edit Attributes 59) Go to the Application: Supported Profiles and choose Edit Figure Edit Application: Supported Profiles 60) Set the Rows attribute to 1. 61) Change the Profile Name attribute to FTP_Profile. 62) Click OK. 63) Set the Client Address attribute value to Client_Sthlm. 64) Go to the Application: Destination Preferences and choose Edit 65) Set the Rows attribute to 1. 66) Set the Symbolic Name attribute to FTP Server. 67) Click in the Actual name column. 68) Set the Name attribute to Server_Paris. Click OK to close Actual name table dialog. 69) Click OK to close Application: Destination Preferences dialog. Tommy Svensson 112

113 70) Click OK to close Client_Sthlm Attributes dialog. 71) Save the project. File Save. The Stockholm subnet is now configured. Figure Subnet Sthlm nodes 72) Click the Go to next higher level action button. Tommy Svensson 113

114 Create the IP Cloud 73) Place an ip32_cloud on the workspace between Stockholm and Paris. 74) Set the name to Europa_Internet. 75) Connect the Paris subnet to the Europa_Internet IP Cloud with a PPP_DS3 cable. 76) Select Paris.Router_Paris in the pop-up menu. 77) Connect the Sthlm subnet to the Europa_Internet IP Cloud with a PPP_DS3 cable. 78) Select Sthlm.Router_Sthlm in the pop-up menu. The IP Cloud is now configured. Figure Network overview Tommy Svensson 114

115 Choose Statistics 79) Enter the Paris Subnet. 80) Right click on Server_Paris and select Choose Indivitual Statistics from the pop-up menu. 81) Expand Node Statistics TCP Connection and select Congestion Windows Size (bytes) Figure 107 Choose Results dialogue 82) Right click on the Congestion Window Size (bytes) and select Change Collection mode. 83) Check the Advanced checkbox in the pop-up dialog. 84) Change Capture mode to all values. 85) Click OK to close the dialog. Tommy Svensson 115

116 86) Click OK to close the Choose results dialog. 87) Save the project. File Save. Tommy Svensson 116

117 Slow start and Congestion avoidance simulation 88) Select Simulation Configure Discrete Event Simulation in the menu. 89) Set Duration to 10 minutes. 90) Click Run. 91) Click Close when the simulation has finished. View the results 92) Right click on the workspace and choose View Results. 93) Expand Object statistics Choose From Maps Network Paris Server Paris TCP Connection and select Congestion Window Size. 94) Click Show. The graph should resemble the one below. Figure Slow start and Congestion Avoidance Tommy Svensson 117

118 Fast retransmit Fast retransmit is a modification to the congestion avoidance algorithm. The TCP sender should use fast retransmit algorithm to detect and repair loss, based on incoming duplicate ACK s. The fast retransmit algorithm uses the arrival of 3 duplicate ACKs (4 identical ACK s without the arrival of any other intervening packets) as an indication that a segment has been lost. After receiving 3 duplicate ACK s, TCP performs a retransmission of what appears to be the missing segment, without waiting for the retransmission timer to expire. The fast retransmit algorithm first appeared in the 4.3BSD Tahoe release. Fast recovery Congestion avoidance without slow start is performed after fast retransmit sends what appears to be the missing segment. It is an improvement that allows high throughput under moderate congestion, especially for large windows. In this case the reason for not performing slow start is that the receipt of duplicate ACK s tells TCP that more than just one packet has been lost. Since the receiver can only generate the duplicate ACK when another segment is received, that segment has left the network and is in the receiver s buffer. In other words there is still data flowing between the two ends, and TCP does not want to reduce the flow abruptly by going into slow start. The fast recovery algorithm appeared in the 4.3BSD Reno release. The fast retransmit and fast recovery algorithms are usually implemented together as follows: a) When the third duplicate ACK is received, set ssthresh to no more than one-half the current congestion window, cwnd, but no less than two segments. Retransmit the missing segment, and then set cwnd to ssthresh plus 3 times the segment size. This increases the congestion window by the number of segments that have left the network and which the other end has cached. b) Each time another duplicate ACK arrives, increment cwnd by the segment size. This inflates the congestion window for the additional segment that has left the network. c) Transmit a segment (packet) if allowed by the new value of cwnd and the receiver s advertised window. d) When the next ACK arrives that acknowledges new data, set cwnd to ssthresh. This ACK should be the acknowledgment of the retransmission from step a, one round-trip time after the retransmission. Additionally, this ACK should acknowledge all the intermediate segments sent between the lost packet and the receipt of the first duplicate ACK. This step is congestion avoidance, since TCP is down to one-half the rate it was at when the packet was lost. Tommy Svensson 118

119 Fast Retransmit and Fast Recovery simulation Two additional scenarios will be created to study the behavior of fast retransmit and fast recovery algorithms. The network just created was assumed to be perfect with no packet loss. In the following scenarios packet loss will be introduced. Create the Tahoe scenario 95) Select Scenarios Duplicate Scenario. 96) Name the scenario Tahoe. 97) Right click on the IP Cloud, Europa Internet, and choose Edit Attributes. 98) Set the Packet Discard Ratio attribute to 0.5%. Figure Europa internet attributes 99) Click OK. 100) Enter the Paris subnet. 101) Right click on Server_Paris and choose Edit Attributes 102) Expand TCP Parameters. 103) Change the Fast Retransmit attribute to Enabled. Figure Server Paris TCP attributes 104) Click OK. 105) Save the project. File Save. Create the Reno scenario 106) Select Scenarios Duplicate Scenario. 107) Name the scenario Reno. 108) Right click on the Server_Paris and choose Edit Attributes Tommy Svensson 119

120 109) Expand TCP Parameters. 110) Change the Fast Recovery attribute to Reno. Figure Server Paris TCP attributes 111) Click OK. 112) Save the project. File Save. Simulate the scenarios 113) Select Scenarios Manage scenarios. 114) Change the Results attribute to collect or recollect. Figure Manage Scenarios dialog 115) Click OK. 116) Click Close when the simulations has finished. View results 117) Right click on the workspace and choose Compare Results. 118) Expand Object statistics Choose From Maps Network Paris Server Paris TCP Connection. 119) Check Congestion Window size (bytes). 120) Select Statistics Stacked in the bottom left roll-down menu. Tommy Svensson 120

121 Figure Compare results dialog 121) Click Show. The graph should resemble the one below. Figure Resluts Graphs The first graph illustrates the NoDrop scenario which has no packet loss. Tommy Svensson 121

122 The second graph illustrates the Tahoe scenario which has 0.5% packet loss. When congestion is indicated by a timeout, cwnd is set to one segment. In other words, slow start is performed. The third graph illustrates the Reno scenario which also has 0.5% packet loss. The congestion window size does not drop to zero as in the Tahoe graph. Fast recovery is performed instead of slow start. The lab is completed. Tommy Svensson 122

123 Laboratory 5 OSPF simulation Objective The purpose of this lab is to demonstrate the behavior of OSPF routing protocol. Overview In this lab we will study the OSPF routing protocol. The objective is to construct a network and configure it with all the necessary parameters for OSPF routing. Using this network we will analyze the behavior of the OSPF routing protocol. Procedure The Open Shortest Path First (OSPF) protocol is an interior gateway protocol (IGP) used for routing in Internet Protocol (IP) networks. As a link state routing protocol, OSPF is more robust against network topology changes than distance vector protocols such as RIP, IGRP, and EIGRP. OSPF can be used to build large scale networks consisting of hundreds or thousands of routers. Open Shortest Path First (OSPF) uses the Dijkstra s algorithm to compute the shortest path to a destination. The algorithm calculates the shortest path to each destination based on the cumulative cost required to reach that destination. The cumulative cost is a function of the cost of the various interfaces needed to be traversed in order to reach that destination. The cost (or the metric) of an interface in OSPF is an indication of the overhead required to send packets across that interface. The cost of an interface is calculated based on the bandwidth -- it is inversely proportional to the bandwidth of that specific interface (i.e., a higher bandwidth indicates a lower cost). For example, the cost of a T1 interface is much higher than the cost of a 100Mbit Ethernet interface because there is more overhead (e.g., time delays) involved in crossing a T1 interface.[5] Characteristic features of OSPF Link State Based Runs directly over IP Interior or border gateway protocol Multiple paths to each destination. Load balancing. Link-attribute based costing. Costing is statically assigned. [6] Tommy Svensson 123

124 Create the network 1. Start OPNET and create a new project. File New and choose Project. 2. Name the project <initials>_ospf and the scenario NoAreas. Click OK. 3. Select Create empty scenario and click next. 4. Select Office and click next. 5. Set X Span to 200 and Y Span to 200. Click next. 6. Do not include any technologies and click next. 7. Review the values and click OK. 8. Open the Object palette and change the palette to routers. Figure 115 Object palette dialog 9. Click OK. 10. Place ten slip8_gtwy s in the workspace as in figure Change the object palette to internet_toolbox. Figure Object palette 12. Connect all the routers using PPP_DS3 link as in figure 117. Tommy Svensson 124

125 13. Rename all the routers as in figure 117. Right click on each router and select Set Name from the pop up menu. Figure Network overview Tommy Svensson 125

126 Configure router interfaces We need to designate the interfaces of all routers that use the OSPF protocol. By default, RIP is used on every router interface. There are three ways to configure router interfaces to use a particular set of routing protocols: Method Characteristics When to Use Protocols IP Routing Configure Routing Protocols menu operation Any number of interfaces can be configured at the same time Overwrites the IP Routing Parameters Interface Information Routing Parameters attribute Multiple routing protocols can be specified. In most cases. IP Routing Parameters Interface Information Routing Protocols IP Dynamic Routing Protocol simulation attribute Only one interface can be configured at a time. Does not modify router attributes Overrides the routing protocols configured on the router interfaces for the duration of the simulation One routing protocol used on all interfaces When this attribute is set to Default, the protocols specified on the router interfaces are used. When one wants to add a protocol to those already designated on a particular interface. You have configured the routing protocols in your network but want to see the effects of running a single protocol throughout the network. The easiest way to designate routing protocols is the Configure Routing Protocols operation from the Protocols IP Routing menu. This operation has the same effect as manually setting the interface routing protocol attributes, but with the added advantage of being able to configure multiple interfaces at the same time. The previous setting on the interface is overwritten each time this operation is used. 1. Open the Protocols IP Routing Configure Routing Protocols menu. Tommy Svensson 126

127 2. Check the OSPF check box. Figure Select the All interfaces radio button. Figure 118. Figure Configure routing protocols dialog 4. Save the project. Tommy Svensson 127

128 A Routing Domain Legend appears in the bottom left corner on the workspace. All links should have a green O attached to it. This indicates that OSPF routing protocol is used over that link. Figure 119. Figure Routing Domain Legend and Link indication Assign addresses to the router interfaces. The Protocols IP Addressing Auto-Assign IP Addresses operation assigns a unique IP address to the connected IP interfaces whose IP address is currently set to autoassigned. This operation does not change the value of manually set IP addresses. 1. Use the Protocols IP Addressing Auto-Assign IP Addresses. The message Assignes 40 IP addresses appear in the status bar. Figure 120. Figure Status bar Tommy Svensson 128

129 Configure routing cost Cost is specified on a per interface basis and is used as the basis for the shortest path route calculation. There are two ways of setting this Cost attribute for each interface. A. Per-interface: The interface information table is located by right clicking on a router and selecting the Edit attributes option. Figure 121. One can manually specify the cost of an interface by editing the value with the desired cost setting. For example, the default value of Auto Calculate can be over-written by any positive integer cost value: When set to Auto Calculate, the formula used to calculate the cost is based on the interface speed and another configurable Re ference _ Bandwith attribute called Reference Bandwidth: Interface _ cost = Interface _ Bandwith Note: The default value for Reference Bandwidth is 1000 Mbps; therefore, it will cost 1,000,000,000/100,000,000 = 10 to traverse a 100Mbps Ethernet interface and it will cost 1,000,000,000/1,544,000 = 647 to cross a T1 serial line interface. The default for Interface Bandwidth is computed dynamically using the data rate of the connected interface. It can be over-written by using the Bandwidth setting in the Protocols IP Routing Configure Interface Metric Information table. Figure Router attributes Tommy Svensson 129

130 B. Globally for all interfaces: If wanted to change the interface cost across all interfaces, then, rather than individually setting them on each interface, one can use the model-wide cost configuration option using the following menu option: Protocols OSPF Configure Interface Cost. This operation will allow for choosing one of the following two cost configuration options: B1) The Reference Bandwidth will be set for all routers. All interfaces will be set with a cost value of Auto Calculate. B2) All interfaces will be set with the specified cost value. The interface/bandwidth settings will be ignored. Figure OSPF Interface Cost Configuration dialog In this lab we use different bandwidths on the links to set different costs. 1. Select the links between: Router A Router B Router B Router D Router D Router C Router C Router A Router B Router C by shift clicking on them. 2. Open the Configure Interface Metric Information dialog. Protocols IP Routing Configure Interface Metric Information. 3. Set the Bandwidth value to 5000 kbps. 4. Select Interfaces across selected links radio button. Click OK. 5. Select the links between: Router B Router E Router E Router G Router I Router F Router F Router D Router E Router F by shift clicking on them. Tommy Svensson 130

131 6. Open the Configure Interface Metric Information dialog. Protocols IP Routing Configure Interface Metric Information. 7. Set the Bandwidth value to kbps. 8. Select Interfaces across selected links radio button. Click OK. 9. Select the links between: Router G Router H Router H Router J Router J Router I Router I Router G Router G Router J by shift clicking on them. 10. Open the Configure Interface Metric Information dialog. Protocols IP Routing Configure Interface Metric Information. 11. Set the Bandwidth value to kbps. 12. Select Interfaces across selected links radio button. Click OK. 13. Save the project. The cost configuration looks as in figure 123: Figure Cost overview Tommy Svensson 131

132 Configure the traffic demands 1. Select both Router B and Router D by shift clicking on them. 2. Open the Create traffic demands menu. Protocols IP Demands Create Traffic Demands 3. Select From Router B radio button. 4. Click Create. 5. Select both Router C and Router J by shift clicking on them. 6. Open the Create traffic demands menu. Protocols IP Demands Create Traffic Demands 7. Select From Router C radio button. 8. Click Create. The paths of the traffic demands are now visible. To hide them select View Demand Objects Hide All. Configure Simulation 1. Open the Configure Discrete Event Simulation dialog. 2. Set duration to 10 minutes. 3. Click OK. 4. Save the project. Duplicate the scenario In the scenario just created all routers belong to the same level of hierarchy, i.e., one area. No load balancing where enforced for any routers. Two new scenarios will be created to implement areas and load balancing. Areas scenario The major addition in OSPF configuration, relative to other protocols, is that the OSPF routing domain can be divided into smaller segments called areas. This reduces memory and computational load on the routers. Each area is numbered and there must always be an area zero, which is the backbone. All other areas attach to the backbone either directly or via virtual links. An area should contain no more than about routers for optimum performance. A router that connects to more than one area is called an Area Border Router (ABR). 1. Duplicate the scenario. Scenarios Duplicate scenario 2. Name the scenario Areas. Partition the network into areas. This is a physical partitioning in the sense that an interface can belong to only one area. The distinct interfaces of the same router may still belong to separate areas. Tommy Svensson 132

133 3. Select the links between: Router A Router B Router B Router D Router D Router C Router C Router A Router B Router C by shift clicking on them. 4. Open the OSPF Area Configuration dialog. Protocols OSPF Configure Areas. 5. Set the value 1 to Area Identifier. 6. Click OK. 7. Select the links between: Router B Router E Router E Router G Router I Router F Router F Router D Router E Router F by shift clicking on them. 8. Open the OSPF Area Configuration dialog. Protocols OSPF Configure Areas. 9. Set the value 0 to Area Identifier. 10. Click OK. 11. Select the links between: Router G Router H Router H Router J Router J Router I Router I Router G Router G Router J by shift clicking on them. 12. Open the OSPF Area Configuration dialog. Protocols OSPF Configure Areas. 13. Set the value 2 to Area Identifier. 14. Click OK. 15. Visualize the areas. Protocols OSPF Visualize Areas 16. Click OK in the pop-up dialog. 17. Save the project. The areas are visualized in different colors. Balanced Scenario Load balancing is a concept that allows a router to take advantage of multiple best paths (routes) to a given destination. If two routes to the same destination have the same cost, the traffic will be distributed half to each. Tommy Svensson 133

134 1. Go back to the NoAreas scenario. Scenarios Switch To Scenario NoAreas. 2. Duplicate the scenario. Scenarios Duplicate scenario 3. Name the scenario Balanced. 4. Select both Router C and Router J by shit clicking on them. 5. Open the Configure Load Balancing Option dialog. Protocols IP Routing Configure Load Balancing Option. 6. Select Packet based in the roll-down menu. 7. Select the Selected Routers radio button. 8. Click OK. 9. Save the project. Figure Configure Load Balancing Option dialog Run the simulation 1. Open the Manage Scenarios dialog. Scenarios Manage Scenarios 2. Click in the Results column on the NoAreas row and click the collect button. 3. Set the scenarios Area and Balanced to collect results. Repeat the previous step. Figure Manage Results dialog 4. Click OK to run the simulation. 5. Click Close when the simulation has finished. Tommy Svensson 134

135 View the results NoAreas scenario 1. Switch to the NoAreas scenario. Scenarios Switch to Scenario NoAreas. 2. Open the Route Report for IP Traffic Flows dialog. Protocols IP Demands Display Routes for Configured Demands 3. Expand Sources Router B Router D. 4. Select Router B Router D. 5. Change the Display attribute to Yes. Figure 126. Figure Route Report for IP Traffic Flows dialog The traffic flow should look like figure 127. Figure 127 NoAres scenario. Router B Router D traffic flow Tommy Svensson 135

136 6. Change the Display attribute for Router B Router D to No. 7. Expand Sources Router C Router J. 8. Select Router C Router J. 9. Change the Display attribute to Yes. Figure 128. Figure Route Report for IP Traffic Flows dialog The traffic flow should look like figure 129. Figure 129 NoAres scenario. Router C Router J traffic flow Tommy Svensson 136

137 Areas scenario 1. Switch to the Areas scenario. Scenarios Switch to Scenario Areas. 2. Open the Route Report for IP Traffic Flows dialog. Protocols IP Demands Display Routes for Configured Demands 3. Expand Sources Router B Router D. 4. Select Router B Router D. 5. Change the Display attribute to Yes. The traffic flow should look like figure 130. Figure Ares scenario. Router B Router D traffic flow Tommy Svensson 137

138 Balanced scenario 1. Switch to the Balanced scenario. Scenarios Switch to Scenario Balanced. 2. Open the Route Report for IP Traffic Flows dialog. Protocols IP Demands Display Routes for Configured Demands 3. Expand Sources Router C Router J. 4. Select Router C Router J. 5. Change the Display attribute to Yes. The traffic flow should look like figure 131. Figure Balanced scenario. Router C Router J traffic flow The lab is completed. Tommy Svensson 138

139 Laboratory 6 Queuing policies Objective The purpose of this lab is to demonstrate the behavior of different queuing disciplines. Overview In this lab we will look at one aspect of the DS (Differentiated Services) architecture which is queue management and traffic shaping. The simulation package OPNET has been used in this study. Based on the DS value, packets may be put in separate queues, and various forwarding policies can be used to favor high priority packets in different ways. The policies that are studied here are: FIFO (First In First Out), PQ (Priority Queuing), WFQ (Weighted Fair Queuing). Procedure Originally, the Internet was designed for data processing applications where delays were relatively unimportant. In most cases a best effort delivery service was adequate, and in case of loss or corruption of data, the TCP protocol would take care of the necessary retransmission and recovery. Nowadays these requirements have been changed due to the growth of multimedia application which are bandwidth hungry and require megabits per second rather than the kilobits per second required for traditional data processing applications. Today s application are more or less sensitive for the delays experienced when transmitting over Internet. It is therefore important to keep track of the delay and delay variation or jitter and insure that they don t grow to big. There is thus a need to support a variety of traffic with different quality of service (QoS). The central issue is how to share available resources in times of congestion. For doing this, diverse mechanisms are needed to differentiate between different types of traffic (priority). Tommy Svensson 139

140 Copy files 1. Copy the model files from the CD-ROM and place them on the hard drive. 2. Edit the Opnet environment file, env_db9.0. On Windows XP it is located in C:\Documents and Settings\<profile>\op_admin 3. Add the path where the files are placed to mod_dirs. Figure Opnet enviroment file Tommy Svensson 140

141 FIFO queuing First-in-first-out (FIFO) is the simplest type of queuing. The incoming packets are placed in a single queue and are served in the order as they where received. This queuing policy requires very little computation and its behavior is very predicable, i.e. packet delay is a direct function of the queue size. There are many undesirable properties related to this queuing policy, due to the simplistic nature. It is impossible to offer different services for different packet classes since all packets are inserted into the same queue. If an incoming flow suddenly becomes bursty, then it is possible for the entire buffer space to be filled by this single flow and other flows will not be serviced until the buffer is emptied. Figure FIFO queue Tommy Svensson 141

142 Create the FIFO network 1. Start OPNET and create a new project. File New and choose Project. 2. Name the project <initials>_queue_ disciplines and the scenario Fifo. Click OK. 3. Click Quit. 4. Open the Object palette. 5. Click the Configure palette button. 6. Clear the palette. Click the Clear button. 7. Choose which node models to include. Click the Node models button. 8. Include ta_fifo node model. Click OK. Figure Include node models dialog 9. Click SAVE in the Configure Palette dialog. Use the default filename. 10. Click OK to close the Configure Palette dialog. 11. Click and drag ta_fifo node model from the Object palette to the workspace. 12. Right click on node model in the workspace and choose set name. Set the name to fifo_infinite_buffer. 13. Double click on the fifo node model. The node model that appears should resemble the one in figure 135. The model has three packet sources which generates packets to the fifo_queue. The packets in the queue are served by fifo (First In First Out) queue discipline and sent to the sink, where they are destroyed. Tommy Svensson 142

143 Figure Fifo queue node model overview 14. Right click on source_1 and choose Edit attributes 15. Verify the values with figure Click OK to close the attribute dialog. Figure Source_1 attributes 17. Repeat the same procedure with source_2 and source_3. Tommy Svensson 143

144 18. Right click on fifo_queue and choose Edit attributes 19. Right click on subqueue attribute and choose Promote to higher level. 20. Click OK to close the attribute dialog. Figure fifo_queue attributes 21. Close the node model window. Save the changes. 22. Right click on the fifo node and choose Edit attributes 23. Expand fifo_queue.subqueue row Set both bit capacity and pk capacity to infinity. Figure fifo node subqueue attributes (infinite buffer) 25. Click OK. Tommy Svensson 144

145 Duplicate scenario 26. Duplicate the scenario. Choose scenarios duplicate Scenario (Figure 139) or use shortcut key Ctrl + Shift + D. Figure Duplicate scenario menu item 27. Enter the name fifo_finite_buffer. 28. Right click on the fifo node and choose Edit attributes 29. Expand fifo_queue.subqueue row Set bit capacity to infinity and pk capacity to 20. Figure Fifo node subqueue attributes (finite buffer) 31. Click OK. Tommy Svensson 145

146 Collect statistics 32. Right click on the fifo node. 33. Select Choose individual statistics. 34. Expand Module statistics fifo_queue queue. 35. Check overflow, queue size and queue delay statistics. Figure Choose individual statistic dialog 36. Right click on the overflow statistic and choose Change collection mode. Figure Change Collection mode 37. Check the Advanced checkbox. 38. Change Collection mode to all values. Figure Statistics capture mode Tommy Svensson 146

147 39. Click OK. 40. Repeat the same procedure for Queue size (packet) and Queue delay statistics. 41. Click OK to close the dialog. 42. Switch to scenario fifo_infinite_buffer. Scenarios Switch to scenario fifo_infinite_buffer. 43. Choose the same statistics and capture mode as in fifo_finite_buffer scenario. Run the simulation 44. From the main menu, select Scenarios Manage scenarios. 45. Choose collect or recollect in the results column. 46. Set Sim duration to 1 hour. Figure Manage scenarios dialog 47. Click OK and wait for the simulation to finish. 48. Close the simulation sequence dialog. Tommy Svensson 147

148 View the results 49. Right click in the workspace and choose Compare results. 50. Expand Object statistics fifo fifo_queue queue. 51. Check queue size (packets). 52. Choose statistics stacked in the pull down menu. Figure Click Show. Figure Compare results dialog 54. Repeat the same procedure for queue delay statistics. 55. Check overflow statistic. 56. Choose differentiator in the middle pull down menu. Figure Choose select scenarios in the right pull down menu. Figure Click Show. 59. Uncheck fifo_infinite_buffer and check fifo_finite_buffer and click OK. Figure Compare results dialog Tommy Svensson 148

149 The results should resemble the graphs below. Figure Fifo Queue size (packet) for infinite and finite buffers Tommy Svensson 149

150 Figure Fifo queue delay for infinite and finite buffers Tommy Svensson 150

151 Figure Packet overflows for finite buffer Tommy Svensson 151

152 Priority queuing A simple way of offering different services to different classes of packets is Priority Queuing. Its operation involves classifying each incoming packet into different priorities and placing them into separate queues accordingly. The packets that have the highest priority are transmitted on the output port before the packets with lower priority. Even though this queuing policy is a good way of providing differentiated service, it also has some shortcomings, like large continuous flow of high priority traffic into the queue, equals excessive delay, and perhaps even service starvation for lower priority packets. Further, in our case we make use of both a non-preemptive priority network and a preemptive priority network. The difference between a so-called non-preemptive priority queuing discipline and a preemptive priority queuing discipline is that the transmission of a packet in a non-preemptive queuing discipline is not interrupted once it has begun. Figure Priority queuing Create the Non-preemptive priority network, infinite buffer 1. Open a new project. File New 2. Name the project <initials>_priority_queue and the scenario non_preemptive. 3. Click OK. 4. Click Quit button to close the wizard. 5. Open the Object palette. 6. Click the Configure palette button. 7. Clear the palette. Click the Clear button. 8. Choose which node models to include. Click the Node models button. 9. Include jsd_prio and jsd_prmpt_res node model and click OK. Figure 151. Tommy Svensson 152

153 Figure Include node models dialog 10. Click Save and use the default filename. 11. Click OK to close the dialog. 12. Click and drag jsd_prio node model from the Object palette to the workspace. 13. Change the name on the node to nonpreemptive. Right click set name. 14. Double click on the node. 15. Right click on source_1 and choose Edit attributes 16. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 18. Right click on source_2 and choose Edit attributes 19. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 21. Right click on source_3 and choose Edit attributes 22. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 24. Right click on nonpreemptive_priority_queue and choose Edit attributes Tommy Svensson 153

154 25. Set: Processing_rate to Subqueue rows to 3 Subqueue row 0 bit capacity to infinity Subqueue row 0 pk capacity to infinity Subqueue row 1 bit capacity to infinity Subqueue row 1 pk capacity to infinity Subqueue row 2 bit capacity to infinity Subqueue row 2 pk capacity to infinity 26. Click OK. 27. Close the node model and save the changes. Tommy Svensson 154

155 28. Right click on the node and select Choose Individual Statistics. 29. Check the statistics as in figure Change Statistic collection mode to All values. Right click on the statistic and choose Change collection mode. 31. Click OK to close the Choose Result dialog. Figure Choose individual statistics for nonpreemtive priority queue model Tommy Svensson 155

156 Create the Preemptive priority network, infinite buffer 32. Duplicate the scenario and name it preemptive. Scenarios Duplicate scenario. 33. Select the node on the workspace and delete it. 34. Click and drag jsd_prmpt_res node model from the Object palette to the workspace. 35. Change the name on the node to preemptive. Right click set name. 36. Double click on the node. 37. Right click on source_1 and choose Edit attributes 38. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 40. Right click on source_2 and choose Edit attributes 41. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 43. Right click on source_3 and choose Edit attributes 44. Set: ia_time to 1 instruction_range to 9600 priority_range to Click OK. 46. Right click on preemptive_priority_queue and choose Edit attributes 47. Set: Processing_rate to Subqueue rows to 3 Subqueue row 0 bit capacity to infinity Subqueue row 0 pk capacity to infinity Subqueue row 1 bit capacity to infinity Subqueue row 1 pk capacity to infinity Subqueue row 2 bit capacity to infinity Subqueue row 2 pk capacity to infinity 48. Click OK. 49. Close the node model and save the changes. 50. Right click and select Choose individual statistics. 51. Choose the same statistics as in nonpreemptive scenario. Don t forget to change statistic collection mode to all values. Tommy Svensson 156

157 Run the infinite buffer simulation 52. Choose Scenarios Manage scenarios from the main menu. 53. Change the value in results column to collect. 54. Change Sim Duration to 1 hour. 55. Click OK and wait for the simulation to finish. 56. Close the simulation dialog. Tommy Svensson 157

158 View the infinite buffer simulation results 57. Open Analysis Configuration tool. File New Analysis Configuration. Figure 153. Figure Open a new Analysis configuration tool window 58. Click Create a graph of a statistic button. 59. Expand File statistics <initials>_priority_queue-non_preemptive Object Statistics nonpreemptive nonpreemptive_priority_queue. Figure 154. Figure Choose File Statistics in Analysis Configuration tool 60. Choose the statistics as in Figure 155. Tommy Svensson 158

159 Figure 155 Chosen statistics for nonpreemptive priority queue 61. Choose Statistics Overlaid and time_average in the pull down menus at the bottom. Figure Graph layout setting 62. Click Show. Tommy Svensson 159

160 The Graph should resemble Figure 157. Figure 157 -Queue sizes for Nonpreemptive priority queues Tommy Svensson 160

161 63. Expand File statistics <initials>_priority_queue-preemptive Object Statistics preemptive preemptive_priority_queue. Figure 158. Figure Choose File Statistics in Analysis Configuration tool 64. Choose the statistics as in Figure 159. Figure Chosen statistics for preemptive priority queue 65. Choose Statistics Overlaid and time_average in the pull down menus at the bottom. Figure Graph layout setting 66. Click Show. Tommy Svensson 161

162 The Graph should resemble Figure 161. Figure Queue sizes for preemptive priority queues Tommy Svensson 162

163 Create the Preemptive priority network, Finite buffer 67. Enter the preemptive node. Double click on the node. 68. Right click on the preemptive_priority_queue and choose Edit attributes 69. Change the subqueues packet capacity to 3. Figure 162. Figure Finite buffer queue, packet capacity setting 70. Click OK. 71. Close the node model and save the changes. 72. Right click on the preemptive node and select Choose Individual Statistics. 73. Expand Module Statistics preemptive_priority_queue.subqueue[0] queue. 74. Check overflows statistic. 75. Right click on the overflows statistics and choose Change Collection Mode. 76. Set Capture mode to All values. 77. Repeat the same procedure on subqueue[1] and subqueue[2]. Create the Preemptive priority network, Finite buffer 78. Change the scenario to non_preemptive. Scenarios Switch To Scenario non_preemptive. 79. Enter the nonpreemptive node. Double click on the node. 80. Right click on the nonpreemptive_priority_queue and choose Edit attributes 81. Change the subqueues packet capacity to Click OK. 83. Close the node model and save the changes. 84. Right click on the preemptive node and select Choose Individual Statistics. 85. Expand Module Statistics nonpreemptive_priority_queue.subqueue[0] queue. 86. Check overflows statistic. 87. Right click on the overflows statistics and choose Change Collection Mode. 88. Set Capture mode to All values. 89. Repeat the same procedure on subqueue[1] and subqueue[2]. Tommy Svensson 163

164 Run the finite buffer simulation 90. Choose Scenarios Manage scenarios from the main menu. 91. Change the value in results column to collect. 92. Change Sim Duration to 1 hour. 93. Click OK and wait for the simulation to finish. 94. Close the simulation dialog View the finite buffer simulation results 95. Open Analysis Configuration tool. File New Analysis Configuration. Figure 163 Figure Open a new Analysis configuration tool window 96. Click Create a graph of a statistic button. 97. Expand File statistics <initials>_priority_queue-non_preemptive Object Statistics nonpreemptive nonpreemptive_priority_queue. Figure 64. Figure Choose File Statistics in Analysis Configuration tool Tommy Svensson 164

165 98. Choose the statistics as in Figure 165. Figure Selected statistics for nonpreemptive priority queue 99. Choose Statistics Overlaid and differentiator in the pull down menus at the bottom. Figure Graph layout setting 100. Click Show. Tommy Svensson 165

166 The graphs should resemble Figure 167. Figure Packet loss rate for nonpreemptive priority queue Tommy Svensson 166

167 101. Expand File statistics <initials>_priority_queue-preemptive Object Statistics preemptive preemptive_priority_queue. Figure 168. Figure Choose File Statistics in Analysis Configuration tool 102. Choose the statistics as in Figure 169. Figure Selected statistics for preemptive priority queue 103. Choose Statistics Overlaid and differentiator in the pull down menus at the bottom. Figure Graph layout setting 104. Click Show. Tommy Svensson 167

168 The graph should resemble Figure 171. Figure Packet loss rate for preemptive priority queue Tommy Svensson 168

169 Weighted Fair Queuing Processor Sharing (PS) is a class of queueing mechanism with the purpose of allowing fair access for each incoming flow and to prevent a bursty flow from consuming all of the output bandwidth. PS contains a queue for each distinct flow and packets from each flow are inserted into its respective queue. The system then services each queue one packet at a time in a round robin fashion. Weighted Fair Queuing (WFQ) is a variation of Processor Sharing (PS) in that it supports flows with different bandwidth requirements. It does this by assigning each queue with different weights that corresponds to the proportion of the allocated output bandwidth. In WFQ, each incoming packet is time stamped with a finish time in addition to being placed into its corresponding flow queue. Unlike Processor Sharing, selection of which packet to be serviced is now based on this time stamp on each packet. Further packets are serviced by examining their finish times. The ones with earlier finish times are transmitted before the ones with later finish times. It is possible for a later packet to have a finish time stamp that is smaller than an earlier packet. Figure WFQ scheduling Create the Weighted Fair Queuing infinite buffer network 1. Start OPNET and create a new project. File New and choose Project. 2. Name the project <initials>_wfq_discipline and the scenario infinite. Click OK. 3. Click Quit. 4. Open the Object palette. 5. Click the Configure palette button. 6. Clear the palette. Click the Clear button. 7. Choose which node models to include. Click the Node models button. 8. Include ta_wfq_node_model. Figure 173. Tommy Svensson 169

170 Figure Include WFQ node model 9. Click OK. 10. Click Save and use the default filename. 11. Click OK. 12. Click on ta_wfq_node_model in the object palette and drag it into the workspace. 13. Right click on the node and choose Set name. 14. Set the name wfq and click OK. 15. Enter the wfq node. Double click on it. 16. Right click on source_1 and choose Edit Attributes 17. Set ia_time to 1 instruction_range to 1 priority_range to Click OK. 19. Right click on source_2 and choose Edit Attributes 20. Set ia_time to 1 instruction_range to 1 priority_range to Click OK. 22. Right click on source_3 and choose Edit Attributes 23. Set ia_time to 1 instruction_range to 9600 priority_range to Click OK. 25. Right click on wfq_queue and choose Edit Attributes 26. Set processing_rate to queue_weight0 to 50 queue_weight1 to 30 queue_weight2 to Set the rows attribute value to Set Row 0 Bit capacity to infinity. Tommy Svensson 170

171 Row 0 Pk capacity to infinity. Row 1 Bit capacity to infinity. Row 1 Pk capacity to infinity. Row 2 Bit capacity to infinity. Row 2 Pk capacity to infinity. Figure wfq processor settings 29. Close the node model and save the changes. Tommy Svensson 171

172 30. Right click the wfq node and select Choose Individual Statistics. 31. Choose the statistics as in Figure Right click subqueue[0] queue queue size (packets) and choose Change collection mode. 33. Change Capture mode to all values. 34. Click OK to close capture mode dialog. 35. Click OK to close Choose Results dialog. Figure wfq statistics settings Tommy Svensson 172

173 Run the Weighted Fair Queuing infinite buffer simulation 36. Open Configure simulation dialog. Click the Run simulation button. 37. Set duration to 1 day Seed to any arbitrary integer (i.e. 5416) 38. Click Run and wait for the simulation to finish. View the Weighted Fair Queuing infinite buffer results. 39. Right click on the workspace and choose View Results. 40. Expand Object statistics wfq wfq_queue. 41. Choose the statistics as in Figure Set Statistics overlaid and time_average in the pull down menus at the bottom. Figure 176. Figure WFQ graph results setting 43. Click Show. Tommy Svensson 173

174 The Graph should resemble Figure 177. Figure 177 WFQ queue length, infinite buffer Tommy Svensson 174

175 Create the Weighted Fair Queuing finite buffer network 44. Close the View result dialog. 45. Enter the wfq node. Double click on it. 46. Right click on wfq_queue and choose Edit Attributes 47. Change subqueue row 0 pk capacity (pks) to 3 subqueue row 1 pk capacity (pks) to 3 subqueue row 2 pk capacity (pks) to 3 (figure 178) Figure wfq finite queue settings 48. Click OK. 49. Close the node model and save the changes. 50. Right click the wfq node and select Choose Individual Statistics. 51. Include Module statistics wfq_queue wfq_queue.subqueue[0] overflows and change the colletion mode to all values. 52. Include Module statistics wfq_queue wfq_queue.subqueue[1] overflows and change the colletion mode to all values. 53. Include Module statistics wfq_queue wfq_queue.subqueue[2] overflows and change the colletion mode to all values. 54. Click OK. Tommy Svensson 175

176 Run the Weighted Fair Queuing finite buffer simulation 55. Open Configure simulation dialog. Click the Run simulation button. 56. Set duration to 1 day Seed to any arbitrary integer (i.e. 2569) 57. Click Run and wait for the simulation to finish. View the Weighted Fair Queuing finite buffer results. 58. Right click on the workspace and choose View Results. 59. Expand Object statistics wfq wfq_queue. 60. Choose the statistics as in Figure Set Statistics overlaid and differentiator in the pull down menus at the bottom. Figure 179. Figure WFQ packet loss graph results setting 62. Click Show. Tommy Svensson 176

177 The Graph should resemble Figure 180. Figure 180 Packet loss for WFQ finite buffer Tommy Svensson 177

178 Laboratory 7 Self-Similar Objective The purpose of this lab is to understand self-similarity on physical grounds in a realistic network environment. This understanding is important when developing efficient and integrated network frameworks within which end-to-end QoS guarantees are fully supported. Overview Self-similar traffic has been shown to exist in networks and it seems to be a ubiquitous phenomenon that is independent of technology, protocol and environment. In this laboratory moment we will study and compare the performance of an Ethernet segment run with heavy-tail traffic and with exponential traffic. The performance parameters considered here are link utilization and e2e delay. The laboratory moments are as follows: Creation of the network model Running the simulation with different ON-OFF models Plotting and comparing the results Tommy Svensson 178

179 Procedure A self-similar phenomenon represents a process displaying structural similarities across a wide range of scales of a specific dimension. In other words, the reference structure is repeating itself over a wide range of scales and the (main) statistics of the process do not change. However, these properties do not hold indefinitely for real phenomena and at some point, this structure breaks down. Self-similarity can therefore be associated with fractals which are objects with unchanged appearances over different scales. A stochastic process is called fractal when a number of relevant statistics exhibit scaling with related scaling exponents. Since scaling leads mathematically to power-law relationships in the scaled quantities the conclusion is therefore that the traffic shows fractal properties when several estimated statistics exhibit power-law behaviour over a wide range of time scales [8]. A continuous-time stochastic process X(t) is considered to be statistical self-similar with parameter H(0.5 H 1.0) if, for any real positive a, the process a -H x(at) has the same statistical properties as x(t). This relationship may be expressed by the following three conditions: E[x(t)] = E[x(at)] / a H Var[x(t)] = Var[x(at)] / a 2H R x (t,s) = R x (at,as) /a 2H mean variance autocorrelation The parameter H is known as the Hurst parameter, or the self-similarity meter, and it is a key measure of self-similarity. More precisely H is a measure of the persistence of a statistical phenomenon and it is the measure of the length of the long-range dependence of a stochastic process. A value of H=0.5 indicates the absence of long-range dependence. The closer H is to 1 the greater the degree of persistence or long-range dependence. Tommy Svensson 179

180 Create the self similar network model 1. Start OPNET and create a new project. File New and choose Project. 2. Name the project <initials>_selfsimilar and the scenario self_similar_vs_exponential. Click OK. 3. Choose Create Empty Scenario. Click Next. 4. Choose Office. Click Next. 5. Set: Size to Meters X Span to 100 Y Span to 100 Click Next. 6. Include RPG. Click Next. Figure Include technologies dialog 7. Review the chosen values. Click OK. 8. Open the Object palette if it s not already open. 9. Place two Ethernet_rpg_station nodes in the workspace. Figure 182. Figure ethernet_rpg_station icon 10. Name the first node model PowOn-PowOff source and the second one PowOn- PowOff receiver. Right click and choose Set Name. 11. Change the Object palette to ethernet_advanced. Figure 183. Figure Choused Object palette Tommy Svensson 180

181 12. Place two ethernet_stn_advanced nodes in the workspace. Figure 184. Figure ethernet_stn_advanced icon 13. Name the first node model Exponential source and the second one Exponential_receiver. Right click and choose Set Name. 14. Place two ethernet16_hub_adv in the workspace. Figure ethernet16_hub_adv icon 15. Name the first hub PowON-PowOFF Hub and the second hub Exponential Hub. Right click and choose Set Name. 16. Use 10BaseT_int link model to the following connections. PowOn-PowOff_source PowON-PowOFF Hub PowON-PowOFF Hub PowOn-PowOff receiver Exponential source Exponential Hub Exponential Hub Exponential_receiver Figure BaseT_int icon Tommy Svensson 181

182 The network model should resemble figure 187. Figure 187 Network model overview 17. Right click on PowOn-PowOff source and choose Edit Attributes Set the attributes as in Figure 188. Tommy Svensson 182

183 Figure PowOn-PowOff Source node attributes 19. Click OK to close the attributes dialog. 20. Select the PowOn-PowOff network and press <CTRL>+C 21. Paste two copies on the workspace. Press <CTRL>+V to place a copy next to the original. 22. Rename the nodes. PowOn-PowOff source_0 to ExpOn-PowOff source PowOn-PowOff Hub_0 to ExpOn-PowOff Hub PowOn-PowOff Receiver_1 to ExpOn-PowOff Receiver PowOn-PowOff source_1 to PowOn-ExpOff source PowOn-PowOff Hub_1 to PowOn-ExpOff Hub PowOn-PowOff Receiver_1 to PowOn-ExpOff Receiver Tommy Svensson 183

184 23. Right click on ExpOn-PowOff source and choose Edit Attributes Set the attributes as in Figure 189. Figure ExpOn-PowOff source node attributes 25. Click OK to close the dialog. Tommy Svensson 184

185 26. Right click on PowOn-ExpOff source and choose Edit Attributes Set the attributes as in Figure 190. Figure PowOn-ExpOff source node attributes 28. Click OK to close the dialog. Tommy Svensson 185

186 29. Right click on PowOn-ExpOff source and choose Edit Attributes Set the attributes as in Figure 191. Figure ExpOn-PowOff receiver node attributes 31. Click OK to close the dialog. 32. Right click on PowOn-ExpOff source and choose Edit Attributes Set the attributes as in Figure 192. Figure PowOn-ExpOff receiver node attributes 34. Click OK to close the dialog. Tommy Svensson 186

187 35. Right click on PowOn-PowOff source and choose Edit Attributes Set the attributes as in Figure 193. Figure PowOn-PowOff receiver node attributes 37. Click OK to close the dialog. 38. Right click on Exponential source and choose Edit attributes 39. Set the attributes as in Figure 194. Figure Exponential source node attributes 40. Click OK to close the dialog. Tommy Svensson 187

188 41. Right click on Exponential receiver and choose Edit attributes 42. Set the attributes as in Figure 195. Figure Exponential reveiver node attributes 43. Click OK to close the dialog. The final network should resemble figure 196. Figure Network overview Tommy Svensson 188

189 44. Right click on the workspace and choose Select Individual Statistics. 45. Expand Node statistics Ethernet. 46. Choose Delay (sec) and Utilization statistics. Figure Choused statistics 47. Click OK. Tommy Svensson 189

190 Run the simulation 63. Open Configure simulation dialog. Click the Run simulation button. 64. In the Common tab, Set duration to 100 seconds Seed to any arbitrary integer (i.e. 5416) 65. In the Global Attributes tab, Set Eth Hub Optimization to Enabled RPG Flow Info File to Not Used RPG Start Time to In the Environment Files, Set Optimize_simulation status to included 67. Click Run and wait for the simulation to finish. 68. Close the simulation dialog. Tommy Svensson 190

191 View the results 48. Right click on the workspace and choose View results. 49. Choose the delay statistics as in figure 198. Figure Choose delay statistics Tommy Svensson 191

192 The results should resemble figure 199. Figure Delay results Tommy Svensson 192

193 50. Choose the throughput statistics as in figure 200. Figure 200 Choose throughput statistic Tommy Svensson 193

194 The results should resemble figure 201. Figure Throughput graph Tommy Svensson 194

LAN Modeling. Overview

LAN Modeling. Overview LAN Modeling Overview This lesson focuses on the use of LAN models and background link utilization. You will learn to Configure the object palette with the models you need Set up application and profile

More information

This document presents the basics of OPNET Modeler. The content of this document is mainly transcript from the OPNET documentation [www.opnet.com].

This document presents the basics of OPNET Modeler. The content of this document is mainly transcript from the OPNET documentation [www.opnet.com]. Instituto Superior de Engenharia do Porto (ISEP) Departamento de Engenharia Informática (DEI) Mestrado em Engenharia Informática (MEI) Área: Arquitectura, Sistemas e Redes Sistemas Móveis (SIMOV) Paulo

More information

Order of Packet Transmission and Dropping

Order of Packet Transmission and Dropping Laboratory 9 Queuing Disciplines Order of Packet Transmission and Dropping Objective The objective of this lab is to examine the effect of different queuing disciplines on packet delivery and delay for

More information

SIMULATION FRAMEWORK MODELING

SIMULATION FRAMEWORK MODELING CHAPTER 5 SIMULATION FRAMEWORK MODELING 5.1 INTRODUCTION This chapter starts with the design and development of the universal mobile communication system network and implementation of the TCP congestion

More information

Order of Packet Transmission and Dropping

Order of Packet Transmission and Dropping LAB 11 Queuing Disciplines Order of Packet Transmission and Dropping OBJECTIVES The objective of this lab is to examine the effect of various queuing disciplines on packet delivery and delay for different

More information

Switched LANs. A Set of Local Area Networks Interconnected by Switches

Switched LANs. A Set of Local Area Networks Interconnected by Switches Laboratory 3 Switched LANs A Set of Local Area Networks Interconnected by Switches Objective This lab is designed to demonstrate the implementation of switched local area networks. The simulation in this

More information

Switched LANs A Set of Local Area Networks Interconnected by Switches

Switched LANs A Set of Local Area Networks Interconnected by Switches Switched LANs A Set of Local Area Networks Interconnected by Switches Objective This lab is designed to demonstrate the implementation of switched local area networks. The simulation in this lab will help

More information

Queuing Disciplines. Order of Packet Transmission and Dropping. Laboratory. Objective. Overview

Queuing Disciplines. Order of Packet Transmission and Dropping. Laboratory. Objective. Overview Laboratory 2 Queuing Disciplines Order of Packet Transmission and Dropping Objective The objective of this lab is to examine the effect of different queuing disciplines on packet delivery and delay for

More information

Network Design. Planning a Network with Different Users, Hosts, and Services. Laboratory. Objective. Overview

Network Design. Planning a Network with Different Users, Hosts, and Services. Laboratory. Objective. Overview Laboratory 4 Network Design Planning a Network with Different Users, Hosts, and Services Objective The objective of this lab is to demonstrate the basics of designing a network, taking into consideration

More information

Ethernet. A Direct Link Network with Media Access Control. Laboratory 1. Objective. Overview

Ethernet. A Direct Link Network with Media Access Control. Laboratory 1. Objective. Overview Laboratory 1 Ethernet A Direct Link Network with Media Access Control Objective This lab is designed to demonstrate the operation of the Ethernet network. The simulation in this lab will help you examine

More information

IT Guru Academic Edition does not work correctly with number representations different from English.

IT Guru Academic Edition does not work correctly with number representations different from English. PGRI PLANEAMENTO E GESTÃO DE REDES INFORMÁTICAS LAB ASSIGNMENT 1 DATE: 2009.10.19 OVERVIEW The purpose of this lab is to introduce the main concepts involved in modeling Local Area Networks (LAN) based

More information

Security Lab 1 Firewall Performance

Security Lab 1 Firewall Performance Security Lab 1 Firewall Performance This lab has been partially based on OPNET Lab Manual To Accompany Data and Computer Communications, by Kevin Brown and Leann Christianson, Prentice Hall, 2004. Objective

More information

This tutorial teaches you the basics of using Modeler. If you are new to Modeler, this short introduction will help get you started.

This tutorial teaches you the basics of using Modeler. If you are new to Modeler, this short introduction will help get you started. Introduction Overview Welcome to Modeler! This tutorial teaches you the basics of using Modeler. If you are new to Modeler, this short introduction will help get you started. If you are performing this

More information

Security Labs in OPNET IT Guru

Security Labs in OPNET IT Guru Security Labs in OPNET IT Guru Universitat Ramon Llull Barcelona 2004 Security Labs in OPNET IT Guru Authors: Cesc Canet Juan Agustín Zaballos Translation from Catalan: Cesc Canet -I- Overview This project

More information

Objective To examine the throughput of a TCP connection as the flow control window size is varied.

Objective To examine the throughput of a TCP connection as the flow control window size is varied. Lab 7 TCP Throughput Overview TCP uses a sliding window mechanism to provide flow control. The destination advertises how much space it has available in its buffers, and the source restricts its transmissions

More information

Computer Network. The Practical User Guide for. Simulation. Adarshpal S. Hnatyshin. Vasil Y. CRC Press. Taylor Si Francis Croup

Computer Network. The Practical User Guide for. Simulation. Adarshpal S. Hnatyshin. Vasil Y. CRC Press. Taylor Si Francis Croup The Practical OPNET@ User Guide for Computer Network Simulation Adarshpal S. Sethi Vasil Y. Hnatyshin CRC Press Taylor Si Francis Croup Boca Raton London New York CRC Press is an imprint of the Taylor

More information

Introduction to Modeler

Introduction to Modeler Table of Contents Lab: Using The Project Editor...2 Lab: Building a First Network...11 Lab: Using Other Editors...28 Extra Credit Lab: Discrete Event Simulation Studies...32 Lab: Node Modeling...39 Lab:

More information

Lab 1: Improving performance by LAN Hardware Upgrade

Lab 1: Improving performance by LAN Hardware Upgrade Lab 1: Improving performance by LAN Hardware Upgrade Objective In this lab, OPNET s IT Guru Academic Edition advanced modeling software will be used to study performance improvements in LAN obtained by

More information

Objective To examine the change in throughput in a local area network when upgrading from a hub to a switch.

Objective To examine the change in throughput in a local area network when upgrading from a hub to a switch. Lab 2 Switches versus Hubs Overview Ethernet hubs work at the physical layer, simply repeating any frames they receive on one port onto all other ports. For this reason, they are also called multiport

More information

Shared Ethernet Networks

Shared Ethernet Networks Lab 1 Shared Ethernet Networks Overview In a shared Ethernet network, end systems are typically connected together using a hub. The hub retransmits any incoming frames on all outgoing lines creating a

More information

Lab 3: Performance Analysis of ALOHA

Lab 3: Performance Analysis of ALOHA Lab 3: Performance Analysis of ALOHA ALOHA is one of the basic random access methods in mobile data networks. It is based on mobile terminals sending their packets without any coordination between them.

More information

OPNET Editors and Features

OPNET Editors and Features OPNET Steven Gordon Sirindhorn International Institute of Technology Thammasat University June 2010 Contents OPNET Menus Nodes and Links Communication Running Multiple OPNET Commonly used editors: 1. Project

More information

Advanced Communication Lab OPNET Tutorial

Advanced Communication Lab OPNET Tutorial Advanced Communication Lab OPNET Tutorial SS 2013 Authors: Mohammad M. Siddique, Andreas J. Könsgen 1 1. Log on to the computer. 2. Open the OPNET program by clicking on the respective icon. 3. After the

More information

ECEN 5032 Data Networks Medium Access Control Sublayer

ECEN 5032 Data Networks Medium Access Control Sublayer ECEN 5032 Data Networks Medium Access Control Sublayer Peter Mathys mathys@colorado.edu University of Colorado, Boulder c 1996 2005, P. Mathys p.1/35 Overview (Sub)networks can be divided into two categories:

More information

OVERVIEW WARNING! DATE: INFORMÁTICAS LAB ASSIGNMENT 3

OVERVIEW WARNING! DATE: INFORMÁTICAS LAB ASSIGNMENT 3 PGRI PLANEAMENTO E GESTÃO DE REDES INFORMÁTICAS LAB ASSIGNMENT 3 DATE: 2010.11 OVERVIEW The Internet can be used to transmit data from a variety of applications across an infrastructure shared by millions

More information

Chapter 4 NETWORK HARDWARE

Chapter 4 NETWORK HARDWARE Chapter 4 NETWORK HARDWARE 1 Network Devices As Organizations grow, so do their networks Growth in number of users Geographical Growth Network Devices : Are products used to expand or connect networks.

More information

Using OPNET to Enhance Student Learning in a Data Communications

Using OPNET to Enhance Student Learning in a Data Communications Using OPNET to Enhance Student Learning in a Data Communications Course Michael W Dixon Murdoch University, Perth, Australia m.dixon@murdoch.edu.au Terry W Koziniec Murdoch University, Perth, Australia

More information

Advanced Communication Lab OPNET Tutorial

Advanced Communication Lab OPNET Tutorial Advanced Communication Lab OPNET Tutorial SS 2014 Authors: Mohammad M. Siddique, Andreas J. Könsgen 1 1. Log on to the computer. 2. Open the OPNET program by clicking on the respective icon. 3. After the

More information

Module 1. Introduction. Version 2, CSE IIT, Kharagpur

Module 1. Introduction. Version 2, CSE IIT, Kharagpur Module 1 Introduction Version 2, CSE IIT, Kharagpur Introduction In this module we shall highlight some of the basic aspects of computer networks in two lessons. In lesson 1.1 we shall start with the historical

More information

RSVP: Resource Reservation Protocol

RSVP: Resource Reservation Protocol LAB 12 RSVP: Resource Reservation Protocol Providing QoS by Reserving Resources in the Network OBJECTIVES The objective of this lab is to study the Resource Reservation Protocol (RSVP) as part of the integrated

More information

COMPUTER NETWORKS - Local area networks

COMPUTER NETWORKS - Local area networks Local area networks Telecommunication Networks Group firstname.lastname@polito.it http://www.telematica.polito.it/ COMPUTER NETWORKS LANs - 1 Copyright Quest opera è protetta dalla licenza Creative Commons

More information

Local area networks. Copyright

Local area networks. Copyright Local area networks Telecommunication Networks Group firstname.lastname@polito.it http://www.telematica.polito.it/ COMPUTER NETWORKS LANs - 1 Copyright Quest opera è protetta dalla licenza Creative Commons

More information

Frame Relay Network Performance

Frame Relay Network Performance Lab 4 Frame Relay Network Performance Overview Frame Relay is a connection-oriented, unreliable technology based on virtual circuits. A virtual circuit must be set up between a source and destination before

More information

IT INFRASTRUCTURE PROJECT PHASE I INSTRUCTIONS

IT INFRASTRUCTURE PROJECT PHASE I INSTRUCTIONS Project Overview IT INFRASTRUCTURE PROJECT PHASE I INSTRUCTIONS This project along with the Phase II IT Infrastructure Project will help you understand how a network administrator improves network performance

More information

2. Modelling of telecommunication systems (part 1)

2. Modelling of telecommunication systems (part 1) 2. Modelling of telecommunication systems (part ) lect02.ppt S-38.45 - Introduction to Teletraffic Theory - Fall 999 2. Modelling of telecommunication systems (part ) Contents Telecommunication networks

More information

What is the fundamental purpose of a communication system? Discuss the communication model s elements.

What is the fundamental purpose of a communication system? Discuss the communication model s elements. What is the fundamental purpose of a communication system? The fundamental purpose of a communication system is the exchange of data between two parties. Discuss the communication model s elements. The

More information

This tutorial shows how to use ACE to Identify the true causes of poor response time Document the problems that are found

This tutorial shows how to use ACE to Identify the true causes of poor response time Document the problems that are found FTP Application Overview This tutorial shows how to use ACE to Identify the true causes of poor response time Document the problems that are found The screen images in this tutorial were captured while

More information

LAB 1: Evaluating Internet Connection Choices for a Small Home PC Network

LAB 1: Evaluating Internet Connection Choices for a Small Home PC Network LAB 1: Evaluating Internet Connection Choices for a Small Home PC Network This lab has been originally designed as supplemental material for Prof. Panko s textbook Business Data Networks and Telecommunications.

More information

An Approach for Enhanced Performance of Packet Transmission over Packet Switched Network

An Approach for Enhanced Performance of Packet Transmission over Packet Switched Network ISSN (e): 2250 3005 Volume, 06 Issue, 04 April 2016 International Journal of Computational Engineering Research (IJCER) An Approach for Enhanced Performance of Packet Transmission over Packet Switched

More information

To start using Opnet modeller, select the program icon from the programs menu.

To start using Opnet modeller, select the program icon from the programs menu. Lab 1, Getting Started with Opnet Modeler Creating a new Project To start using Opnet modeller, select the program icon from the programs menu. - The Opnet modeller program icon. Once the program has initialised

More information

General comments on candidates' performance

General comments on candidates' performance BCS THE CHARTERED INSTITUTE FOR IT BCS Higher Education Qualifications BCS Level 5 Diploma in IT April 2018 Sitting EXAMINERS' REPORT Computer Networks General comments on candidates' performance For the

More information

Network Simulation with OPNET

Network Simulation with OPNET CS 521 PROJECT 2 Network Simulation with OPNET Submitted by: Manish Mehta (manishmehta@india.com) Date: 04/16/2001 Scenario 1: Two file transfer TCP connections using the same link with two routers in

More information

SIMON FRASER UNIVERSITY SCHOOL OF ENGINEERING SCIENCE. Spring 2013 ENSC 427: COMMUNICATION NETWORKS. Midterm No. 2(b) Monday, March 18, 2013

SIMON FRASER UNIVERSITY SCHOOL OF ENGINEERING SCIENCE. Spring 2013 ENSC 427: COMMUNICATION NETWORKS. Midterm No. 2(b) Monday, March 18, 2013 SIMON FRASER UNIVERSITY SCHOOL OF ENGINEERING SCIENCE Spring 2013 ENSC 427: COMMUNICATION NETWORKS Midterm No. 2(b) Monday, March 18, 2013 Duration: 50 minutes. Attempt all problems. Questions may not

More information

Introduction to LAN Protocols

Introduction to LAN Protocols CHAPTER 2 Introduction to LAN Protocols This chapter introduces the various media-access methods, transmission methods, topologies, and devices used in a local area network (LAN). Topics addressed focus

More information

Communication Networks - 3 general areas: data communications, networking, protocols

Communication Networks - 3 general areas: data communications, networking, protocols Communication Networks - Overview CSE 3213 Fall 2011 1 7 September 2011 Course Content 3 general areas: data communications, networking, protocols 1. Data communications: basic concepts of digital communications

More information

Lab 1: Evaluating Internet Connection Choices for a Small Home PC Network

Lab 1: Evaluating Internet Connection Choices for a Small Home PC Network Requirement Lab 1: Evaluating Internet Connection Choices for a Small Home PC Network This set of labs works in conjunction with Professor Ray Panko s textbook, Business Data Networks and Telecommunications.

More information

Contention Protocols and Networks

Contention Protocols and Networks 4/13/2005 314 Lecture Contention Protocols and Networks 1 Contention Protocols and Networks Contention Protocols CSMA/CD Network Topologies Ethernet 4/13/2005 314 Lecture Contention Protocols and Networks

More information

Cover sheet for Assignment 3

Cover sheet for Assignment 3 Faculty of Arts and Science University of Toronto CSC 358 - Introduction to Computer Networks, Winter 2018, LEC0101 Cover sheet for Assignment 3 Due Monday March 5, 10:00am. Complete this page and attach

More information

CS321: Computer Networks Congestion Control in TCP

CS321: Computer Networks Congestion Control in TCP CS321: Computer Networks Congestion Control in TCP Dr. Manas Khatua Assistant Professor Dept. of CSE IIT Jodhpur E-mail: manaskhatua@iitj.ac.in Causes and Cost of Congestion Scenario-1: Two Senders, a

More information

PARALLEL ALGORITHMS FOR IP SWITCHERS/ROUTERS

PARALLEL ALGORITHMS FOR IP SWITCHERS/ROUTERS THE UNIVERSITY OF NAIROBI DEPARTMENT OF ELECTRICAL AND INFORMATION ENGINEERING FINAL YEAR PROJECT. PROJECT NO. 60 PARALLEL ALGORITHMS FOR IP SWITCHERS/ROUTERS OMARI JAPHETH N. F17/2157/2004 SUPERVISOR:

More information

6 MPLS Model User Guide

6 MPLS Model User Guide 6 MPLS Model User Guide Multi-Protocol Label Switching (MPLS) is a multi-layer switching technology that uses labels to determine how packets are forwarded through a network. The first part of this document

More information

Eng 3553 Lab #5 TCP Throughput

Eng 3553 Lab #5 TCP Throughput Eng 3553 Lab #5 TCP Throughput Overview TCP (Transmission Control Protocol) is a means for building a reliable communications stream, enabling two hosts to establish a connection and exchange streams of

More information

International Journal of Scientific Research and Modern Education (IJSRME) ISSN (Online): ( Volume I, Issue I,

International Journal of Scientific Research and Modern Education (IJSRME) ISSN (Online): (  Volume I, Issue I, EFFECTIVE LEARNING WITH USAGE OF SIMULATORS A CASE OF NCTUNS SIMULATOR IN COMPUTER NETWORKS Subrahmanya Bhat* & Dr. K. R. Kamath** * Department of Computer Application, Srinivas Institute of Management

More information

TCP versus UDP Response Time

TCP versus UDP Response Time Lab 9 TCP versus UDP Response Time Overview TCP provides connection-oriented service at the transport layer, and UDP provides connectionless service. As a result, a data exchange using TCP can take longer

More information

ECE453 Introduction to Computer Networks. Broadcast vs. PPP. Delay. Lecture 7 Multiple Access Control (I)

ECE453 Introduction to Computer Networks. Broadcast vs. PPP. Delay. Lecture 7 Multiple Access Control (I) ECE453 Introduction to Computer Networks Lecture 7 Multiple Access Control (I) 1 Broadcast vs. PPP Broadcast channel = multiaccess channel = random access channel Broadcast LAN Satellite network PPP WAN

More information

Multiple unconnected networks

Multiple unconnected networks TCP/IP Life in the Early 1970s Multiple unconnected networks ARPAnet Data-over-cable Packet satellite (Aloha) Packet radio ARPAnet satellite net Differences Across Packet-Switched Networks Addressing Maximum

More information

TCP Congestion Control in Wired and Wireless networks

TCP Congestion Control in Wired and Wireless networks TCP Congestion Control in Wired and Wireless networks Mohamadreza Najiminaini (mna28@cs.sfu.ca) Term Project ENSC 835 Spring 2008 Supervised by Dr. Ljiljana Trajkovic School of Engineering and Science

More information

TSIN01 Information Networks Lecture 3

TSIN01 Information Networks Lecture 3 TSIN01 Information Networks Lecture 3 Danyo Danev Division of Communication Systems Department of Electrical Engineering Linköping University, Sweden September 10 th, 2018 Danyo Danev TSIN01 Information

More information

CS 5520/ECE 5590NA: Network Architecture I Spring Lecture 13: UDP and TCP

CS 5520/ECE 5590NA: Network Architecture I Spring Lecture 13: UDP and TCP CS 5520/ECE 5590NA: Network Architecture I Spring 2008 Lecture 13: UDP and TCP Most recent lectures discussed mechanisms to make better use of the IP address space, Internet control messages, and layering

More information

===================================================================== Exercises =====================================================================

===================================================================== Exercises ===================================================================== ===================================================================== Exercises ===================================================================== 1 Chapter 1 1) Design and describe an application-level

More information

Chapter 4 Determining Cell Size

Chapter 4 Determining Cell Size Chapter 4 Determining Cell Size Chapter 4 Determining Cell Size The third tutorial is designed to give you a demonstration in using the Cell Size Calculator to obtain the optimal cell size for your circuit

More information

Modelling a Video-on-Demand Service over an Interconnected LAN and ATM Networks

Modelling a Video-on-Demand Service over an Interconnected LAN and ATM Networks Modelling a Video-on-Demand Service over an Interconnected LAN and ATM Networks Kok Soon Thia and Chen Khong Tham Dept of Electrical Engineering National University of Singapore Tel: (65) 874-5095 Fax:

More information

COS 140: Foundations of Computer Science

COS 140: Foundations of Computer Science COS 140: Foundations of Computer Science ALOHA Network Protocol Family Fall 2017 Homework 2 Introduction 3 Network Protocols.......................................................... 3 Problem.................................................................

More information

ECE 158A: Lecture 13. Fall 2015

ECE 158A: Lecture 13. Fall 2015 ECE 158A: Lecture 13 Fall 2015 Random Access and Ethernet! Random Access! Basic idea: Exploit statistical multiplexing Do not avoid collisions, just recover from them When a node has packet to send Transmit

More information

Chapter 8: Subnetting IP Networks

Chapter 8: Subnetting IP Networks Chapter 8: Subnetting IP Networks Designing, implementing and managing an effective IP addressing plan ensures that networks can operate effectively and efficiently. This is especially true as the number

More information

Basics (cont.) Characteristics of data communication technologies OSI-Model

Basics (cont.) Characteristics of data communication technologies OSI-Model 48 Basics (cont.) Characteristics of data communication technologies OSI-Model Topologies Packet switching / Circuit switching Medium Access Control (MAC) mechanisms Coding Quality of Service (QoS) 49

More information

3D Network Visualizer

3D Network Visualizer 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets you create three-dimensional animations based on topology information, node relationships, performance statistics, and terrain

More information

Course 6. Internetworking Routing 1/33

Course 6. Internetworking Routing 1/33 Course 6 Internetworking Routing 1/33 Routing The main function of the network layer is routing packets from the source machine to the destination machine. Along the way, at least one intermediate node

More information

Network II Lab 01. Part 01: Interface Overview. Program interface

Network II Lab 01. Part 01: Interface Overview. Program interface Part 01: Interface Overview Network II Lab 01 This initial interface contains ten components. If you are unsure of what a particular interface item does, move your mouse over the item and a help balloon

More information

Module 16: Distributed System Structures

Module 16: Distributed System Structures Chapter 16: Distributed System Structures Module 16: Distributed System Structures Motivation Types of Network-Based Operating Systems Network Structure Network Topology Communication Structure Communication

More information

Wide area networks: packet switching and congestion

Wide area networks: packet switching and congestion Wide area networks: packet switching and congestion Packet switching ATM and Frame Relay Congestion Circuit and Packet Switching Circuit switching designed for voice Resources dedicated to a particular

More information

DiffServ Architecture: Impact of scheduling on QoS

DiffServ Architecture: Impact of scheduling on QoS DiffServ Architecture: Impact of scheduling on QoS Abstract: Scheduling is one of the most important components in providing a differentiated service at the routers. Due to the varying traffic characteristics

More information

Southern Polytechnic State University Spring Semester 2009

Southern Polytechnic State University Spring Semester 2009 Southern Polytechnic State University Spring Semester 2009 ECET 4840 Laboratory Exercises 9: Router Queuing Configuration and Testing Objective: Students will investigate the effect of varying link capacity

More information

UNIT 2 TRANSPORT LAYER

UNIT 2 TRANSPORT LAYER Network, Transport and Application UNIT 2 TRANSPORT LAYER Structure Page No. 2.0 Introduction 34 2.1 Objective 34 2.2 Addressing 35 2.3 Reliable delivery 35 2.4 Flow control 38 2.5 Connection Management

More information

CS610- Computer Network Solved Subjective From Midterm Papers

CS610- Computer Network Solved Subjective From Midterm Papers Solved Subjective From Midterm Papers May 08,2012 MC100401285 Moaaz.pk@gmail.com Mc100401285@gmail.com PSMD01 CS610- Computer Network Midterm Examination - Fall 2011 1. Where are destination and source

More information

Integrated t Services Digital it Network (ISDN) Digital Subscriber Line (DSL) Cable modems Hybrid Fiber Coax (HFC)

Integrated t Services Digital it Network (ISDN) Digital Subscriber Line (DSL) Cable modems Hybrid Fiber Coax (HFC) Digital Local Loop Technologies Integrated t Services Digital it Network (ISDN) Handles voice and data Relatively l high h cost for low bandwidth (Skip) Digital Subscriber Line (DSL) Cable modems Hybrid

More information

The Network Layer and Routers

The Network Layer and Routers The Network Layer and Routers Daniel Zappala CS 460 Computer Networking Brigham Young University 2/18 Network Layer deliver packets from sending host to receiving host must be on every host, router in

More information

IP Network Emulation

IP Network Emulation Developing and Testing IP Products Under www.packetstorm.com 2017 PacketStorm Communications, Inc. PacketStorm is a trademark of PacketStorm Communications. Other brand and product names mentioned in this

More information

Key words: IP router, Differentiated services, QoS, Custom Queuing, Priority Queuing. 1. INTRODUCTION

Key words: IP router, Differentiated services, QoS, Custom Queuing, Priority Queuing. 1. INTRODUCTION OPNET Modeling of an IP Router with Scheduling Algorithms to Implement Differentiated Services Hiroshi Yamada NTT Service Integration Laboratories, Communication Traffic Project, Traffic Solution Group

More information

Performance of Telecommunication Networks

Performance of Telecommunication Networks MONASH UNIVERSITY DEPARTMENT OF ELECTRICAL & COMPUTER SYSTEMS ENGINEERING Performance of Telecommunication Networks Experiment IV: Delay and Queueing in Packet Switching Networks Y. Ahmet Şekercioğlu Aims

More information

COSC 6377 Mid-Term #2 Fall 2000

COSC 6377 Mid-Term #2 Fall 2000 Name: SSN: Signature: Open book, open notes. Your work must be your own. Assigned seating. Test time: 7:05pm to 8:05pm. You may not use a calculator or PalmPilot to calculate subnetting/host/netid information.

More information

Module 15: Network Structures

Module 15: Network Structures Module 15: Network Structures Background Topology Network Types Communication Communication Protocol Robustness Design Strategies 15.1 A Distributed System 15.2 Motivation Resource sharing sharing and

More information

NetBrain Quick Start Guide For End Users

NetBrain Quick Start Guide For End Users NetBrain Quick Start Guide For End Users Dynamic Documentation Network Analysis Visual Troubleshooting Automation Qapp Network Change Management Thin Client NetBrain Technologies, Inc. 2004-2016. All rights

More information

Introduction to LAN Protocols

Introduction to LAN Protocols CHAPTER 2 Chapter Goals Learn about different LAN protocols. Understand the different methods used to deal with media contention. Learn about different LAN topologies. This chapter introduces the various

More information

AMCP/4-WP/70. b) requirements and recommendations together with their rationale; and

AMCP/4-WP/70. b) requirements and recommendations together with their rationale; and Appendix A to the Report on Agenda Item 3 3A-1 APPENDIX A VHF DIGITAL LINK (VDL) DESIGN GUIDELINES 1. INTRODUCTION 1.1 In the absence of a comprehensive and detailed set of operational requirements, the

More information

Chapter 1 Modeling Overview

Chapter 1 Modeling Overview Chapter 1 Modeling Overview 1-Ov 2-Ov Modeling Concepts Modeling Concepts Introduction Ov.1 Introduction OPNET provides a comprehensive development environment supporting the modeling of communication

More information

ADVANCED COMPUTER NETWORKS

ADVANCED COMPUTER NETWORKS ADVANCED COMPUTER NETWORKS Congestion Control and Avoidance 1 Lecture-6 Instructor : Mazhar Hussain CONGESTION CONTROL When one part of the subnet (e.g. one or more routers in an area) becomes overloaded,

More information

Medium Access Protocols

Medium Access Protocols Medium Access Protocols Summary of MAC protocols What do you do with a shared media? Channel Partitioning, by time, frequency or code Time Division,Code Division, Frequency Division Random partitioning

More information

William Stallings Data and Computer Communications. Chapter 10 Packet Switching

William Stallings Data and Computer Communications. Chapter 10 Packet Switching William Stallings Data and Computer Communications Chapter 10 Packet Switching Principles Circuit switching designed for voice Resources dedicated to a particular call Much of the time a data connection

More information

Lab 4: Changing Frame Relay PVC Speeds in a WAN Environment

Lab 4: Changing Frame Relay PVC Speeds in a WAN Environment Objective Lab 4: Changing Frame Relay PVC Speeds in a WAN Environment This lab investigates the performance of applications across a Wide Area Network. We examine how changing the speeds of Frame Relay

More information

Interface The exit interface a packet will take when destined for a specific network.

Interface The exit interface a packet will take when destined for a specific network. The Network Layer The Network layer (also called layer 3) manages device addressing, tracks the location of devices on the network, and determines the best way to move data, which means that the Network

More information

Summary of MAC protocols

Summary of MAC protocols Summary of MAC protocols What do you do with a shared media? Channel Partitioning, by time, frequency or code Time Division, Code Division, Frequency Division Random partitioning (dynamic) ALOHA, S-ALOHA,

More information

Advanced Internet Technologies

Advanced Internet Technologies Advanced Internet Technologies Chapter 3 Performance Modeling Dr.-Ing. Falko Dressler Chair for Computer Networks & Internet Wilhelm-Schickard-Institute for Computer Science University of Tübingen http://net.informatik.uni-tuebingen.de/

More information

Monitoring and Analysis

Monitoring and Analysis CHAPTER 3 Cisco Prime Network Analysis Module 5.1 has two types of dashboards: One type is the summary views found under the Monitor menu, and the other type is the over time views found under the Analyze

More information

CS 344/444 Computer Network Fundamentals Final Exam Solutions Spring 2007

CS 344/444 Computer Network Fundamentals Final Exam Solutions Spring 2007 CS 344/444 Computer Network Fundamentals Final Exam Solutions Spring 2007 Question 344 Points 444 Points Score 1 10 10 2 10 10 3 20 20 4 20 10 5 20 20 6 20 10 7-20 Total: 100 100 Instructions: 1. Question

More information

OPNET. Mustafa Ergen. UC Berkeley

OPNET. Mustafa Ergen. UC Berkeley OPNET Mustafa Ergen ergen@eecs.berkeley.edu UC Berkeley Overview Introduction Design Process domain Node domain Network domain Communication mechanism Simulation Statistics Probe Analysis IEEE 802.11 MAC

More information

Project: E337 GRAPHIC INTERFACE DESIGN FOR SIMULATION SOFTWARE

Project: E337 GRAPHIC INTERFACE DESIGN FOR SIMULATION SOFTWARE Undergraduate Research Opportunity Programme (UROP) Project: E337 GRAPHIC INTERFACE DESIGN FOR SIMULATION SOFTWARE Supervisor Asst.Professor Ma MaoDe Nanyang Technological University Email: emdma@ntu.edu.sg

More information

Distributed System Chapter 16 Issues in ch 17, ch 18

Distributed System Chapter 16 Issues in ch 17, ch 18 Distributed System Chapter 16 Issues in ch 17, ch 18 1 Chapter 16: Distributed System Structures! Motivation! Types of Network-Based Operating Systems! Network Structure! Network Topology! Communication

More information

Security Labs in OPNET IT Guru

Security Labs in OPNET IT Guru Security Labs in OPNET IT Guru Universitat Ramon Llull Barcelona 2004 Security Labs in OPNET IT Guru Authors: Cesc Canet Juan Agustín Zaballos Translation from Catalan: Cesc Canet -I- Overview This project

More information

Packet Tracer - Investigating the TCP/IP and OSI Models in Action (Instructor Version Optional Packet Tracer)

Packet Tracer - Investigating the TCP/IP and OSI Models in Action (Instructor Version Optional Packet Tracer) (Instructor Version Optional Packet Tracer) Instructor Note: Red font color or gray highlights indicate text that appears in the instructor copy only. Optional activities are designed to enhance understanding

More information