Data and Computer Communications · 2015. 2. 5. · Data and Computer Communications Tenth Edition...
Transcript of Data and Computer Communications · 2015. 2. 5. · Data and Computer Communications Tenth Edition...
-
Data and Computer Communications
Tenth Edition by William Stallings
Data and Computer Communications, Tenth Edition by William Stallings, (c) Pearson
Education - Prentice Hall, 2013
-
Local Area Network Overview
CHAPTER 11
-
“There is some evidence that computer networks will have a large impact on society. Likely areas are the economy, resources, small computers, human-to-human interaction, and computer research.”
—What Can Be Automated? The Computer Science and
Engineering Research Study, MIT Press, 1980
-
Bus Topology Ø Topology
l Refers to the way in which the endpoints, or stations, attached to the network are interconnected
Ø Bus topology l All stations attach, through a tap, directly to a linear
transmission medium, or bus l Full-duplex operation between the station and the tap
allows data to be transmitted onto the bus and received from the bus
l A transmission from any station propagates the length of the medium in both directions and can be received by all other stations
l At each end of the bus is a terminator, which absorbs any signal, removing it from the bus
-
A
A
C transmits frame addressed to A
Frame is not addressed to B; B ignores it
A copies frame as it goes by
A
A
Figure 11.1 Frame Transmission on a Bus LAN
B C
A B C
A B C
-
Star Topology Ø Each station connects to common central
node l Usually via two point-to-point links
• One for transmission and one for reception
• Operate in broadcast fashion • Physical star, logical bus • Only one station can transmit at a time (hub) • Can act as frame switch
Central node
-
Central Hub,switch,or repeater
Figure 11.2 Star Topology
-
Physical
Data Link
Medium
Network
Transport
Session
Presentation
Application
OSI ReferenceModel
Physical
Medium AccessControl
Medium
Logical Link Control( ) ( ) ( )
UpperLayer
ProtocolsLLC ServiceAccess Point
(LSAP)
Scopeof
IEEE 802Standards
Figure 11.3 IEEE 802 Protocol Layers Compared to OSI Model
IEEE 802Reference
Model
-
IEEE 802 Reference Model
Ø Lowest layer corresponds to the physical layer of the OSI model
Ø Includes a specification of the transmission medium and the topology
Includes functions such as:
Encoding/decoding of signals
Preamble generation/removal
Bit transmission/reception
-
IEEE 802 Layers Ø Logical Link Control
Layer (LLC) l Provide interface to
higher levels l Perform flow and error
control
Ø Media Access Control (MAC) l On transmit assemble
data into frame l On reception
disassemble frame, perform address recognition and error detection
l Govern access to LAN transmission medium
-
TCP segment
IP datagram
LLC protocol data unit
MAC frame
Application data
TCPheader
IPheader
LLCheader
MACheader
MACtrailer
Figure 11.4 LAN Protocols in Context
Application Layer
TCP Layer
IP Layer
LLC Layer
MAC Layer
-
Logical Link Control
Ø Transmission of link level PDUs between stations
Ø Must support multi-access, shared medium
Ø Relieved of some details of link access by the MAC layer
Ø Addressing involves specifying source and destination LLC users l Referred to as service access points (SAPs)
-
LLC Services Unacknowledged connectionless service • Data-gram style service • Delivery of data is not guaranteed
Connection-mode service • Logical connection is set up between two users • Flow and error control are provided
Acknowledged connectionless service • Datagrams are to be acknowledged, but no logical
connection is set up
-
LLC Service Alternatives Unacknowledged connectionless service • Requires minimum logic • Avoids duplication of mechanisms • Preferred option in most cases
Connection-mode service • Used in simple devices • Provides flow control and reliability mechanisms
Acknowledged connectionless service • Large communication channel needed • Time critical or emergency control signals
-
LLC Protocol
Ø Modeled after HDLC Ø Asynchronous balanced mode
l Connection mode (type 2) LLC service Ø Unacknowledged connectionless service
l Using unnumbered information PDUs (type 1) Ø Acknowledged connectionless service
l Using 2 new unnumbered PDUs (type 3) Ø Permits multiplexing using LSAPs
-
Figure 11.5 LLC PDU in a Generic MAC Frame Format
MACFrame
LLCAddress FieldsI/G
I/G = Individual/GroupC/R = Command/Response
DSAP value C/R SSAP value
MACControl
DestinationMAC Address
SourceMAC Address LLC PDU CRC
LLCPDU DSAP
1 octet 1 1 or 2 variable
SSAP LLC Control Information
-
Medium Access Control (MAC) Protocol
Ø Controls access to the transmission medium Ø Key parameters:
l Where • Greater control, single point of failure • More complex, but more redundant
l How • Synchronous
l Capacity dedicated to connection, not optimal • Asynchronous
l Response to demand l Round robin, reservation, contention
-
Asynchronous Systems
Round robin • Each station
given turn to transmit data
Reservation • Divide medium
into slots • Good for stream
traffic
Contention • All stations
contend for time • Good for bursty
traffic • Simple to
implement • Tends to collapse
under heavy load
-
MAC Frame Handling
Ø MAC layer receives data from LLC layer
Ø PDU is referred to as a MAC frame
Ø MAC layer detects errors and discards frames
Ø LLC optionally retransmits unsuccessful frames
-
Bridges
Ø Connects similar LANs with identical physical and link layer protocols
Ø Minimal processing Ø Can map between MAC formats Ø Reasons for use:
l Reliability l Performance l Security l Geography
-
LAN A
LAN B
Bridge
Figure 11.6 Bridge Operation
Frames withaddresses 11 through20 are accepted andrepeated on LAN B
Frames withaddresses 1 through10 are accepted andrepeated on LAN A
Station 1 Station 2 Station 10
Station 11 Station 12 Station 20
-
Bridge Design Aspects
Ø Makes no modification to the content or format of the frames it receives
Ø Should contain enough buffer space to meet peak demands
Ø Must contain routing and addressing intelligence
Ø May connect more than two LANs Ø Bridging is transparent to stations
-
PhysicalPhysical
MAC
MAC-H LLC-H MAC-TUser Data
LLC-H User Data
User Data
LLC
Usert1
t3, t4, t5, t6
t2, t7
t1, t8
t2t3 t4 t5 t6
t7
t8
Physical
MAC
LLC
User
MAC
(a) Architecture
(b) Operation
Figure 11.7 Connection of Two LANs by a Bridge
PhysicalLAN LAN
-
LAN A
LAN B LAN C
LAN D LAN E LAN GLAN F
Bridge101 Bridge
107
Bridge102
Bridge103
Bridge104
Bridge105
Bridge106
Station 1
Station 4 Station 5 Station 6 Station 7
Station 2 Station 3
Figure 11.8 Configuration of Bridges and LANs, with Alternate Routes
-
Fixed Routing Ø Simplest and most common strategy Ø Suitable for small internets and internets that are
relatively stable Ø A fixed route is selected for each pair of LANs
• Usually least hop route Ø Only change when topology changes Ø Widely used but limited flexibility
-
Spanning Tree Ø Bridge automatically develops routing
table Ø Automatically updates routing table in
response to changing topology
Algorithm consists of three mechanisms:
Frame forwarding Address learning Loop resolution
-
Frame Forwarding Ø Maintain forwarding database for each port
attached to a LAN Ø For a frame arriving on port X:
Search forwarding database to see if MAC address is listed for any port except port X
If destination MAC address is not found, forward frame out all ports except the one from which it was received
If the destination address is in the forwarding database for some port y, check port y for blocking or forwarding state
If port y is not blocked, transmit frame through port y onto the LAN to which that port attaches
-
Address Learning Ø Can preload forwarding database Ø When frame arrives at port X, it has come from
the LAN attached to port X Ø Use source address to update forwarding
database for port X to include that address Ø Have a timer on each entry in database Ø If timer expires, entry is removed Ø Each time frame arrives, source address
checked against forwarding database l If present timer is reset and direction recorded l If not present entry is created and timer set
-
Spanning Tree Algorithm Ø Address learning works for tree layout if there
are no alternate routes in the network l Alternate route means there is a closed loop
Ø For any connected graph there is a spanning tree maintaining connectivity with no closed loops
Ø Algorithm must be dynamic
• Each bridge assigned unique identifier • Cost assigned to each bridge port • Exchange information between bridges to find spanning tree • Automatically updated whenever topology changes
IEEE 802.1 Spanning Tree Algorithm:
-
LAN Y
LAN X
Bridge Bridge
t2t1
t0 t0
Station B
Station A
Figure 11.9 Loop of Bridges
-
Hubs Ø Active central element of star layout Ø Each station connected to hub by two lines Ø Hub acts as a repeater Ø Length of a line is limited to about 100m Ø Optical fiber may be used to about 500m Ø Physically a star, logically a bus Ø Transmission from any one station is received by
all other stations Ø If two stations transmit at the same time there
will be a collision
-
Station Station Station Station
Station
HHUB
Figure 11.10 Two-Level Star Topology
IHUBIHUB
Two cables(twisted pair or
optical fiber)
Transmit
Receive
-
Shared Bus - 10 Mbps
10 M
bps
10 M
bps
10 M
bps
10 M
bps
A B C D
(a) Shared medium bus
A B C D
(b) Shared medium hub
10 Mbps 10 Mbps
10 Mbps10 Mbps
Total capacityup to 10 Mbps
A B C D
(c) Layer 2 switch
10 Mbps 10 Mbps
10 Mbps10 Mbps
Total capacityN 10 Mbps
Figure 15.11 LAN Hubs and Switches
-
Layer 2 Switch Benefits
Ø No change is required to the software or hardware of the attached devices to convert a bus LAN or a hub LAN to a switched LAN
Ø Have dedicated capacity equal to original LAN l Assuming switch has sufficient capacity to keep up
with all devices Ø Scales easily
l Additional devices attached to switch by increasing capacity of layer 2
-
Types of Layer 2 Switches
Ø Store-and-forward switch l Accepts frame on input
line, buffers briefly, routes to appropriate output line
l See delay between sender and receiver
l Boosts overall integrity
Ø Cut-through switch l Use destination
address at beginning of frame
l Switch begins repeating frame onto output line as soon as destination address is recognized
l Yields highest possible throughput
l Risk of propagating bad frames
-
Layer 2 Switch vs. Bridge Ø Differences between
switches and bridges: Ø Layer 2 switch can be viewed as full-duplex hub
Ø Incorporates logic to function as multiport bridge
Ø New installations typically include layer 2 switches with bridge functionality rather than bridges
Bridge
Frame handling done in software
Analyzes and forwards one
frame at a time
Uses store-and-forward operation
Switch
Performs frame forwarding in
hardware
Can handle multiple frames
at a time
Can have cut-through operation
-
Figure 11.12 A LAN Configuration
Inaho for takeout. Love to All Tricia
Z
W
XY
Internet
Server
RouterEthernet
switch
Printer
Workstation
-
Figure 11.13 A Partitioned LAN
Internet
Server
RouterEthernet
switch
Printer
Workstation
Z
V
W
XY
-
Figure 11.14 A VLAN Configuration
Internet
VLANE
VLAN C
VLAN A
VLANA
VLANA
VLANA
VLANB
VLANB
VLAND
Server
Ethernetswitch withVLAN andIP routingcapability
Printer
Workstation
Z
W
XY
-
Defining VLANs
Ø Broadcast domain consisting of a group of end stations not limited by physical location and communicate as if they were on a common LAN
Ø Membership by: l Port group l MAC address l Protocol information
-
Communicating VLAN Membership
Switches need to know VLAN membership
Ø Configure information manually Ø Network management signaling protocol Ø Frame tagging (IEEE802.1Q)
-
Summary Ø Bus and tree topologies
and transmission media l Topologies l Choice of topology l Choice of transmission
medium Ø LAN protocol
architecture l IEEE 802 reference
model l Logical link control l Medium access control
Ø Hubs and switches l Hubs l Layer 2 switches
Ø Bridges l Functions of a bridge l Bridge protocol
architecture l Fixed routing l The spanning tree
approach Ø Virtual LANs
l The use of virtual LANs l Defining VLANs l Communicating VLAN
membership