Upload
dipshi92
View
245
Download
13
Embed Size (px)
Citation preview
8/10/2019 Network Simulation Lab Manual
1/85
EC0421 NETWORK SIMULATION LAB
LABORATORY MANUAL
SEMESTER VII
DEAPRTMENT OF
ELECTRONICS AND COMMUNICATION ENGINEERING
SRM UNIVERISTY(Under SECTION !" #$e UGC A%#& 1')*
S+R+M+ NAGAR& KATTANKULAT,UR - )020+KANC,EEPURAM DISTRICT
1
8/10/2019 Network Simulation Lab Manual
2/85
De./r#en# !" Ee%#r!n%3 /nd C!n%/#!n En5neern5
EC0421
Ne#6!r7 S/#!n L/8
L/8!r/#!r9 M/n/
C!r3e Te/
Dr+B+R//%$/ndr/n
Mr3+V+N#$9/
M3+:+R/d$7/Mr3+ P+ M//r;e
8/10/2019 Network Simulation Lab Manual
3/85
PURPOSE
To know and understand communication networks using NETSIM Software and LAN
Trainer kit.
INSTRUCTIONAL OB:ECTIVES
To study the communication networks characteristics and to analyze various MA androuting layer !rotocols.
LIST OF E>PERIMENTS
". Ethernet LAN #rotocol. To create Scenario and study the #erformance of SMA$%
#rotocol through simulation
&. Token 'us and Token (ing #rotocols. To create scenario and study the #erformance of
token )us and token ring #rotocols through simulation
*. +ireless LAN #rotocols. To create scenario and study the #erformance of network
with SMA$A #rotocol and com#are with SMA$% #rotocols
,. Im#lementation and study of Sto# and +ait #rotocol
-. Im#lementation and study of o )ack N and Selective (e#eat #rotocols/. Im#lementation of %istance 0ector (outing algorithm
1. Im#lementation of Link state routing algorithm
2. Im#lementation of data encry#tion and decry#tion
3. Transfer of files from ! to ! using +indows$ 4NI5 socket #rocessing
TOTAL 4
REFERENCE= LABORATORY MANUAL
EC0421?Ne#6!r7 S/#!n L/8
3
8/10/2019 Network Simulation Lab Manual
4/85
ourse designed )y %e#artment of Electronics 6 ommunication Engineering
!rogramoutcome
a ) c d e f g h i 7 k
5 5 5 5 5 5
ategory
eneral89
'asicSciences8'9
EngineeringSciences andTechnical Arts8E9
!rofessionalSu)7ects8!9
5'road area 8for :!;category9
ommunication Signal!rocessing
Electronics 0LSI Em)edded
5
Staff res#onsi)le for
#re#aring the sylla)us
Ms.0.Nithya
Ms.#eriment? "@3? The e>#eriments are #erformed )y configuring the nodes to
identify the network #arameters such as num)er of collisions successfully
transmitted #ackets link failure ( errors etc and the through#ut is
calculated using the formula to analyze and solve the network engineering
#ro)lem.
%+ Gr/d/#e 6 de!n3#r/#e #$e /8#9 #! de35n /nd %!nd%# e.eren#3& /n/9#eriment? "@-= The #ractical through#ut and the offered load for different
LAN To#ologies are calculated )y varying the #arameters like 'E( Inter
#acket delay etc .The o)tained data are analyzed and inter#reted using #lots.
d+ Gr/d/#e 6 de!n3#r/#e #$e /8#9 #! de35n / 393#e& %!.!nen# !r .r!%e33 /3
.er need3 /nd 3.e%"%/#!n
4
8/10/2019 Network Simulation Lab Manual
5/85
E>#eriment? "@-? The network is designed and configured for s#ecific
#arameters like the )itratesB num)er of nodes )it error rate MA #rotocol and
their #erformance are analyzed.
"+ Gr/d/#e 6 de!n3#r/#e #$e 373 #! 3e !dern en5neern5 #!!3& 3!"#6/re@3
/nd e.en# #! /n/9#eriment? / 1 2 and 3 Chel#s in using the NetSim software to analyze the
various routing algorithms
La) /? Im#lementation of %istance 0ector (outing algorithm
La) 1? Im#lementation of Link State (outing Algorithm
La)2? Im#lementation of data encry#tion and decry#tion
La)3? Transfer of files from ! to ! using +indows$ 4NI5 socket
#rocessing
7+ Gr/d/#e 6 3$!6 #$e /8#9 #! ./r#%./#e /nd #r9 #! 3%%eed n %!.e##;e
e/n/#!n3
All the e>#eriments carried out in the la) aim in knowing the )asic #rinci#lesrelating to network and solving network #ro)lems.
S8 C!de= EC0421 See3#er = VII
S8 T#e= Ne#6!r7 S/#!n L/8 C!r3e Te= :-De%@12
Prere3#e = N
C!re3#e = N
Pr!5r/ Ed%/#!n/ O8e%#;e3 ;3 Pr!5r/ O#%!ePr!5r/
O#%!e3Pr!5r/ Ed%/#!n/ O8e%#;e3
". To #re#are
students to
com#ete for a
successful
career in their
chosen
#rofession
through glo)al
education
standards.
&. To ena)le the
students to a#tly to
a##ly their acDuired
knowledge in )asic
sciences and
mathematics in
solving engineering
#ro)lems.
*. To #roduce skill
full graduates to
analyze design and
develo# a
system$com#onent$
#rocess for the
reDuired needs
under the realistic
constraints.
,.To train the
students to
a##roach
ethically any
multidisci#linar
y engineering
challenges with
economic
environmental
and social
conte>ts
-. To create an
awareness
among students
a)out the need
for life longlearning to
succeed in their
#rofessional
career.
a9raduates
will
demonstrate
knowledge of
mathematics
science and
engineering
5
8/10/2019 Network Simulation Lab Manual
6/85
)9raduate
will
demonstrate
the a)ility to
identify
formulateand solve
engineering
#ro)lem
>
c9raduate
will
demonstrate
the a)ility to
design and
conduct
e>#eriments
analyze andinter#ret data
>
d9raduate
will
demonstrate
the a)ility to
design a
system
com#onent or
#rocess as
#er needs ands#ecification
>
f9raduate
will
demonstrate
the skills to
use modern
engineering
tools
software;sand
eDui#ment to
analyze
#ro)lems
k9raduate
will show the
a)ility to
#artici#ate
and try to
succeed incom#etitive
6
8/10/2019 Network Simulation Lab Manual
7/85
e>aminations
7
8/10/2019 Network Simulation Lab Manual
8/85
S8 C!de= EC0421 See3#er = VII
S8 T#e= Ne#6!r7 S/#!n L/8 C!r3e Te= :-De%@12
Prere3#e = N
C!re3#e = N
In3#r%#!n/ O8e%#;e /nd Pr!5r/ O#%!e
S+N!+ In3#r%#!n/
O8e%#;e
Pr!5r/ O#%!e E.eren# De#/3
1
To study the
communication
networks
characteristics and to
analyze various MA
and routing layer
!rotocols.
/+ raduates will demonstrate
knowledge of mathematics
science and engineering
8. raduate will demonstrate the
a)ility to identify formulate and
solve engineering #ro)lem
%. raduate will demonstrate the
a)ility to design and conduct
e>#eriments analyze and inter#ret
data
d. raduate will demonstrate the
a)ility to design a system
com#onent or #rocess as #er needs
and s#ecification
"+ raduate will demonstrate the
skills to use modern engineering
tools software;s and eDui#ment to
analyze #ro)lems.
7+ raduate will show the a)ility to
#artici#ate and try to succeed in
com#etitive e>aminations
". Ethernet LAN #rotocol? To create
a network scenario and study the
#erformance of SMA$%
#rotocol through simulation
&. Token 'us and Token (ing#rotocols? To create a network
scenario and study the
#erformance of token )us and
token ring #rotocols through
simulation
*. +ireless LAN #rotocols? To create
a network scenario and study the
#erformance of network with
SMA$A #rotocol and com#are
with SMA$% #rotocols
,. Im#lementation and study of Sto#and +ait #rotocol
-. Im#lementation and study of o
)ack N and Selective (e#eat
#rotocols
/. Im#lementation of %istance 0ector
(outing algorithm
1. Im#lementation of Link state
routing algorithm
2. Im#lementation of data encry#tion
and decry#tion
3. Transfer of files from ! to !using +indows$ 4NI5 socket
#rocessing
8
8/10/2019 Network Simulation Lab Manual
9/85
S+R+M Un;er3#9
F/%#9 !" En5neern5 /nd Te%$n!!59
De./r#en# !" Ee%#r!n%3 /nd C!n%/#!n En5neern5
S8 C!de= EC0421 See3#er = VII
S8 T#e= Ne#6!r7 S/#!n L/8 C!r3e Te = :-De%@12
Prere3#e = N
C!re3#e = N
E>PERIMENTS DETAILS
9
S+N!+ E.eren#3 De#/ E.en#3 Rered
" Ethernet LAN #rotocol. To
create Scenario and study the
#erformance of SMA$%
#rotocol through simulation.
LAN Trainer it and three
om#uters
& Token 'us and Token (ing
#rotocols. To create scenario and
study the #erformance of token
)us and token ring #rotocols
through simulation
LAN Trainer it and three
om#uters
* +ireless LAN #rotocols. To
create scenario and study the
#erformance of network withSMA$A #rotocol and
com#are with SMA$%
#rotocols
LAN Trainer it and three
om#uters
, Im#lementation and study of
Sto# and +ait #rotocol
LAN Trainer it and three
om#uters
- Im#lementation and study of o
)ack N and Selective (e#eat#rotocols
LAN Trainer it and
om#uters
/ Im#lementation of %istance
0ector (outing algorithm
om#uters with Net Sim
Software
1 Im#lementation of Link state
routing algorithm
om#uters with Net Sim
Software
2 Im#lementation of data
encry#tion and decry#tion
Two om#uters with Net Sim
software
3 Transfer of files from ! to !
using +indows$ 4NI5 socket
#rocessing
Two om#uters with Net Sim
software
8/10/2019 Network Simulation Lab Manual
10/85
S.e%"%/#!n !" LAN Tr/ner K#
E.eren# S!"#6/re
LAN Trainer Shell C #rovides a menu driven interface to the e>#eriments. :; li)rary @ !rogramming interface to the NI4.
Stand alone #rograms for o)servation e>#eriments. Source code #rovided for study
and analysis.
Saving of e>#eriment results to a file.
%is#lay of e>#eriment activities in the a##lication window wherever a##lica)le.
,/rd6/re
Ne#6!r7 E/#!r Un# (NEU*
%ata rates? 2 "/ *& /, "&2 &-/ -"&)#s "M)#s.
To#ology? 'us (ing Star.
%elay? = . . . . "- )its )etween each #air of nodes.
Error enerators? 'it error C = to "=@/
8)etween one #air of nodes9 Frame error C = to "= @-
Nodes? / nodes #er NE4 8* !s can )e connected #er NE4.
Each ! acts as & nodes9
NE4s can )e cascaded to emulate larger networks.
Ne#6!r7 In#er"/%e Un# (NIU*
! #lug in card? ISA )us. MA Layer su##ort? ALGHA SMA SMA$% Token )us Token (ing.
Nodes? & nodes #er NI4.S93#e Rereen#3
!? !entium or higher
Gne ISA slot reDuired
"/M' (AM
G#erating System? +indows 3-
Num)er of !s? & C *
0isual com#iler? 0ersion -.= or a)ove
8G#tional C for #rogramming$modifying e>#eriments at Level & and for further
develo#ment9
EC0421 L/8!r/#!r9 P!%e3 /nd Re.!r# F!r/#
(e#orts are due at the )eginning of the la) #eriod. The re#orts are intended to )e a
com#lete documentation of the work done in #re#aration for and during the la). The
re#ort should )e com#lete so that someone else familiar with com#uter networkscould use it to verify your work. The #re la) and #ost la) re#ort format is as follows?
10
8/10/2019 Network Simulation Lab Manual
11/85
". A neat thorough #re la) must )e #resented to your Staff In charge at the )eginning
of your scheduled la) #eriod. L/8 re.!r#3 3$!d 8e 38##ed !n A4 ./.er+ Jour
re#ort is a #rofessional #resentation of your work in the la). Neatness organization
and com#leteness will )e rewarded. !oints will )e deducted for any #art that is notclear.
&. In this la)oratory students will work in teams of four. However the la) re#orts will
)e written individually. !lease use the following format for your la) re#orts.
a. C!;er P/5e= Include your name Su)7ect ode Section No. E>#eriment
No. and %ate.
).O8e%#;e3= Enumerate * or , of the to#ics that you think the la) will teach
you. There should )e one or two sentences #er o)7ective. (emem)er you should write
a)out what you will learn not what you will do.
c.C!n"5r/#!n= This #art contains the configuration details of the node used
for the simulation. This should include onfiguration menu ta)le where the values of
network simulation #arameters ty#e of #rotocols used are given here. T$3 3e%#!n
3$!d /3! n%de / %e/r 6r##en de3%r.#!n !" 9!r 3/#!n .r!%e33+ Sim#ly
including a configuration ta)le is not sufficient.
d. S/#!n Re3#3=The analysis of the given #rotocol is studied with the
hel# of simulation results. 4se the necessary formulas to study the #erformance of the
given #rotocol and draw necessary #lots with the o)tained results. The model gra#h
should also )e given .Make sure that the neat gra#h must )e drawn for the o)tained
results.
e. e3#!n3= S#ecific Duestions 8!re la) and !ost la)9 asked in the la) should)e answered here. Re#9.e #$e e3#!n3 .re3en#ed n #$e /8 /nd #$en "!r/9
/n36er #$e+
*. Jour work must )e original and #re#ared inde#endently. However if you need any
guidance or have any Duestions or #ro)lems #lease do not hesitate to a##roach your
faculty in charge during office hours. o#ying any #re la) $#ost la) will result in a
grade of =. The incident will )e formally re#orted to the 4niversity and the students
should follow the dress code in the La) session.
,. Each la)oratory e>#eriment must )e com#leted and demonstrated to your faculty incharge in order to receive working module credit. This is the #rocedure to follow?
a. E>#ected simulation results o)tained? If the e>#eriment is com#leted with
e>#ected simulation results during the la) #eriod 8* hours9 call your
Staff in charge and he$she will sign and date it. This is the end of this la) and you
will
get a com#lete grade for this #ortion of the la).
). No E>#ected simulation results? If the e>#eriment is done )ut not with
e>#ected results you must make use of the o#en times for the la) room to com#lete
your e>#eriment. +hen your simulation results are correct contact your staff in
charge to set u# a time when the two of you can meet to check your results.
11
8/10/2019 Network Simulation Lab Manual
12/85
-. Attendance at your regularly scheduled la) #eriod is reDuired. An une>#ected
a)sence will result in loss of credit for your la). If for valid reason a student misses a
la) or makes a reasona)le reDuest in advance of the class meeting it is #ermissi)le
for the student to do the la) in a different section later in the week if a##roved )y the
staff in charge of )oth the sections. Ha)itually late students 8i.e. students late morethan "- minutes more than once9 will receive "= #oint reductions in their grades for
each occurrence following the first.
/. Final grade in this course will )e )ased on la)oratory assignments. All la)s have an
eDual weight in the final grade. rading will )e )ased on #re@la) work la)oratory
re#orts #ost@la) and in@la) #erformance 8i.e. com#leting la) answering la)oratory
related Duestions etc.9.The faculty in charge will ask #ertinent Duestions to individual
mem)ers of a team at random. La)s will )e graded as #er the following grading
#olicy?
!re@La) +ork "=.==K
In@La) !erformance &=.==K
!ost La) +ork "=.==K
La)oratory (e#ort "=.==K
2. Re.!r#3 De D/#e3? (e#orts are due one week after com#letion of the
corres#onding la).
3. S93#e3 !" Te3#3=(egular la)oratory class work over the full semester will carry a
weightage of 1-K. The remaining &-K weightage will )e given )y conducting an end
semester #ractical e>amination for every individual student if #ossi)le or )yconducting a " to " hours duration common written test for all students )ased on all
the e>#eriment carried out in the semester.
10+ Gener/ Pr!%edre=
a. !ro#erly #lace the #atch cord in its res#ective #osition for good internal connection
in the trainer kit
). Make sure with the connection of #atch cords in the trainer kit in res#ect to the
e>#eriment concerned.
c. %o not meddle with the trainer kit
d. (un the %iagnostics #rocedure from one of the !s connected to the NE4.e. The driver file name and #ath 8?Lantrain'inLANT0"*.e>e9 should not )e
changed.
f. lick (eset )utton to reset NI4
g. (e#eat the a)ove ste#s from 8d to f9 to other !s 8one ! at a time9 connected to
NE4 to confirm the LAN@T working.
h. Set u# the )it delay and )it error rate according to the e>#eriment reDuirement.
SRM UNIVERSITYDe./r#en# !" Ee%#r!n%3 /nd C!n%/#!n En5neern5
EC0421 Ne#6!r7 S/#!n L/8L/8!r/#!r9 Re.!r# C!;er S$ee#
12
8/10/2019 Network Simulation Lab Manual
13/85
ODD SEM - 2010
Name?
Section? Tick Gne M 8 9 T4 8 9 + 8 9 Th 8 9 Fr 8 9
0enue? Networking La)
Title of La)? E=,&" Network Simulation La)
Pre./r/#!n Ver"%/#!n
Staff Name 6 Signature?
E.eren# C!.e#!n Ver"%/#!n
Staff Name 6 Signature?
%ate Time?
P/r#%/r3 M/ M/r73 M/r73 O8#/ned
!re@la) +ork "=
La) !rocedure &=
!ost la) +ork "=
La) (e#ort "=
Total -=
Re.!r# Ver"%/#!n
Staff Name 6 Signature?
%ate Time?
LAN Tr/ner KIT O.er/#!n
13
8/10/2019 Network Simulation Lab Manual
14/85
F5re 1+1? om#onents in the LAN Trainer
In#r!d%#!n #! #$e LAN Tr/ner?
To successfully use the LAN Trainer a num)er of hardware and software com#onents must )e
#ro#erly used together 8see Fig. "."9. Each ! acts as two nodes in the network. 'oth areconnected to the Network Emulator 4nit via the same ca)le. Thus with * !s you can
e>#eriment with a /@node network. Gn the software side the screen is divided into & windows
one for each node. This is accom#lished using the LAN Trainer control #anel running under
+indows C 3-
NIU C/rd? Each ! that is #art of the LAN Trainer setu# must have an NI4 ard #lugged into it.Ne#6!r7 E/#!r Un#
The Network Emulator 4nit acts as a network interconnecting u# to / network nodes 8* NI4
ards in * !s9. Each card is connected to the Network Emulator 4nit via a ca)le with %'@*1
connectors. Gnce #ro#erly installed these should not normally )e distur)ed. The Network
Emulator 4nit has a num)er of 7um#ers that must )e #ro#erly wired@u# de#ending on the ty#e of
network one wants @ a )us a ring or a star. This must corres#ond to the setting of the To#ologyselector switch. The Network Emulator 4nit also has selector switches for %ata (ate 'it %elay
Error (ate and Frame Error (ate. These should )e set in accordance with the instructions of each
e>#eriment. In addition there is a (eset switch which should )e used )efore every e>#eriment
and in case of trou)le.
CONTENTSL/8 1+ S#d9 !" E#$erne# LAN Pr!#!%! CSMACD
14
8/10/2019 Network Simulation Lab Manual
15/85
"." Introduction
".& Hardware (eDuirement
".* 'ackground
"., !re la)
".- La) !rocedure
"./ !ost la)
L/8 2= S#d9 !" T!7en Rn5 /nd T!7en B3 Pr!#!%!3
&." Introduction
&.& Hardware (eDuirement
&.* 'ackground
&., !re la)
&.- La) !rocedure&.-." Token 'us
&.-.& Token (ing
&./ !ost la)
L/8 = S#d9 !" Wree33 LAN .r!#!%! CSMACA
*." Introduction
*.& Hardware (eDuirement
*.* 'ackground
*., !re la)
*.- La) !rocedure
*./ !ost la)
L/8 4= I.een#/#!n /nd 3#d9 !" S#!. /nd W/# Pr!#!%!3
,." Introduction
,.& Hardware (eDuirement
,.* 'ackground
,., !re la),.- La) !rocedure
,./ !ost la)
L/8 = I.een#/#!n /nd 3#d9 !" G! 8/%7 N /nd See%#;e Re.e/#
Pr!#!%!
-." Introduction
-.& Hardware (eDuirement
-.* 'ackground
-., !re la)
15
8/10/2019 Network Simulation Lab Manual
16/85
-.- La) !rocedure
-.-." o 'ack N #rotocol
-.-.& Selective (e#eat !rotocol
-./ !ost la)
L/8 )= I.een#/#!n !" D3#/n%e Ve%#!r R!#n5 /5!r#$
/." Introduction
/.& Hardware (eDuirement
/.* 'ackground
/., !re la)
/.- La) !rocedure
/./ !ost la)
L/8 = I.een#/#!n !" Ln7 S#/#e R!#n5 A5!r#$
1." Introduction
1.& Hardware (eDuirement
1.* 'ackground
1., !re la)
1.- La) !rocedure
1./ !ost la)
L/8H= I.een#/#!n !" d/#/ en%r9.#!n /nd de%r9.#!n2." Introduction2.& Hardware (eDuirement
2.* 'ackground
2., !re la)
2.- La) !rocedure
2./ !ost la)
L/8'= Tr/n3"er !" "e3 "r! PC #! PC 3n5 Wnd!63 UNI> 3!%7e#
.r!%e33n5
3." Introduction3.& Hardware (eDuirement
3.* 'ackground
3., !re la)
3.- La) !rocedure
3./ !ost la)
A..end
L/8 1= S#d9 !" E#$erne# LAN Pr!#!%! CSMACD
16
8/10/2019 Network Simulation Lab Manual
17/85
1+1 In#r!d%#!n?
The #ur#ose of this e>#eriment is to understand the conce#t of Listen@while@transmit to
im#rove efficiency. In this la) you will )e a)le to im#lement the SMA$% #rotocol for
#acket communication )etween a num)er of nodes connected to a common )us.
1+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit
#onential )ack off.
1+4 Pre /8 e3#!n3
". %efine network to#ology and list the ty#es with the advantages and disadvantages.
&. +hich media access method is used in EthernetO
*. +hich GSI Layer includes the SMA$% mechanismO
,. How is the collision occurrence intimated to other nodes in a networkO
-. %efine through#ut+
17
http://www.webopedia.com/TERM/C/network.htmhttp://www.webopedia.com/TERM/C/device.htmhttp://www.webopedia.com/TERM/C/channel.htmhttp://www.webopedia.com/TERM/C/Ethernet.htmhttp://www.webopedia.com/TERM/C/network.htmhttp://www.webopedia.com/TERM/C/device.htmhttp://www.webopedia.com/TERM/C/channel.htmhttp://www.webopedia.com/TERM/C/Ethernet.htm8/10/2019 Network Simulation Lab Manual
18/85
1+ Pr!%edre=
18
8/10/2019 Network Simulation Lab Manual
19/85
19
8/10/2019 Network Simulation Lab Manual
20/85
20
8/10/2019 Network Simulation Lab Manual
21/85
21
8/10/2019 Network Simulation Lab Manual
22/85
1+) P!3# /8 e3#!n3=
". alculate the through#ut for a network with )andwidth "= M)#s which can #ass at an
average of "&=== frames $min each carrying "==== )its.
&. +hat are the draw)acks of SMA$% #rotocolO
*. an a node transmit #ackets during )ack@off #eriodO +hyO
,. How to overcome the draw)acks of SMA$%O
22
8/10/2019 Network Simulation Lab Manual
23/85
L/8 2= S#d9 !" T!7en Rn5 /nd T!7en B3 .r!#!%!
2+1 In#r!d%#!n?
The #ur#ose of this e>#eriment is to understand the conce#t of demand assignment versus
random access setting #riorities and token management in a ring and )us LAN .In this la)
you will )e a)le to im#lement a token C#assing access method for a ring and )us LAN.
2+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit
t with a control
token circulating around the ring controlling access..!hysically a token ring network is
wired as a star with Phu)sP and arms out to each station and the loo# going out@and@)ack
through each.
Each station #asses or repeatsthe s#ecial token frame around the ring to its nearest
downstream neigh)or. This token@#assing #rocess is used to ar)itrate access to the shared
ring media. Stations that have data frames to transmit must first acDuire the token )efore
they can transmit them. Token ring LANs normally use differential Manchester encoding
of )its on the LAN media.
+hen no station is transmitting a data frame a s#ecial token frame circles the loo#.
This s#ecial token frame is re#eated from station to station until arriving at a station that
needs to transmit data. +hen a station needs to transmit data it converts the token frame
into a data frame for transmission. Gnce the sending station receives its own data frame it
converts the frame )ack into a token
23
http://en.wikipedia.org/wiki/Local_area_networkhttp://en.wikipedia.org/wiki/Network_protocolhttp://en.wikipedia.org/wiki/Data_link_layerhttp://en.wikipedia.org/wiki/OSI_modelhttp://en.wikipedia.org/wiki/Ring_networkhttp://en.wikipedia.org/wiki/Star_networkhttp://en.wikipedia.org/wiki/Differential_Manchester_encodinghttp://en.wikipedia.org/wiki/Local_area_networkhttp://en.wikipedia.org/wiki/Network_protocolhttp://en.wikipedia.org/wiki/Data_link_layerhttp://en.wikipedia.org/wiki/OSI_modelhttp://en.wikipedia.org/wiki/Ring_networkhttp://en.wikipedia.org/wiki/Star_networkhttp://en.wikipedia.org/wiki/Differential_Manchester_encoding8/10/2019 Network Simulation Lab Manual
24/85
T!7en 83is a network im#lementing the token ring#rotocol over a Qvirtual ringQ on
acoa>ial ca)le. A token is #assed around the network nodes and only the node #ossessing
the token may transmit. If a node doesnPt have anything to send the token is #assed on to
the ne>t node on the virtual ring. Each node must know the address of its neigh)our in the
ring so a s#ecial #rotocol is needed to notify the other nodes of connections to and
disconnections from the ring.
2+4 Pre L/8 e3#!n3
". +hat is meant )y )ack)one in a networkO
&. +hat is meant )y token and how is it used in ring methodologyO
*. ive the advantages of token ring over Ethernet.
,. %efine Token Holding Timer 8THT9.
-. ive the IEEE standard of token ring and token )us LAN.
2+ Pr!%edre
2++1 T!7en B3
". lick on the Token 'us icon twice from the deskto#.
&. lick the onfiguration )utton in the window in )oth the !;s.
Setting the onfigurations Menu for Token 'us
24
http://en.wikipedia.org/wiki/Token_ringhttp://en.wikipedia.org/wiki/Coaxial_cablehttp://en.wikipedia.org/wiki/Token_ringhttp://en.wikipedia.org/wiki/Coaxial_cable8/10/2019 Network Simulation Lab Manual
25/85
".If you connect two !;s and configured four nodes then set the My Address as = to * in all
four nodes if you connect three !s and configured si> nodes then set the My Address as =to
- in all si> nodes.
&.Start running the e>#eriment from the lowest #riority node 8i.e. from My Address * in case
of
four nodes and - in the case of si> nodes9
*. No of Nodes has to )e set as , when two !s are connected and / when three !s are
connected.
is the generated load in the network.
N is the num)er of nodes #artici#ating in the network. For e>am#le let us say that , nodes
8using & com#uters9
! is the #acket length e>#ressed in )itsB say "== )ytes 82== )its9.
is the data rate normally set as 2k)s which is selected in the NE4.
tais the inter #acket delay e>#ressed in secondsB the time interval )etween two consecutive
#ackets generated.
So lets assume taR ,= milliseconds and su)stitute the a)ove mentioned #arameters in the
EDuation A which leads to R "=. Like wise assume various values of tato generate offer
loads in the range of =." to "=. Su)stitute the value of ta in the configuration menu.
25
8/10/2019 Network Simulation Lab Manual
26/85
*. lick G )utton and %ownload the driver to the NI4 using the 'GGT )utton
command.
'ooting from any one of the a##lications is enough.
,. (un the e>#eriment )y clicking )utton or )y choosing (4N Start from each
a##lication.
(un the all the e>#eriments at the same time.
Note? +hile you do this THT window #o#s u# enter the THT time in all nodes and #ress the
G
)utton first in the node which has the lowest #riority of My Address.-. Set the Token Holding Time 8THT9 8say "==== ms9.
/. 0iew the statistics window for results. To view the statistics window click on )utton.
1. Note down the readings once the e>#eriment is com#leted.
2. (e#eat the a)ove ste#s for various values of ta
3. alculate the !ractical offered load from the )elow given formula and #lot the gra#h
)etween
the #ractical Gffered load and Through#ut.
Note? Jou can also use the tem#late for #lotting the gra#h. !lease refer A##endi>@" to #lot the
gra#h using the tem#late.
"=. (e#eat the e>#eriment for various values of !acket length Node %ata rate.
"". (e#eat the a)ove ste#s while running the e>#eriment set the 'E( to "=@& in the NE4 or
try to sto# one of the nodes and o)serve the )ehavior and e>#lain the same.
alculations of !ractical Through#ut from the o)tained readings
26
8/10/2019 Network Simulation Lab Manual
27/85
alculations of Gffered Load
C Gffered loadN C Num)er of nodes
! C !acket length in )its
C %ata rate in )its$sec
ta@Inter #acket delay in millisecs.
Model Ta)ulations
Model ra#h
2++2 T!7en Rn5
27
8/10/2019 Network Simulation Lab Manual
28/85
8/10/2019 Network Simulation Lab Manual
29/85
EDuation A which leads to R "=. Like wise assume various values of ta to generate offer
loads in the range of =." to "=. Su)stitute the value of ta in the configuration menu.
*. lick G )utton and %ownload the driver to the NI4 using the 'GGT )uttoncommand.
'ooting from any one of the a##lications is enough.
,. (un the e>#eriment )y clicking )utton or )y choosing (4N Start from each
a##lication.
(un the all the e>#eriments at the same time.
-. Set the Token Holding Time 8THT9 8say "==== ms9.
/. 0iew the statistics window for results. To view the statistics window click on )utton
.
1. Note down the readings once the e>#eriment is com#leted.
2. (e#eat the a)ove ste#s for various values of ta.
3. alculate the !ractical offered load from the )elow given formula and #lot the gra#h
)etween
the #ractical Gffered load and Through#ut.
Note? Jou can also use the tem#late for #lotting the gra#h.
"=. (e#eat the e>#eriments for various values of !acket length Node %ata rate.
"". (e#eat the a)ove ste#s while running the e>#eriment set the 'E( to "=@& in the NE4 or
try
to sto# one of the nodes and o)serve the )ehavior and e>#lain the same.
29
8/10/2019 Network Simulation Lab Manual
30/85
alculation of !ractical Through#ut 859 from the o)tained readings?
alculation of the Gffered load?
C Gffered load
N C Num)er of nodes
! C !acket length in )its
C %ata rate in )its$sec
ta C Inter #acket delay in millisecs.
Model Ta)ulation?
Model ra#h
30
8/10/2019 Network Simulation Lab Manual
31/85
8/10/2019 Network Simulation Lab Manual
32/85
a nodewishing to transmit data has to first listen to the channel for a #redetermined
amount of time to determine whether or not another node is transmitting on the
channel within the wireless range. If the channel is sensed QidleQ then the node is
#ermitted to )egin the transmission #rocess. If the channel is sensed as Q)usyQ the
node defers its transmission for a random #eriod of time. Gnce the transmission
#rocess )egins it is still #ossi)le for the actual transmission of a##lication data to not
occur.
CSMACA is a modification of #ure arrier Sense Multi#le Access 8CSMA9. ollision
avoidance is used to im#rove CSMA#erformance )y not allowing wireless transmission of a
node if another node is transmitting thus reducing the #ro)a)ility of collision due to the use
of a random time. G#tionally )ut almost always im#lemented an IEEE 2=&."" (TS$TS
e>change can )e reDuired to )etter handle situations such as the hidden node#ro)lem in
wireless networking.
SMA$A is a layer & access method not a #rotocol of the GSI model. A nodewishing to
send data initiates the #rocess )y sending a (eDuest to Send frame8(TS9. The destination
node re#lies with a lear to send frame 8TS9. Any other node receiving the (TS or TS
frame should refrain from sending data for a given time 8solving the hidden node #ro)lem9.
The amount of time the node should wait )efore trying to get access to the medium is
included in )oth the (TS and the TS frame. This #rotocol was designed under the
assum#tion that all nodes have the same transmission range.
(TS$TS is an additional method to im#lement virtual carrier sensing in arrier sense
multi#le access with collision avoidance 8SMA$A9. 'y default 2=&.""relies onphysical
carrier sensingonly which is known to suffer from thehidden terminal #ro)lem.
(TS$TS #acket size threshold is =@&*,1 octets.Ty#ically sending (TS$TS frames does not
occur unless the #acket size e>ceeds this threshold. If the #acket size the node wants to
transmit is larger than the threshold the (TS$TS handshake gets triggered. Gtherwise the
data frame gets sent immediately. (TS$TS #ackets carry the e>#ected duration of the data
transmission which will have some im#lications.
+4 Pre /8 e3#!n3
32
http://en.wikipedia.org/wiki/Node_(networking)http://en.wikipedia.org/wiki/Carrier_sense_multiple_accesshttp://en.wikipedia.org/wiki/Collision_(telecommunications)http://en.wikipedia.org/wiki/IEEE_802.11_RTS/CTShttp://en.wikipedia.org/wiki/Hidden_nodehttp://en.wikipedia.org/wiki/Wireless_networkinghttp://en.wikipedia.org/wiki/Node_(networking)http://en.wikipedia.org/wiki/Frame_(networking)http://en.wikipedia.org/wiki/Hidden_node_problemhttp://en.wikipedia.org/wiki/Carrier_sense_multiple_access_with_collision_avoidancehttp://en.wikipedia.org/wiki/Carrier_sense_multiple_access_with_collision_avoidancehttp://en.wikipedia.org/wiki/802.11http://en.wikipedia.org/wiki/Hidden_terminal_problemhttp://en.wikipedia.org/wiki/Octetshttp://en.wikipedia.org/wiki/Node_(networking)http://en.wikipedia.org/wiki/Carrier_sense_multiple_accesshttp://en.wikipedia.org/wiki/Collision_(telecommunications)http://en.wikipedia.org/wiki/IEEE_802.11_RTS/CTShttp://en.wikipedia.org/wiki/Hidden_nodehttp://en.wikipedia.org/wiki/Wireless_networkinghttp://en.wikipedia.org/wiki/Node_(networking)http://en.wikipedia.org/wiki/Frame_(networking)http://en.wikipedia.org/wiki/Hidden_node_problemhttp://en.wikipedia.org/wiki/Carrier_sense_multiple_access_with_collision_avoidancehttp://en.wikipedia.org/wiki/Carrier_sense_multiple_access_with_collision_avoidancehttp://en.wikipedia.org/wiki/802.11http://en.wikipedia.org/wiki/Hidden_terminal_problemhttp://en.wikipedia.org/wiki/Octets8/10/2019 Network Simulation Lab Manual
33/85
". +hat is the difference )etween SMA$% and SMA$AO
&. +hat are hidden terminal #ro)lem and e>#osed terminal #ro)lemO
*. +hat is %FO
,. +hat is the use of (TS$TS handshake #rotocolO
-. +hat is random )ack off algorithmO
+ Pr!%edre
Ste#s to configure (eceiver?
". lick on the SMA$A icon from the deskto# on one !.
&. lick the onfiguration )utton.
33
8/10/2019 Network Simulation Lab Manual
34/85
34
8/10/2019 Network Simulation Lab Manual
35/85
35
8/10/2019 Network Simulation Lab Manual
36/85
36
8/10/2019 Network Simulation Lab Manual
37/85
37
8/10/2019 Network Simulation Lab Manual
38/85
38
8/10/2019 Network Simulation Lab Manual
39/85
39
8/10/2019 Network Simulation Lab Manual
40/85
40
8/10/2019 Network Simulation Lab Manual
41/85
+) P!3# /8 e3#!n3
". +hat is NA0O
&. +hat do you mean )y e>#onential )ack off algorithmO
*. Fragment a "=== )yte #acket into five &== )ytes #acket and com#are the through#ut
o)tained with single "=== )yte #acket transmission
,. In what situations can collision occur in +LAN networkO How to solve the collisions or
minimize the #ro)a)ility of collisionsO
-. +hat is the choice of contention windowO
41
8/10/2019 Network Simulation Lab Manual
42/85
L/8 4= I.een#/#!n /nd 3#d9 !" S#!. /nd W/# Pr!#!%!3
4+1 In#r!d%#!n?
The #ur#ose of this e>#eriment is to introduce you to the )asics of error correction time
outs and state machines. In this la) you will )e a)le to #rovide relia)le data transfer )etween
two nodes over an unrelia)le network using the sto#@ and@wait #rotocol.
4+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit t one. In this way the
sender can recognize that the #revious #acket is transmitted successfully and we could say
Qsto#@n@waitQ guarantees relia)le transfer )etween nodes. To su##ort this feature the sender
kee#s a record of each #acket it sends. Also to avoid confusion caused )y delayed or
du#licated As Qsto#@n@waitQ send each #acket with uniDue seDuence num)ers and receive
that num)ers in each A. If the sender doesnPt receive A for #revious sent #acket after a
certain #eriod of time the sender times out and retransmits that #acket again. There are two
cases when the sender doesnPt receive AB Gne is when the A is lost and the other is
when the frame itself is not transmitted. To su##ort this feature the sender kee#s timer #er
each #acket.
4+4 Pre /8 e3#!n3
". +hat are the functions of data link layerO
&. +hat is the need for flow control techniDuesO
*. E>#lain the mechanism of sto# and wait flow control techniDue.
,. In what situations does the sender retransmit a #acketO
42
8/10/2019 Network Simulation Lab Manual
43/85
-. +hat is meant )y #romiscuous modeO
4+ Pr!%edre=
". lick on the Sto# 6 +ait icon from the deskto# on )oth !s.
&. lick the onfiguration )utton in the window in )oth the !c;s.
Setting the configuration menu?
*. Set the Inter !acket %elay to ,==msecs
,. lick G )utton and %ownload the driver to the NI4 using the 'GGT )utton
command. 'ooting from any one of the a##lications is enough.
43
8/10/2019 Network Simulation Lab Manual
44/85
-. (un the e>#eriment )y clicking )utton or )y choosing (4N Start from each
a##lication.
/. Set the Timeout 0alue to "-== ms
1. Note down the no of successfully Transmitted !ackets.
2. (e#eat the a)ove ste#s for various time out values and #lot the gra#h )etween timeout
0alue 6Through#ut. Find the o#timum timeout value from the #lot.
3. E>#lain why the through#ut is less com#ared to SMA% #rotocol.
alculation of !ractical Through#ut?
Model Ta)ulation?
44
8/10/2019 Network Simulation Lab Manual
45/85
M!de Gr/.$?
4+) P!3# /8 e3#!n3
". om#uter A uses sto# and wait A( #rotocol to send #ackets to com#uter '. If the
distance )etween A and ' is ,===km how long does it take com#uter A to receive
acknowledgement for a #acketO 4se the s#eed of light for #ro#agation s#eed and assume
the time )etween receiving and sending the acknowledgement is zero.
&. +hy there is no need to num)er the acknowledgements in sto# and wait A(O
*. For the Duestion no" how long it takes for com#uter A to send out a #acket of size
"===)ytes if the through#ut is "=====k)#sO
L/8 = I.een#/#!n /nd 3#d9 !" G! 8/%7 N /nd See%#;e Re.e/#
45
8/10/2019 Network Simulation Lab Manual
46/85
Pr!#!%!
+1 In#r!d%#!n?
The #ur#ose of this e>#eriment is to introduce you to the )asics of error correction time
outs and state machines. In this la) you will )e a)le to #rovide relia)le data transfer )etween
two nodes over an unrelia)le network using o )ack N and selective re#eat #rotocol.
+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit
8/10/2019 Network Simulation Lab Manual
47/85
or damaged then that frame and all following frames in the window 8even if they were
received without error9 will )e re@sent. To avoid thisSelective (e#eat A(can )e used.
See%#;e Re.e/# AR See%#;e Ree%# AR is a s#ecific instance of the
Automatic (e#eat@reDuest 8A(9!rotocol. It may )e used as a #rotocol for the delivery and
acknowledgement of message units or it may )e used as a #rotocol for the delivery of
su)divided message su)@units.
+hen used as the #rotocol for the delivery of e33/5e3 the sending #rocess continues to
send a num)er of framess#ecified )y a window sizeeven after a frame loss. 4nlike o@'ack@
N A( the receiving #rocess will continue to acce#t and acknowledgeframes sent after an
initial errorB this is the general case of the sliding window #rotocolwith )oth transmit andreceive window sizes greater than ".
The receiver #rocess kee#s track of the seDuence num)er of the earliest frame it has not
received and sends that num)er with every Ait sends. If a frame from the sender does not
reach the receiver the sender continues to send su)seDuent frames until it has em#tied its
window. The receiver continues to fill its receiving window with the su)seDuent frames
re#lying each time with an A containing the seDuence num)er of the earliest missing
frame. Gnce the sender has sent all the frames in its window it re@sends the frame num)er
given )y the As and then continues where it left off.
The size of the sending and receiving windows must )e eDual and half the ma>imum
seDuence num)er 8assuming that seDuence num)ers are num)ered from = to nV"9 to avoid
miscommunication in all cases of #ackets )eing dro##ed. To understand this consider the
case when all As are destroyed. If the receiving window is larger than half the ma>imum
seDuence num)er some #ossi)ly even all of the #ackages that are resent after timeouts aredu#licates that are not recognized as such. The sender moves its window for every #acket that
is acknowledged.
+hen used as the #rotocol for the delivery of su)divided messages it works somewhat
differently. In non@continuous channels where messages may )e varia)le in length standard
A( or Hy)rid A( #rotocols may treat the message as a single unit. Alternately selective
retransmission may )e em#loyed in con7unction with the )asic A( mechanism where the
message is first su)divided into su)@)locks 8ty#ically of fi>ed length9 in a #rocess called
47
http://en.wikipedia.org/wiki/Selective_Repeat_ARQhttp://en.wikipedia.org/wiki/Automatic_repeat-requesthttp://en.wikipedia.org/wiki/Data_framehttp://en.wikipedia.org/wiki/Go-Back-N_ARQhttp://en.wikipedia.org/wiki/Go-Back-N_ARQhttp://en.wikipedia.org/wiki/ACK_(computing)http://en.wikipedia.org/wiki/Sliding_Window_Protocolhttp://en.wikipedia.org/wiki/ACK_(computing)http://en.wikipedia.org/wiki/Data_framehttp://en.wikipedia.org/wiki/Selective_Repeat_ARQhttp://en.wikipedia.org/wiki/Automatic_repeat-requesthttp://en.wikipedia.org/wiki/Data_framehttp://en.wikipedia.org/wiki/Go-Back-N_ARQhttp://en.wikipedia.org/wiki/Go-Back-N_ARQhttp://en.wikipedia.org/wiki/ACK_(computing)http://en.wikipedia.org/wiki/Sliding_Window_Protocolhttp://en.wikipedia.org/wiki/ACK_(computing)http://en.wikipedia.org/wiki/Data_frame8/10/2019 Network Simulation Lab Manual
48/85
!acket segmentation. The original varia)le length message is thus re#resented as a
concatenation of a varia)le num)er of su)@)locks. +hile in standard A( the message as a
whole is either acknowledged 8Aed9 or negatively acknowledged 8NAed9 in A( with
selective transmission the NAed res#onse would additionally carry a )it flag indicating the
identity of each su)@)lock successfully received. In A( with selective retransmission of
su)@divided messages each retransmission diminishes in length needing to only contain the
su)@)locks that were NAed.
In most channel models with varia)le length messages the #ro)a)ility of error@free rece#tion
diminishes in inverse #ro#ortion with increasing message length. In other words itPs easier to
receive a short message than a longer message. Therefore standard A( techniDues involving
varia)le length messages have increased difficulty delivering longer messages as each re#eat
is the full length. Selective retransmission a##lied to varia)le length messages com#letely
eliminates the difficulty in delivering longer messages as successfully delivered su)@)locks
are retained after each transmission and the num)er of outstanding su)@)locks in following
transmissions diminishes.
+4 Pre /8 e3#!n3
". E>#lain the mechanism of o )ack N A(.
&. In sliding window flow control if the window size is /* what is the range of seDuence
num)ersO
*. For a sliding window of size n@" 8n@seDuence num)ers9 there can )e a ma>imum of @@@@@@@
frames sent )ut unacknowledged.
,. %ifferentiate )etween )it rate and )aud rate.
-. E>#lain the mechanism of selective re#eat A(./. om#are selective re#eat and o)ack N A( schemes.
+ Pr!%edre=
++1 G! B/%7 N Pr!#!%!
". lick on the Sliding +indow 'N icon from the deskto# on )oth !s.
48
http://en.wikipedia.org/wiki/Packet_segmentationhttp://en.wikipedia.org/wiki/Packet_segmentation8/10/2019 Network Simulation Lab Manual
49/85
&. lick the onfiguration )utton in the window in )oth the !c;s.
Setting the configuration menu?
Note? The No of !ackets #arameter defines the window size.
*. Set the Inter !acket %elay to ,==msecs
,. lick G )utton and %ownload the driver to the NI4 using the 'GGT )utton
command.'ooting from any one of the a##lications is enough.
-. (un the e>#eriment )y clicking )utton or )y choosing (4N Start from each
a##lication.
49
8/10/2019 Network Simulation Lab Manual
50/85
/. Set the Timeout 0alue to "-== ms
1. Note down the no of successfully Transmitted !ackets.
2. (e#eat the a)ove ste#s for various time out values and #lot the gra#h )etween timeout
0alue 6Through#ut. Find the o#timum timeout value from the #lot.3. E>#lain why the through#ut is less com#ared to SMA% #rotocol.
alculation of !ractical Through#ut?
M!de T/8/#!n?
G!?B/%7 N Pr!#!%!
50
8/10/2019 Network Simulation Lab Manual
51/85
M!de Gr/.$=
G!?B/%7 N Pr!#!%!
++2 See%#;e Re.e/# Pr!#!%!
". lick on the Selective (e#eat icon from the deskto# on )oth !s.
&. lick the onfiguration )utton in the window in )oth the !c;s.
51
8/10/2019 Network Simulation Lab Manual
52/85
Setting the configuration menu?
Note? The No of !ackets #arameter defines the window size.
*. Set the Inter !acket %elay to ,==msecs
,. lick G )utton and %ownload the driver to the NI4 using the 'GGT )utton
command.'ooting from any one of the a##lications is enough.
-. (un the e>#eriment )y clicking )utton or )y choosing (4N Start from each
a##lication.
52
8/10/2019 Network Simulation Lab Manual
53/85
/. Set the Timeout 0alue to "=== ms
1. Note down the no of successfully Transmitted !ackets.
2. (e#eat the a)ove ste#s for various time out values and #lot a gra#h )etween timeout 0alue
6 Through#ut. Find the o#timum timeout value from the #lot.
alculation of !ractical Through#ut?
Model Ta)ulation?
53
8/10/2019 Network Simulation Lab Manual
54/85
M!de Gr/.$=
See%#;e Re.e/# Pr!#!%!
+) P!3# /8 e3#!n3
". %raw the sender and receiver windows for a system using o@)ack@N A( given the
following .a. Frame = is sent frame = is acknowledged.
). Frames " and & are sent frames " and & are acknowledged.
c. Frame *, and - are sent NA, is received.
d. Frame ,-/ and 1 are sentB frames, through 1 are acknowledged.
&. A sliding window #rotocol uses a sliding window of size"-. How many )its are needed to
define the seDuence num)ersO
*. %raw the sender and receiver windows for a system using selective re#eat A( given the
following.
a. Frame = is sent frame = is acknowledged.
). Frames " and & are sent frames " and & are acknowledged.
c. Frame *, and - are sent NA, is received.d. Frame , -/ and 1 are sentB frames, through 1 are acknowledged.
,.
= " & * , - / 1 2 3 "= "" "& "* ", "- = " & *
a. Show the window after the sender has sent #ackets = to "" and has receivedA2.
54
8/10/2019 Network Simulation Lab Manual
55/85
). The receiver has sent A/ and A3 )ut A/ is lost. Show the sender
window.
L/8 )= I.een#/#!n !" D3#/n%e Ve%#!r R!#n5 /5!r#$
)+1 In#r!d%#!nTo simulate the distance vector routing #rotocol to maintain routing ta)lesas the traffic and to#ology of the network changes
)+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit
t@ho# router. For e>am#le Q%estination A is a distance of - ho#s away in
the direction of ne>t@ho# router 5.Q As that statement im#lies each router learns routes from
its neigh)oring routersP #ers#ectives and then advertises the routes from its own #ers#ective.
'ecause each router de#ends on its neigh)ors for information which the neigh)ors in turnmay have learned from their neigh)ors and so on distance vector routing is sometimes
facetiously referred to as Qrouting )y rumor.Q
The common haracteristics are
Periodic Updates
Periodic updatesmeans that at the end of a certain time #eriod u#dates will )e transmitted.
Neighbors
In the conte>t of routers neighborsalways mean routers sharing a common data link.
Broadcast Updates
+hen a router first )ecomes active on a network how does it find other routers and how does
it announce its own #resenceO Several methods are availa)le.
Full Routing Table Updates
55
8/10/2019 Network Simulation Lab Manual
56/85
Most distance vector routing #rotocols take the very sim#le a##roach of telling their
neigh)ors everything they know )y )roadcasting their entire route ta)le with some
e>ce#tions that are covered in following sections.
S.# ,!r
A route #ointing )ack to the router from which #ackets were received is called a reverse
route. Split horizonis a techniDue for #reventing reverse routes )etween two routers.
)+4 Pre/8 e3#!n3
". +hat is (outingO
&. %escri)e a)out the %esign oals of (outing
3. +hat is a distance vector routing #rotocolO,. List the common characteristics of %0(
)+ Pr!%edre=
". %ou)le click on LanT (outing Simulator icon from the deskto#.
&. lick )utton and )rowse o#en ?Lantrainonfig linear.t>t.
*. lick )utton and select %istance vector algorithm
,. The icon in the screen re#resents the nodes and the green colour line re#resents the #ath.
The values inside the )races re#resents the :Forward and (everse; weights.
56
8/10/2019 Network Simulation Lab Manual
57/85
-. lick on the node icon to o)tain the routing ta)le.
/. The a)ove #icture shows the nodes and its routing ta)le.
57
8/10/2019 Network Simulation Lab Manual
58/85
1. G)serve the routing ta)le showing No route to some of the destinations even though there
is a #hysical connection. This is )ecause the routing ta)le of the corres#onding nodes is not
)een u#dated since there is no ho##ing. To u#date the routing ta)le click )utton .
2. Ho##ing ha##ens )y clicking )utton.
58
8/10/2019 Network Simulation Lab Manual
59/85
3. Now after several ho##ing the routing ta)le gets u#dated. As the num)er nodes increases
the num)er of ho##ing increases. This is one of the disadvantages of distance vector
algorithm.
C!n# #! In"n#9 .r!8e
"=. lick the green colour line lying )etween N* and N,.
"". Enter the forward and reverse weight as :@"; in order to disconnect N, from the other
nodes
59
8/10/2019 Network Simulation Lab Manual
60/85
"&. Now o)serve the routing ta)le.
"*. Now you could o)serve that there are no changes in the routing ta)le as they are not
u#dated. lick )utton to u#date the routing ta)le.
60
8/10/2019 Network Simulation Lab Manual
61/85
",. Even after several ho##ing the routing ta)les of N= N" N& N* shows the #ath and
weight to N,. These false u#dates are another disadvantage in the :%istance vector
algorithm;.
)+) P!3# L/8 e3#!n3
". Name several #ro)lems associated with distance vector #rotocols
&. +hat is counting@to@infinity #ro)lem and how can it )e controlledO
*. %escri)e a)out the various (outing Metrics
L/8 - Ln7 S#/#e r!#n5 .r!#!%!
+1 In#r!d%#!n=
61
8/10/2019 Network Simulation Lab Manual
62/85
8/10/2019 Network Simulation Lab Manual
63/85
*. Each router stores a co#y of all the LSAs it has seen in a data)ase. If all works well
the data)ases in all routers should )e identical.
,. The com#leted topological database also called the link state database descri)es a
gra#h of the internetwork. 4sing the %i7kstra algorithm each router calculates the
shortest #ath to each network and enters this information into the route ta)le.
+4 Pre/8 e3#!n3
". E>#lain the #rocedure to calculate Shortest #ath in LS( #rotocol
&. +hat is the #ur#ose of a to#ological data)aseO
*. +hy are seDuence num)ers im#ortant in link state #rotocolsO
+ Pr!%edre=
". %ou)le click on LanT (outing Simulator icon from the deskto#.
&. lick )utton and )rowse o#en ?Lantrainonfiglinear.t>t.
*. lick )utton and select Link state algorithm
63
8/10/2019 Network Simulation Lab Manual
64/85
,. lick on the nodes to o)tain the routing ta)le.
-. lick the )utton to u#date the routing ta)le. (outing ta)le of entire nodes gets
u#dated after a single ho##ing. This is one of the advantages of Link state algorithm over
%istance vector algorithm.
64
8/10/2019 Network Simulation Lab Manual
65/85
ount to Infinity #ro)lem?
/. lick on the green colour line lying )etween N* and N,.
1. Enter forward and reverse weights as @" to disconnect N, from the other nodes.
65
8/10/2019 Network Simulation Lab Manual
66/85
2. G)serve the routing ta)le. The values are not changed as it;s not u#dated.
3. lick the single ste# )utton .
"=. Now you could see the routing ta)le for each nodes )een u#dated. This is the advantage
of :Link state algorithm; over :%istance vector algorithm;.
66
8/10/2019 Network Simulation Lab Manual
67/85
+) P!3# L/8 e3#!n3
". +hat are the differences )etween distance vector and link state routing #rotocolsO
&. E>#lain the Ste#s involved in )uilding a (outing Ta)le using %i7ktra;s Algorithm
*. an to#ology )e )uilt using #artial knowledge of the each nodeO If yes e>#lain whyO
L/8 H= En%r9.#n5 / "e 3n5 RC4 /5!r#$
H+1 In#r!d%#!n?
The #ur#ose of this e>#eriment is to introduce you to (, algorithm encry#tion and
decry#tion.
H+2 ,/rd6/re Rereen#
*!s with NI4 card
Network Emulation 4nit
8/10/2019 Network Simulation Lab Manual
68/85
)its 8a keystream9 which for encry#tion is com)ined with the #lainte>t using )it@
wise e>clusive@orB decry#tion is #erformed the same way 8since e>clusive@or is a symmetric
o#eration9. 8This is similar to the 0ernam ci#her e>ce#t that generated pseudorandom bits
rather than a #re#ared stream are used.9 To generate the keystream the ci#her makes use of a
secret internal state which consists of two #arts?
". A #ermutation of all &-/ #ossi)le )ytes 8denoted QSQ )elow9.
&. Two 2@)it inde>@#ointers 8denoted QiQ and Q7Q9.
The #ermutation is initialized with a varia)le length key ty#ically )etween ,= and &-/ )its
using the key-schedulingalgorithm 8SA9. Gnce this has )een com#leted the stream of )its
is generated using thepseudo-random generation algorithm8!(A9.
H+4 Pre /8 e3#!n3
". +hat does (, stands forO
&. +hat is ey scheduling algorithm and !seudo (andom eneration AlgorithmO
*. +hat is i#herO E>#lain the ste#s in eneration of i#hers
H+ Pr!%edre
Initial set-up:
Install 7re ".-87ava run time environment9 to run this a##lication.
4nderstand the Ste#s Involved in (, Encry#tion and %ecry#tion Algorithm.
1. %ou)le click on icon.
68
8/10/2019 Network Simulation Lab Manual
69/85
&. Select Ste# mode and ty#e any te>t to encry#t. Ty#e any encry#tion key in either te>t or
)inary mode.
*. lick the Ne>t )utton from the right side #anel.
69
8/10/2019 Network Simulation Lab Manual
70/85
,. Now the State ta)le and ey ta)les are formed. 8S 'o> contains a matri> of &-/ values
starting from = and 'o> contains the matri> of re#eated ASII values of the key entered9.
-. The flow of the algorithm in each ste# is e>#lained in the descri#tion #anel on the right
side.
/. In the ne>t ste# the #ermutated values are stored in the S 'o> !ermutation.
1. ey )it stream is generated from the values o)tained from S 'o> !ermutation.
2. 5G( o#eration is done )etween the )inary value and key )it stream generated..
70
8/10/2019 Network Simulation Lab Manual
71/85
3. i#her te>t is formed corres#onding to the 5G( value generated.
"=. o#y the ci#her te>t )y selecting and #ressing ctrl c.
"". lick the clear )utton and #aste the ci#her te>t in the te>t field.
"&. Enter the same key that is used for encry#tion.
71
8/10/2019 Network Simulation Lab Manual
72/85
"*. Now you could retrieve )ack the original message.
En%r9.#n5 / "e 3n5 RC4 /5!r#$
Initial Setup:
". 'rowse ?Lantrain%ataSecurity.
&. o#y the (, folder and three class files 8onnect (,lient Server9 and #aste it into
the
8/10/2019 Network Simulation Lab Manual
73/85
En%r9.#n5 / "e=". G#en command #rom#t in the client side.
&. 'rowse the 7ava )in folder.
*. Ty#e 7ava (,lient.
,. Enter the I! address of the server.
-. Enter the mode of o#eration.
/. Enter the Encry#tion key not more than - characters.
1. Enter the #ath name of the file to )e encry#ted. 8for eg? c?a)c.t>t9
2. Ty#e JES if you like to close the session or ty#e NG if you like to continue decry#ting the
i#her te>t.
3. The encry#ted te>t is availa)le in c?out#ut.t>t.
"=. Try to re@arrange the ci#her te>t using any cry#t@analysis tool.
73
8/10/2019 Network Simulation Lab Manual
74/85
8/10/2019 Network Simulation Lab Manual
75/85
H+) P!3# L/8 e3#!n3
". 4sing the (, Encry#tion scheme encry#t a character with a key and o)serve the ci#her
te>t. (e#eat the same #rocedure for a different key )ut with the same te>t and see if there
is any relation )etween them. (e#eat with two same characters and o)serve whether theci#her te>t also gets re#eated.
&. E>#lain in %etail the generation of key in ey Scheduling Algorithm
75
8/10/2019 Network Simulation Lab Manual
76/85
L/8'= Tr/n3"er !" "e3 "r! PC #! PC 3n5 Wnd!63 UNI> 3!%7e# .r!%e33n5
'+1 In#r!d%#!n
The #ur#ose of this la) is to introduce you the conce#t of socket #rogramming T!
connection esta)lishment and Session management. In this la) you will )e a)le to esta)lish a
socket connection )etween two com#uters and use it to relia)ly transfer a file.
'+2 ,/rd6/re Rereen#
Two com#uters with Net Sim software
'+ B/%75r!nd
File transfer uses the client Cserver #aradigm. The server waits #assively listening for
reDuests from a client. After servicing the reDuest the server resumes listening. The client is
usually interactive and acce#ts commands s#ecifying the file name whether to or from the
server username and #assword etc.
File transfer is a session oriented task. It has three #hases?
". Session esta)lishment? Setu# a logical connection )etween client and server.
&. %ata transfer? the file is transferred to $from the server with a##ro#riate error
checking.
*. Session termination? the files are closed and the logical connection taken down.
Three #hases are descri)ed in detail )elow.
Se33!n E3#/83$en#
This involves several ste#s.
". Setu# of a trans#ort layer connection with the server. This is usually T!.
&. Sending username and #assword to the server for authentication
*. hecking the file #ermissions on )oth ends. E.g to send a file F the local file F must
e>ist and )e reada)le )y the user and the remote file F must )e writa)le )y the user.
In case Xno overwrite modeY is s#ecified the remote file F must not e>ist.
76
8/10/2019 Network Simulation Lab Manual
77/85
,. Negotiating session #arameters such as the file ty#e 8te>t or )inary9 and )lock size.
D/#/ Tr/n3"er
The sender reads the file one segment at a time and sends it on the T! connection. The
segment size may )e large e.g. "=s to "==s of '. Note that some T! im#lementations may
limit the size of each segment say to /, '. T! #rovides relia)le data transfer. However it
may a)ru#tly close the connection without delivering the data to the remote a##lication. To
handle such situations the file transfer receiver send an A to the sender after successfully
writing the data to the destination file.
Se33!n Tern/#!n
This may )e initiated )y either side. The initiator closes its local files and sends a disconnect
reDuest to the other side. The other #arty closes its file and res#onds with a disconnect
confirm. Each side closes its T! socket. The server resumes listening for connect reDuests.
A session may )e terminated normally after successful transfer of the file or a)normally after
incom#lete transfer such as due to network failure. In the latter case the receiver should
delete the incom#lete file so that it is not inadvertently used.
Err!r ,/ndn5
For any o#eration where an A is e>#ected the sender starts a timer. In case of e>#iry of
the timer the o#eration may )e retried or is a)orted and an error indication returned.
'+4 Pre /8 e3#!n3
". +hat is socket #rogrammingO
&. +hat are the #hases involved in file transferO
*. List the features of T! model.
,. +hat is %H!O
77
8/10/2019 Network Simulation Lab Manual
78/85
-. ive the I! address range of class A ' %.
'+ Pr!%edre
78
8/10/2019 Network Simulation Lab Manual
79/85
79
8/10/2019 Network Simulation Lab Manual
80/85
80
8/10/2019 Network Simulation Lab Manual
81/85
81
8/10/2019 Network Simulation Lab Manual
82/85
'+) P!3# /8 e3#!n3
". +hat is the difference )etween T! and 4%! #rotocolO
&. +hat are the timers availa)le in T!O
*. +hat do you mean )y socket addressO
,. ive the #ort num)ers of T! and 4%!.
-. iven the I! address? "3&."/2.=.". Identify the range and net id.
82
8/10/2019 Network Simulation Lab Manual
83/85
8/10/2019 Network Simulation Lab Manual
84/85
In#er P/%7e# De/9@ S#ecify the inter #acket delay 8that is eDuivalent to the inter #acket
arrival time9 )ased on the calculation suggested in the e>#eriments. This has to )e in
milliseconds.
N8er !" P/%7e#3 @ S#ecify num)er of #ackets in a window for Sliding +indow
e>#eriment. This field may )e used for other #ur#oses while writing codes for suggested
e>#eriments in e>ercise say for e>am#le to s#ecify num)er of #ackets to )e transmitted or
received in a MA e>#eriment instead of following time.
M9 Addre33@ S#ecify the address of each node 8)etween " and /9 in to# layers. For e>am#le
the server uses this field in FT! to identify the client for sending and receiving files.
R M!de@ S#ecify !romiscuous or Non@!romiscuous mode of #acket rece#tion. 'y default
all the stand@alone e>#eriments use #romiscuous mode of rece#tion 8receives the entire
#acket9. Altering this field will not have effect in the stand@alone e>#eriments. (efer#rogrammer;s manual for using various ty#es while writing codes for e>ercises.
IO M!de@ Fi>es the ty#es of transmit and receive modes. In ma7ority of the stand@alone
E>#eriments )locking transmit and receive is used and the other ty#es are left for the user to
im#lement wherever necessary as suggested in e>ercises. Altering this field will not have
effect in the stand@alone e>#eriments. (efer #rogrammer;s manual for using various ty#es
while writing codes for e>ercises.
T!7en Ree/3e M!de@ S#ecify the ty#e of token release mode to )e followed in token ring.
Manual token release is used in token ring e>#eriment. Altering this field will not have effect
in this stand@alone e>#eriment. (efer #rogrammer;s manual for using various ty#es whilewriting codes for e>ercises.
Dre%#!n @ S#ecify which direction to )e followed )y each node. In MA e>#eriments
Sender will only transmit data #ackets and (eceiver will only receive. In %LL e>#eriments
Sender will transmit data #ackets and receive acknowledgement #ackets while (eceiver will
receive them and transmit acknowledgement #ackets. In FT! Sender is the client and
(eceiver is the server.
B!!# Fe N/e@ Name and #ath of the NI4 driver file. This is for future use. The default
file and location is ?Lantrain)inLant0"*.e>e. It may )e left to this default name.
84
8/10/2019 Network Simulation Lab Manual
85/85