0% found this document useful (0 votes)
27 views46 pages

20CP022 LAB 7 To 12

Uploaded by

Raj shah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views46 pages

20CP022 LAB 7 To 12

Uploaded by

Raj shah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 46

LAB - 7

1. Introduce students to network simulation through the NetSim


simulation package, createa simple network model with multiple
scenarios, collect statistics on network performance through the use of
NetSim tools, analyze statistics and draw conclusions on network
performance.

Part A:

Introduce students to network simulation through the NetSim simulation package.

Theory:

 What is NetSim?
NetSim is a network simulation tool that allows you to create network scenarios, model
traffic, and study performance metrics.

 What is a network?
A network is a set of hardware devices connected together, either physically or logically.This
allows them to exchange information.

A network is a system that provides its users with unique capabilities, above and beyondwhat
the individual machines and their software applications can provide.

 What is simulation?

A simulation is the imitation of the operation of a real-world process or system overtime.

Network simulation is a technique where a program models the behavior of a network either
by calculating the interaction between the different network entities (hosts/routers, data links,
packets, etc) using mathematical formulae, or actually capturingand playing back observations
from a production network. The behavior of the network and the various applications and
services it supports can then be observed in a test lab; various attributes of the environment
can also be modified in a controlled manner toassess how the network would behave under
different conditions.
 What does NetSim provide?

Simulation: NetSim provides simulation of various protocols working in various networks as


follows: Internetworks, Legacy Networks, BGP Networks, MPLS Networks, Advanced
Wireless Networks, Cellular Networks, Wireless Sensor Networks, Personal Area Networks,
LTE Networks and Cognitive Radio Networks. Users can open, save, and delete experiments
as desired. The different experiments can also be analyzed using the analytics option in the
simulation menu.

Programming: NetSim covers various programming exercises along with concepts, algorithms,
pseudo code and flowcharts. Users can also write their own source codes in C/C++ and can link
them to NetSim.

Some of the programming concepts are Address resolution protocol (ARP), Classless inter
domain routing (CIDR), Cryptography, Distance vector routing, shortest path, Subnetting etc.

Real time: Frame capture is covered in this section. It is used to capture packets when there is
an active data transfer taking place and also provides performance metrics. Note: This menu is
available only in Academic Version.

Utilities: This section handles the user management section used for adding/deleting users,
setting passwords etc.

Part B:

Create a Simple network model with multiple scenarios. Collect statistics on network
performance through the use of NetSim. Analyze statistics and draw conclusion on network
performance.

Theory:

 Network model: A Network model is a flexible way of representing devices and their
relationships. Networking devices like hubs, switches, routers, nodes, connectingwires etc. are
used to create a network model.
 Scenario: A Scenario is a narrative describing foreseeable interactions of types of input
data and its respective output data in the system.
 Network performance: To measure the performance of a network, performance
metrics constitutes of Network Statistics.

 What are network statistics?


Network statistics are network performance related metrics collected at the end of a
simulation run. The report at the end of the completion of an simulation experimentinclude
metrics like throughput, simulation time, frames generated, frames dropped, frames errored,
collision counts etc, and their respective values.

 What is Packet Animation?


When running simulation, options are available to play and record animations whichallow
users to watch traffic flow through the network for in-depth visualization and analysis.

 What is NetSim analytics used for?


It is used to compare and analyze various protocols scenarios under Internetworks, Legacy
Networks, BGP Networks, MPLS Networks, Advanced Wireless Networks - MANET,
Advanced Wireless Networks – WiMAX, Cellular Networks, Wireless Sensor Networks,
Personal Area Networks, LTE Networks and Cognitive Radio Networks. Parameters like
utilization, loss, queuing delay, transmission time etc of different sample experiments are
compared with help of graphs.
2. Framing Sequence
 Bit Stuffing and character stuffing

Part A - Bit Stuffing

Theory:

When data is transmitted, the transmitter should distinguish between the start and the end of
the data. This is done to ensure that the receiving node reads the data completely. This is
accomplished by appending a unique pattern of bit stream before and after the data.
Care should be taken to ensure that this unique pattern does not occur in the data itself. Ifthe
pattern appears in the data then the data is broken. The process of appending a uniquepattern
and breaking the pattern is known as framing.

Bit Stuffing is one of the framing methods, in which each frame begins and ends with a
special bit pattern „0111110‟, called a flag byte.

Whenever the sender‟s data link layer encounters six consecutive 1‟s in the data, it
automatically stuffs a 0 bit into the outgoing bit stream to break the pattern.

Algorithm:
1. Get the Value of Destination Address, Source Address, Data, CRC Polynomial
and Error Status by reading Input.txt.

2. Call the function fnASCII_to_Binary () to get the Binary Values for each
characters in the Data field.

3. Call the function fnBitStuffing () to do the bit stuffing process.

4. Calculate the checksum by calling the function fnCheckSum_Calculation.

5. Initialize nLoop1, nCount and nIndex to zero.

6. Combine the Destination Address, Source Address and Binary Values in single
character array.

7. Loop through all the bits

Check nLoop_Length >= 0 && nLoop_Length < 8


Check pszBits [nLoop_Length] == 1
Increment nCount by 1
Stuffed Destination Address [nIndex] = „1‟
Check nCount == 5
Increment nIndex by 1
Stuffed Destination Address [nIndex] = „0‟
nCount = 0
Increment nIndex by 1
Else

nCount = 0
Stuffed Destination Address [nIndex] = „0‟
Increment nIndex by 1
Check nLoop_Length == 7
Stuffed Destination Address [nIndex] = „\0‟
nIndex = 0
8. Similarly repeat step6 for the Source Address and Binary Values for the
stuffing process.
9. Call the function fnDestuffing () to do the destuffing process.
10. Initialize nLoop1, nCount and nIndex to zero.
11. Loop through all the bits
Check pszBits [nLoop_Length] == 1
Increment nCount by 1
Check nCount == 5
Loop through all the bits
pszBits [nIndex] = pszBits [nIndex + 1]
Increment nIndex by 1
nCount = 0
Else
nCount = 0
12. Call the function fnBinary_to_ASCII () to get the ASCII values and the
message sent by the Transmitter.

13. Write those values into Output.txt.


Procedure:

To begin with the experiment, open NetSim.


Click on Programming from the menu bar, select framing Sequence and then select Bit
Stuffing

Step 1:

Select the User mode to write your own program in C/C++, compile and link to NetSim
software for validation. Click on the F 1(help) for details to write your own code.

Continue with the steps as given for Sample mode.


Step 2:

Here enter the source address, destination address and the data which you want to give as
an input. Now click Run button to execute the program.
Part B - Character Stuffing

Theory:

When data is transmitted, the transmitting node should distinguish between the start andthe
end of the receiving node to read the data completely. This is accomplished by appending a
unique pattern of bit stream before and after the data.

Care is taken that this unique pattern does not occur in the data. If the pattern appears in the
data, it is broken. The process of appending a unique pattern and breaking the patternis known
as framing.

Character stuffing is one of the framing methods, in which each frame starts with DLESTX
(Starting delimiter) character sequence and ends with DLE ETX (Ending delimiter)character
sequence.

Characters for DLE STX or DLE ETX may occur in the data. To solve this problem the
transmitting node inserts a DLE character just before each DLE character occurring in thedata.

Algorithm:
1. Get the Value of Starting Delimiter, Destination Address, Source Address, Data,
Checksum and Ending Delimiter by reading Input.txt.
2. Call the function fnCharacterStuffing () to do the character stuffing process.
3. Loop through all the bytes in Destination Address
Check szDestinationAddress [nLoop1] != „\0‟
sz_Stuffed_DestinationAddress [nIndex] = szDestinationAddress
[nLoop1]
Increment nIndex by 1
Check szDestinationAddress [nLoop1] == szStartingDelimiter [0]
sz_Stuffed_DestinationAddress [nIndex] = szStartingDelimiter [0]
Increment nIndex by 1
Check szDestinationAddress [nLoop1] == szEndingDelimiter [0]
sz_Stuffed_DestinationAddress [nIndex] = szEndingDelimiter [0]
Increment nIndex by 1
Increment nLoop1 by 1
sz_Stuffed_DestinationAddress [nIndex] = '\0';
4. Similarly repeat step3 for Source Address, Data and Checksum.
5. Call the function fnDeStuffing () to do the destuffing process.
6. Copy all the bytes from Stuffed Destination Address to Destuffed Destination
Address
7. Loop through all the bytes in Destuffed Destination Address
Check sz_Destuffed_DestinationAddress [nLoop1] != „\0‟
Check sz_Destuffed_DestinationAddress [nLoop1] ==
szStartingDelimiter [0] && sz_Destuffed_DestinationAddress [nLoop1]
== szEndingDelimiter [0]
Check nIndex < strlen (sz_Destuffed_DestinationAddress)
sz_DeStuffed_DestinationAddress [nIndex] =
sz_DeStuffed_DestinationAddress [nIndex + 2];
Increment nIndex by 1
nIndex = 0
Else if sz_Destuffed_DestinationAddress [nLoop1] ==
szStartingDelimiter [0] || sz_Destuffed_DestinationAddress [nLoop1] ==
szEndingDelimiter [0]
Check nIndex < strlen (sz_Destuffed_DestinationAddress)
sz_DeStuffed_DestinationAddress [nIndex] =
sz_DeStuffed_DestinationAddress [nIndex + 1];
Increment nIndex by 1
nIndex = 0
Increment nLoop1 by 1
8. Similarly repeat step7 for Source Address, Data and Checksum and write those
values into Output.txt.

Procedure:

To begin with the experiment, open NetSim


Click on Programming from the menu bar, select framing Sequence and then select
Character Stuffing

Step 1:

Select the User mode to write your own program in C/C++, compile and link to NetSim
software for validation. Click on the F 1 (help) for details on how to proceed with your own
code.

Continue with the steps as given for Sample mode.


3. Error Detection
Cyclic Redundancy Check
Theory:

Cyclic redundancy check (CRC) is a type of function that takes as input a data stream of
any length, and produces an output. Bit strings are treated as representation of
polynomials with coefficients of „0‟ and „1‟.

The Sender and Receiver must agree upon the Generator Polynomial in advance. The size
of data must be greater than the size of the Generator polynomial to compute the
checksum.

The computed checksum is appended to the transmitting frame. If the receiver gets the
frame it tries dividing it by Generator polynomial, if there is a reminder there has been a
transmission error, else no error.

The Generator polynomial for CRC 12 is x12 + x11 + x3 + x2 + x1 + 1

The Binary equivalent of CRC - 12 is 1100000001111

Algorithm:

No Error Case

Sender side

 Read the input from "Input.txt". Parse the file content.


 Call the In-built function read File.
1. Convert the data string to be transmitted into binary representation.

2. Get ASCII value of the first character.

3. Divide the ASCII value by 2; append the remainder to a string. The quotient
is taken as the next number for the division.

 Repeat the above division processes until the quotient of the number is less than 2.
 Finally we get the remainder string having 1‟s and 0‟s, which is the binary
representation of that character.
 Continue above process for all the characters in the data string.
 Append 12 „0‟s to the final binary string formed by the above step.
 Divide the binary converted data string using the Generator Polynomial (given
above CRC 12).
 Take the MSB 13 bits from the binary data string.
 If the leading bit of the binary data string is „0‟, do an XOR operation with the 13
bits of „0‟s and get the remainder which is also 13 bits.
 Else if the leading bit of the binary data string is „1‟, do an XOR operation with
the 13 bits with binary converted CRC 12 polynomial and get the remainder which
is also 13 bits.
 The first bit of the remainder is left out and the remainder is made to 12 bits.
 If there are successive bits in the data, make the previous remainder bit to 13 bits
by bringing down the next bit in the data
 Convert the final remainder into HEXA equivalent character.
 Divide the final remainder into blocks of 4 bits.
 Convert each block into equivalent HEXA character.
 Thus the output of this whole process will be a 3 - nibble checksum that is
attached to the transmitting frame.

Receiver side

 Repeat the Steps 1 to 4 of the Sender side CRC coding and get the CRC value for
the data.
 Convert the HEXA equivalent string to its binary format. This is the Hexadecimal
to binary conversion process.
 Append the binary format of the above step to the CRC variable. Then append 12
„0s‟ to the CRC variable.
 Repeat the Steps 6 and 7 of the Sender Side CRC coding to calculate the CRC
value for the receiver side.
Error Case

Sender side

 Get the input from "Input.txt". Parse the file content.


 Call the In - built function read File.
1. Convert the data string to be transmitted into binary representation.

2. Get ASCII value of the first character.

3. Divide the ASCII value by 2; append the remainder to a string. The quotient

is taken as the next number for the division.

 Repeat the above division processes until the quotient of the number is less than 2.
 Finally we get the remainder string having 1‟s and 0‟s, which is the binary
representation of that character.
 Continue above process for all the characters in the data string.
 Append 12 „0‟s to the final binary string formed by the above step.
 Divide the binary converted data string using the Generator Polynomial (given
above CRC 12).
 Take the MSB 13 bits from the binary data string.
 If the leading bit of the binary data string is „0‟, do an XOR operation with the 13
bits of „0‟s and get the remainder which is also 13 bits.
 Else if the leading bit of the binary data string is „1‟, do an XOR operation with
the 13 bits with binary converted CRC 12 polynomial and get the remainder which
is also 13 bits.
 The first bit of the remainder is left out and the remainder is made to 12 bits.
 If there are successive bits in the data, make the previous remainder bit to 13 bits
by bringing down the next bit in the data
 Convert the final remainder into HEXA equivalent character.
 Divide the final remainder into blocks of 4 bits.
 Convert each block into equivalent HEXA character.
 Thus the output of this whole process will be a 3-nibble checksum that is attached
to the transmitting frame.
Receiver side

 Repeat the Steps 1 to 4 of the Sender side CRC coding and get the CRC value for
the data.
 Make some errors in the string CRC by changing certain characters. The error
string is stored in the variable CRC.
 Write the Error string CRC into the file „Input.txt‟. The file path for the file
„Input.txt" is the path where you have installed the NetSim application.
(Compulsory).
 Convert the HEXA equivalent string CRC to its binary format. This is the
Hexadecimal to binary conversion process.
 Append the binary format of the above step to the CRC variable. Then append 12
„0s‟ to the CRC variable.
 Repeat the Steps 6 and 7 of the Sender Side CRC coding to calculate the CRC
value for the receiver side.

Procedure:

To begin with the experiment, open NetSim


Click on Programming in the menu bar, select Error Detecting Codes and then select
Cyclic Redundancy Check.

The scenario will be obtained as shown below. Follow the steps.


Step 1:
Select the User mode to write your own program in C/C++, compile and link to NetSim
software for validation. Click on the F1 (Help) for details on how to proceed with your
own code.
Continue with the steps as given for Sample mode.
When you

Results:
Error condition: No Error
LAB - 8

1. Study the throughput characteristics of a slotted aloha network

Objective: Plot the characteristic curve throughput versus offered traffic for a Slotted
ALOHA system.
(Reference: Computer Networks, 3rd Edition. Andrew S. Tanenbaum)

Theory:
ALOHA provides a wireless data network. It is a multiple access protocol (this protocol is
for allocating a multiple access channel). There are two main versions of ALOHA: pure
and slotted. They differ with respect to whether or not time is divided up into discrete
slots into which all frames must fit.

Slotted ALOHA:
In slotted Aloha, time is divided up into discrete intervals, each interval corresponding to
one frame. In Slotted ALOHA, a computer is required to wait for the beginning of the
next slot in order to send the next packet. The probability of no other traffic being
initiated during the entire vulnerable period is given by which leads to � = � �−�
where, S (frames per frame time) is the mean of the Poisson distribution with which
frames are being generated. For reasonable throughput S should lie between 0 and 1.
G is the mean of the Poisson distribution followed by the transmission attempts per frame
time, old and new combined. Old frames mean those frames that have previously suffered
collisions.
It is easy to note that Slotted ALOHA peaks at G=1, with a throughput of or
about 0.368. It means that if the system is operating at G=1, the probability of an empty
slot is 0.368

Calculations used in NetSim to obtain the plot between S and G:


Using NetSim, the attempts per packet time (G) can be calculated as follows;
TA * PT
G=
ST * 1000
Where, G = Attempts per packet time
TA = Total Attempt
PT = Packet time (in seconds)
ST = Simulation time (in seconds)

The throughput (in Mbps) per packet time can be obtained as follows:
Throughput(in Mbps) * 1000 * PT
S=
PS * 8
Where, S = Throughput per packet time
PT = Packet time (in milliseconds)
PS = Packet size (in bytes)
Calculations for the packet time:
Packet Size(bits)
PT =
Band Width(Mbps)
Sample Inputs:
Input for Sample 1: Node 1 generates traffic. The properties of Node 1 which transmits
data to Node 2 are selected as follows:

Simulation Time- 10 Seconds

(Note: The Simulation Time can be selected only after doing the following two tasks,
 Set the properties of Nodes
 Then click on Run Simulation button).
 Obtain the values of Throughput and Total Attempts from the statistics of NetSim
simulation for various numbers of traffic generators.
Thus the following characteristic plot for the Slotted ALOHA is obtained, which matches
the theoretical result.

Slotted Aloha
Throughput per packet time 0.35
0.3

0.25

0.2
Slotted Aloha
0.15

0.1
0.05

0
0.06
0.39
0.59
0.8
1.09
1.67
1.78
1.8
1.92
1.96
1.97
2
Attempt per packet
time
Note: The optimum value is slightly less than the theoretical maximum of 0.368 because
NetSim‟s simulation is per real-world and includes overheads, inter-frame gaps etc.

2. Understand the impact of bit error rate on packet error and


investigate the impact of error of a simple hub based CSMA / CD
network.

Theory:
Bit error rate (BER): The bit error rate or bit error ratio is the number of bit errors
divided by the total number of transferred bits during a studied time interval i.e.

Bit errors
BER =
Total number of bits

For example, a transmission might have a BER of 10-5, meaning that on average, 1 out of
every of 100,000 bits transmitted exhibits an error. The BER is an indication of how
often a packet or other data unit has to be retransmitted because of an error.
Unlike many other forms of assessment, bit error rate, BER assesses the full end to end
performance of a system including the transmitter, receiver and the medium between the
two. In this way, bit error rate, BER enables the actual performance of a system in
operation to be tested.

Bit error probability (pe): The bit error probability is the expectation value of the BER.
The BER can be considered as an approximate estimate of the bit error probability. This
estimate is accurate for a long time interval and a high number of bit errors.

Packet Error Rate (PER):


The PER is the number of incorrectly received data packets divided by the total number
of received packets. A packet is declared incorrect if at least one bit is erroneous.
The expectation of the PER is denoted as packet error probability pp, which for a data
packet length of N bits can be expressed as,

It is based on the assumption that the bit errors are independent of each other.
Derivation of the packet error probability:
Suppose packet size is N bits.
As packet size is N bits and it is the assumption that the bit errors are independent. Hence,
Probability of a packet with no errors =
A packet is erroneous if at least there is one bit error, hence
Probability of packet error=1-

Procedure:
How to create a scenario and generate traffic:
 Create Scenario: “Simulation  New Legacy Networks Traditional Ethernet”.

Example 1:
Create samples by varying the bit error rate (10-6, 10-7, 10-8, 10-9, No error) and check
whether packet error output matches the PER formula.
Sample Inputs:
To perform this sample experiment, two nodes and one hub are considered.
 Click and drop Hub on the environment builder.
 Click and drop Node1 over the hub.
 Click and drop Node2 over the hub.
The properties of Node 1 and Hub are as follows: (Node 2 has default properties)

Hub Properties Sample 1 Sample 2 Sample 3 Sample 4 Sample 5


Data rate (Mbps) 10 10 10 10 10
Error Rate (BER) No Error 10-9 10-8 10-7 10-6

Physical Medium Twisted Twisted Twisted Twisted Twisted Pair


Pair Pair Pair Pair
Simulation Time - 100 Sec
(Note: The Simulation Time can be selected only after the following two tasks,
 Set the properties for the Nodes& The Hub
 Click on the Simulate button).

Comparing Packets errored with Bit error rate:

1600

1400

1200
Packets Errored

1000

800
Two nodes transmission
600
One node transmission
400

200

0
NoError 10^-9 10^-8 10^-7 10^-6
Bit Error Rate (BER)

Inference:
From the Graph, we see that as the error rate is increased the number of errored packets
increase. The increase is exponential since the error rate is increased in powers of 10.
3. To determine the optimum persistence of a p-persistent CSMA / CD
network for a heavily loaded bus capacity.

Theory:
Carrier Sense Multiple Access Collision Detection (CSMA / CD)
This protocol includes the improvements for stations to abort their transmissions as soon
as they detect a collision. Quickly terminating damaged frames saves time and bandwidth.
This protocol is widely used on LANs in the MAC sub layer. If two or more stations
decide to transmit simultaneously, there will be a collision. Collisions can be detected by
looking at the power or pulse width of the received signal and comparing it to the
transmitted signal. After a station detects a collision, it aborts its transmission, waits a
random period of time and then tries again, assuming that no other station has started
transmitting in the meantime.
There are mainly three theoretical versions of the CSMA /CD protocol:
1-persistent CSMA / CD: When a station has data to send, it first listens to the channel
to see if anyone else is transmitting at that moment. If the channel is busy, the station
waits until it becomes idle. When station detects an idle channel, it transmits a frame. If a
collision occurs, the station waits a random amount of time and starts all over again. The
protocol is called 1-persistent because the station transmits with a probability of 1
whenever it finds the channel idle.
Ethernet, which is used in real-life, uses 1-persistence. A consequence of 1-persistence is
that, if more than one station is waiting for the channel to get idle, and when the channel
gets idle, a collision is certain. Ethernet then handles the resulting collision via the usual
exponential back off. If N stations are waiting to transmit, the time required for one
station to win the back off is linear in N.
Non-persistent CSMA /CD: In this protocol, before sending, a station senses the
channel. If no one else is sending, the station begins doing so itself. However, if the
channel is already in use, the channel does not continually sense it for the purpose of
seizing it immediately upon detecting the end of the previous transmission. Instead, it
waits a random period of time and then repeats the algorithm. Intuitively this algorithm
should lead to better channel utilization and longer delays than 1-persistent CSMA
p-persistent CSMA / CD: This protocol applies to slotted channels. When a station
becomes ready to send, it senses the channel. If it is idle, it transmits with a probability of
p. With a probability q=1-p it defers until the next slot. If that slot is also idle, it either
transmits or defers again, with probabilities p and q respectively. This process is repeated
until either the frame has been transmitted or another station has begun transmitting. In
the latter case, it acts as if there had been a collision (i.e., it waits a random time and starts
again). If the station initially senses the channel busy, it waits until the next slot and
applies the above algorithm.

How does the performance of LAN (throughput) that uses CSMA/CD protocol gets
affected as the numbers of logged in user varies:
Performance studies indicate that CSMA/CD performs better at light network loads. With
the increase in the number of stations sending data, it is expected that heavier traffic have
to be carried on CSMA/CD LANs (IEEE 802.3). Different studies have shown that
CSMA/CD performance tends to degrade rapidly as the load exceeds about 40% of the
bus capacity. Above this load value, the number of packet collision raise rapidly due to
the interaction among repeated transmissions and new packet arrivals. Collided packets
will back off based on the truncated binary back off algorithm as defined in IEEE 802.3
standards. These retransmitted packets also collide with the newly arriving packets.
Procedure:
How to create a scenario and generate traffic:
 Create Scenario: “Simulation  New Legacy Networks  Traditional Ethernet”.

Sample Input:

In this Sample experiment 12 Nodes and 2 Hubs need to be clicked and dropped onto the
Environment Builder.
Input for the Sample experiments (i.e. Totally 11 Samples) are given below,
Sample Input 1:
In the first sample for each Node the following properties have to be set,

Node Properties Values to be Selected


Transmission Type Broadcast
Traffic Type Data
No. of Nodes Transmitting 12
Persistence 1
MTU Size(bytes) 1500

Vary persistence from 1/2, 1/3, 1/4, 1/5… 1/11, 1/12 to generate other experiments.

Data Input Configuration: (This window is obtained when Data is selected in Traffic
Type):
Packet Size Distribution Constant
Application Data Size (bytes) 1472
Inter Arrival Time Distribution Exponential
Mean Inter Arrival Time(µs) 1000

Hub Properties common for Hub1 and Hub2:

Hub Properties Values to be


Selected
Data Rate(Mbps) 10
Error Rate (bit error rate) No error
Physical Medium Twisted Pair

Simulation Time - 10 Sec


(Note: The Simulation Time can be selected only after the following two tasks,
 Set the properties for the Nodes & The Hub
 Click on Run Simulation button).
Output:

After simulation of each experiment, click on the network statistics and note down the
user level throughput values. Open an excel sheet and plot a graph for these noted values
against their respective persistence values.
Comparison Chart:

Optimum

Inference:
As the number of logged in users is quite large in this experiment, the performance of a p-
persistent CSMA/CD network with large p, is not optimal because of a large number of
collisions. Therefore, we have minimum throughput when the persistence was 1/2. But as
persistence is decreased (lower and lower probabilities), the likelihood of collisions
reduce and hence throughput starts to increase. However, beyond a certain limit, in this
case 1/11 the probability of transmitting packets becomes very low and hence there aren‟t
many transmissions. Therefore, throughput starts to decline. In this experiment with 12
nodes generating traffic, we notice that the maximum throughput is at a persistence value
lying between 1/9 and 1/11.
LAB - 9

Transmission Flow Control Protocols:

1. Verification of Stop and Wait protocol.


Theory:
Stop and Wait is a reliable transmission flow control protocol. This protocol works only in
Connection Oriented (Point to Point) Transmission. The Source node has window size of ONE.
After transmission of a frame the transmitting (Source) node waits for an Acknowledgement from
the destination node. If the transmitted frame reaches the destination without error, the destination
transmits a positive acknowledgement. If the transmitted frame reaches the Destination with error,
the receiver destination does not transmit an acknowledgement. If the transmitter receives a positive
acknowledgement it transmits the next frame if any. Else if its acknowledgement receive timer
expires, it retransmits the same frame.

Procedure:
 To begin with the experiment, open NetSim
 Click on Programming from the menu bar and select Transmission Flow Control.
 Continue with the steps as given for sample mode. As soon as you begin to enter the input data file
the following window appears and you select the input data file from where you have stored.
Inference:
Due to increase in the error rate, no of errored packets also increase. If errored packets increase no
of retransmitted packets also increase.

2. Verification of Go Back N protocol.

Theory:
Go Back N is a connection-oriented transmission. The sender transmits the frames continuously.
Each frame in the buffer has a sequence number starting from 1 and increasing up to the window
size. The sender has a window i.e. a buffer to store the frames. This buffer size is the number of
frames to be transmitted continuously. The size of the window depends on the protocol designer.

Operations:
A station may send multiple frames as allowed by the window size.
Receiver sends a negative ACK if frame i has an error. After that, the receiver discards all incoming
frames until the frame with error is correctly retransmitted.
If sender receives a negative ACK it will retransmit frame i and all packets i+1, i+2, ... which have
been sent, but not been acknowledged.
Procedure:
 To begin with the experiment, open NetSim.
 Click on Programming from the menu bar and select Transmission Flow Control.
 Continue with the steps as given for sample mode.
 As soon as you begin to enter the input data file the following window appears and you select the
input data file from where you have stored.
3. Verification of Selective Repeat Protocol.

Theory:
Selective repeat is Similar to Go Back N. However, the sender only retransmits that frame for which
a negative ACK is received

Advantage over Go Back N:


 Fewer retransmissions.
Disadvantages:
 More complexity at sender and receiver.
 Receiver may receive frames out of sequence.

Operations:
 A station may send multiple frames as allowed by the window size.
 Receiver sends a negative ACK if frame i has an error. After that, the receiver does not discard all
incoming frames as in Go Back N.
 If sender receives a negative ACK it will retransmit only frame i which is the error frame.

Procedure:
 To begin with the experiment, open NetSim.
 Click on Programming from the menu bar and select Transmission Flow Control
 Continue with the steps as given for sample mode. As soon as you begin to enter the input data file
the following window appears and you select the input data file from where you have stored.
LAB - 10

1. Configure FTP and Web Server in windows OS or Linux OS.


To install the FTP server components, do the following:

1. Open Control Panel.


2. Click on Programs.
3. Under "Programs and Features," click the Turn Windows features on or off link.

1. Expand the "Internet Information Services" feature, and expand the FTP
server option.
2. Check the FTP Extensibility and FTP Service options.
3. Check the Web Management Tools option with the default selections, but
making sure that the IIS Management Console option is checked.
1. Click the OK button.
2. Click the Close button.
Once you've completed the steps, the components to set up an FTP server will be
installed on your device.

How to configure an FTP server site on Windows 10


After installing the required components, you can proceed to configure an
FTP server on the computer, which involves creating a new FTP site, setting
up firewall rules, and allowing external connections.
Setting up an FTP site
To set up an FTP site, do the following:

1. Open Control Panel.


2. Click on System and Security.
3. Click on Administrative Tools.

4. Double-click the Internet Information Services (IIS) Manager shortcut.


5. On the "Connections" pane, right-click Sites, and select the Add FTP Site option.

In the FTP site name, type a short descriptive name for the server.
6. In the "Content Directory" section, under "Physical path," click the button on the
right to locate the folder you want to use to store your FTP files.
7. Click the Next button.
8. Use the default Binding settings selections.
9. Check the Start FTP site automatically option.
10. In the "SSL" section, check the No SSL option.

11. Click the Next button.


12. In the "Authentication" section, check the Basic option.
13. In the "Authorization" section, use the drop-down menu, and select Specified
users option.
14. Type the email address of your Windows 10 account or local account name to
allow yourself access to the FTP server.
15. Check the Read and Write options.
16. Click the Finish button.
2. Configure wireless router.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy