Upload
alexander-taylor
View
220
Download
0
Embed Size (px)
Citation preview
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 1/18
1
Lecture29
ComputerNetworks
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 2/18
2
ThePurposeofNetworking
• Goal: remotedataexchange.
• Afewdesirableproperties:
– Interoperability,
– Flexibility,
– Geographicalrange,
– Scalability,
– Privacyandsecurity.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 3/18
3
Mattersof Protocol
Everythinginnetworkinghappensthrough protocols:
Aprotocoldetermineshowhostsshareandaccessthemedium,
Aprotocoldetermineshowhostsdealwiththemediabandwidth,
errors,flowcontrol,etc,
Aprotocoldetermineshowconnectionsbetweenhostsareestablished
andmaintained,
Aprotocoldetermineshowinformationisroutedacrossshortandlong
distances.
Etc,etc,etc…
Question: Ok,butwhatis protocol?
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 4/18
4
ISO:InternationalStandardsOrganizationOSI:OpenSystemsInterconnection
Physical
Presentation
Session
Transport
Network
Datalink
Application
TheISO/OSIReferenceModelSource:ComputerNetworks,AndrewTanenbaum
Theprotocolstack :
Theideabehindthemodel: Breakupthe
designtomakeimplementationsimpler.
Eachlayerhasawell-definedfunction.
Layerspasstooneanotheronlythe
informationthatisrelevantateachlevel.
Communicationhappensonlybetween
adjacentlayers.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 5/18
5
TheLayersintheISO/OSIRFModel
Physical: Transmitrawbitsoverthemedium.
DataLink: Implementstheabstractionofanerrorfreemedium(handlelosses,duplication,errors,flowcontrol).
Network: Routing.
Transport: Breakupdataintochunks,sendthemdowntheprotocolstack,
receivechunks,putthemintherightorder,passthemup.
Session: Establishconnectionsbetweendifferentusersanddifferent
hosts.
Presentation: Handlesyntaxandsemanticsoftheinfo;examples:
encoding,encrypting.
Application: Protocolscommonlyneededbyapplications(cddb,http,
ftp,telnet,etc).
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 6/18
6
Layern-1
Layern+1
Layern
CommunicationBetweenLayerswithinaHost
SAP SAP…
SAP SAP…
SAPs (serviceaccesspoints)
Note: ThisisISOterminology.
It’simportanttospecify
theservicesoffered
tohigherlayersin
thehierarchy.What
theyare+howto
usethem=interface.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 7/18
7
CommunicationBetweenLayersinDifferentHosts
sender receiver
data data
AH data
PH data
SH data
TH data
NH data
DHDTdata
BITSPhysical
Presentation
Session
Transport
Network
Datalink
Application
Physical
Presentation
Session
Transport
Network
Datalink
Application
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 8/18
8
TheLayersintheTCP/IPProtocolSuiteSource:TheTCP/IPProtocolSuite,Behrouz A.Forouzan
Physical
Datalink
IPARP RARP
ICMP IGMP
Transport TCP UDP
Network
Session
Presentation
Application
FTP HTTP DNS NFS …
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 9/18
9
DesignAlternatives
Point-to-pointchannels: physicallinks(asinwiring)connect
everytwocommunicatingpartieswitha“private”channel.
Broadcastchannels: communicatingpartiesareconnected
byasharedmedium;hostscanheartransmissionsnot
necessarilyaddressedtothem.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 10/18
10
NetworkTopology
Wecanclassifycomputernetworksaccordingtotheirtopology:
bus star
ring
mesh
hypercube
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 11/18
11
RangeofCoverage
LAN: localareanetwork
WLAN: wirelesslocalareanetwork
MAN: metropolitanareanetwork
WAN: wideareanetwork(longhaulnetwork)
Wecanalsoclassifycomputernetworksaccordingto
theirgeographicalcoverage:
Mostcommonly,we’reinterestedintheseamlessintegration
ofalltheselevels(asintheInternet).
Note: Differentlevelsuseverydifferenttechnologies.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 12/18
12
Technology
NetworkInterfaceCard(NIC): I/Odeviceinthecomputer
systemthatallowsittojoinanetwork.
TheNICworkswithaspecificmedium
(twisted-pair,coaxialcable,opticfiber,etc).
Host
NIC
NIC
…
Tothehost,theNICisjustanotherI/Odevice,whichhasits
ownaddress.A protocol determineshowtheNICaccesses
themedium.
Aslongasitsbus
allows,ahostcan
havemultiple
NICs.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 13/18
13
Ethernet
BusArbitrationbyCollisionDetection:
CarrierSenseMultipleAccesswith
CollisionDetection(CSMA/CD)
time
HostAlistensand
findsthebusidle.
HostBlistensand
findsthebusidle.
HostAstartsTX.
HostBstartsTX.
COLLISION!
HostAdetects
collision.
HostBdetects
collision.
HostBlistensand
findsthebusidle.
HostBstartsTX.
HostBcompletesTX.
HostBbacksoff.
HostAbacksoff.
Ethernethasabustopology.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 14/18
14
COTSEthernet
Ethernethasabustopology
Themediumcouldbeanythingthatallowsforabusimplementation.
(someoptionsareeasiertoworkwiththanothers)
Host NIC
Host NIC
Host NIC
… Hub:
Anout-of-theboxbus
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 15/18
15
SwitchedLANs
Host NIC
Host NIC
Host NIC
… Switch:allowsformorethan
onepairtotalkatthesame
time.
Thebusbandwidthislimited,sogoforaswitchedarchitecture.
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 16/18
16
TokenRing
Hostsconnecttoaswitchwhichclosesthering.
Mediumaccessisdonebypassingaroundatoken.
A B C
DEF
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 17/18
17
NetworkArchitectureforPerformance
Thekeywordishierarchy:
Switch
Subnet1
Subnet2
SubnetN
…
hub
hub
hub
8/4/2019 Computer Science 37 Lecture 29
http://slidepdf.com/reader/full/computer-science-37-lecture-29 18/18
18
NetworkArchitectureforPerformanceandCoverage
Again,thekeywordishierarchy:
Switch
Subnet1
Subnet2
SubnetN
…
Switch
Subnet1
Subnet2
SubnetN
…
…
RouterConnectiontoothernetworks
hub
hub
hub
hub
hub
hub