CPSC441 - PowerPoint PPT Presentation

1 / 84
About This Presentation
Title:

CPSC441

Description:

Single communication channel that is shared by all the machines on the network ... Hubs are usually located in computer rooms, or network distribution cupboards ... – PowerPoint PPT presentation

Number of Views:52
Avg rating:3.0/5.0
Slides: 85
Provided by: pagesCpsc
Category:

less

Transcript and Presenter's Notes

Title: CPSC441


1
CPSC441
  • DATALINK LAYER

Media access sublayer
2
OSI
Application
Presentation
LOGICAL LINK sublayer
Session
Transport
Framing Error control Flow control
Network
Data Link
Physical
MEDIA ACCESS sublayer
Transmission/reception of frames
3
Single communication channel that is shared by
all the machines on the network
Broadcast Networks
computer
General Rule Smaller, geographically localized
networks
1
2
3
4
5
cable
Packets
Short messages sent by any machine are received
by all others
Address
Fields
Quick Review
4
Packets
1
2
3
4
5
3
ALL machines receive it, but one processes it
Also possible to address a packet to ALL machines
(special code in the address field)
Mode of operation Broadcasting
Also possible to address a packet to a SUBSET of
machines (group number code in the address field)
Mode of operation Multicasting
Quick Review
5
The Medium Access Sublayer (ch 4)
deals with
BROADCAST NETWORKS AND THEIR PROTOCOLS
6
The Medium Access Sublayer (ch 4)
4.1 THE CHANNEL ALLOCATION PROBLEM
4.2 MULTIPLE ACCESS PROTOCOLS
IEEE STANDARD 802 FOR LANs
DATALINK SWITCHING
VLANs
7
The Channel Allocation Problem
  • Central theme of chapter 4 ? How to allocate a
    single broadcast channel among competing users?
  • Static
  • FDM /TDM (Frequency/Time Division Multiplexing)
  • FDM Radio/TV broadcasts
  • TDM POTS (Plain Old Telephone System)
  • GSM uses both (Global System for Mobile
    Communications)
  • Wasteful of bandwidth
  • Dynamic
  • Pure/ Slotted ALOHA
  • Carrier Sense Multiple Access (CSMA) Protocols
  • Collision free protocols

8
Dynamic Channel Allocation Technologies
  • Pure ALOHA
  • Slotted ALOHA
  • CSMA
  • CSMA/CD (old ETHERNET)
  • Switching (Fast ETHERNET)
  • Token passing (Token Ring )

9
ALOHA Protocols
Back in 1970, the University of Hawaii built a
network out of radios that broadcast signals.
Basic idea
  • Anyone may transmit whenever they want.
    (Continuous time model.)
  • Each radio detects collisions by listening to its
    own signal. A collision is detected when a sender
    doesn't receive the signal that it just sent.
  • After a collision, wait a random amount of time
    and transmit the same frame again. This technique
    is known as backoff.

10
Pure ALOHA
11
A Shared Medium ? Collision Domain
12
Slotted ALOHA
  • Time is divided into slots can only transmit at
    start of slot
  • Vulnerable period halved gt max. eff is doubled
  • Requires sync of clocks
  • Still poor at hi-loads

13
Carrier Sense, Multiple Access (CSMA)
  • We can improve the performance of our simple
    network greatly if we introduce carrier sensing
    (CS). With carrier sensing, each host listens to
    the data being transmitted over the cable.
  • A host will only transmit its own frames when it
    cannot hear any data being transmitted by other
    hosts.
  • When a frame finishes, an interframe gap of about
    9.6?sec is allowed to pass before another host
    starts transmitting its frame.

14
Carrier Sense Multiple Access (CSMA)
  • Improves performance when higher medium
    utilisation
  • When a node has data to transmit, the node first
    listens to the cable (using a transceiver) to see
    if a carrier (signal) is being transmitted by
    another node.

15
Persistent and Nonpersistent CSMA
  • Comparison of the channel utilization versus load
    for various random access protocols.

16
CSMA with Collision Detection
  • CSMA/CD can be in one of three states
    contention, transmission, or idle.

17
Wireless LAN Protocols
  • Wireless LAN. (a) A transmitting.
  • (b) B transmitting.

18
Wireless LAN Protocols
  • The MACA protocol. (a)
  • A sending an RTS to B.
  • (B responding with a CTS to A.

19
IEEE 802.3 CSMA/CD Bus LAN
  • The 802.3 standard describes the operation of the
    MAC sub-layer in a bus LAN that uses carrier
    sense, multiple access with collision detection
    (CSMA/CD).
  • Beside carrier sensing, collision detection and
    the binary exponential back-off algorithm, the
    standard also describes the format of the frames
    and the type of encoding used for transmitting
    frames.
  • The minimum length of frames can be varied from
    network to network. This is important because,
    depending on the size of the network, the frames
    must be of a suitable minimum length.
  • The standard also makes some suggestions about
    the type of cabling that should be used for
    CSMA/CD bus LANs.
  • The CSMA/CD Bus LAN is also widely called
    Ethernet.

20
Ethernet MAC Sublayer Protocol
  • Frame formats. (a) DIX Ethernet,
  • (b) IEEE 802.3.

21
IEEE 802.3 MAC Addresses
  • Every network card in the world has a unique
    46-bit serial number called a MAC address. The
    IEEE allocates these numbers to network card
    manufacturers who encode them into the firmware
    of their cards.
  • The destination and source address fields of the
    MAC frame have 48 bits set aside (the standard
    also allows for 16-bit addresses but these are
    rarely used).
  • The most significant bit is set to 0 to indicate
    an ordinary address and 1 to indicate a group
    address (this is for multicasting, which means
    that frames are sent to several hosts). If all
    48 bits are set to 1 then frames are broadcast to
    all the hosts.
  • If the two most significant bits are both zero
    then the 46 least significant bits contain the
    MAC addresses of the source and destination hosts.

22
IEEE 802.3 Minimum Frame Length
  • When a host transmits a frame, there is a small
    chance that a collision will occur. The first
    host to detect a collision transmits a 48-bit jam
    sequence.
  • To ensure that any hosts involved with the
    collision realise that the jam sequence is
    associate with their frame, they must still be
    transmitting when the jam sequence arrives. This
    means that the frame must be of a minimum length.
  • The worse case scenario is if the two hosts are
    at far ends of the cable. If host As frame is
    just reaching host B when it begins transmitting,
    host B will detect the collision first and send a
    jam signal back to host A.

23
CSMA/CD ? Minimum Ethernet Frame Size
  • To ensure that no node may completely receive a
    frame before the transmitting node has finished
    sending it, Ethernet defines a minimum frame size
    (i.e. no frame may have less than 46 bytes of
    payload).
  • The minimum frame size is related to the
    distance which the network spans, the type of
    media being used and the number of repeaters
    which the signal may have to pass through to
    reach the furthest part of the LAN.
  • Together these define a value known as the
    Ethernet Slot Time, corresponding to 512 bit
    times at 10 Mbps.

24
IEEE 802.3 Minimum Frame Length
  • The longest time between starting to transmit a
    frame and receiving the first bit of a jam
    sequence is twice the propagation delay from one
    end of the cable to the other.
  • This means that a frame must have enough bits to
    last twice the propagation delay.
  • The 802.3 CSMA/CD Bus LAN transmits data at the
    standard rate of r 10Mbps.
  • The speed of signal propagation is about v
    2?108m/s.

25
IEEE 802.3 Minimum Frame Length
In order to calculate the minimum frame length,
we must first work out the propagation delay from
one end of the cable to the other.
26
IEEE 802.3 Minimum Frame Length
Example 1 Cable 400m, transm. speed 10
Mbit/sec, propagation speed 2108 m/sec
Propagation delay time
The round-trip propagation delay is, of course,
twice this. Thus the round trip delay is
With a data rate of
each bit has duration
27
IEEE 802.3 Minimum Frame Length
Example 1 cont.
The number of bits we can fit into a round-trip
propagation delay is
The minimum frame length is thus 40 bits (5
bytes). A margin of error is usually added to
this (often to make it a power of 2) so we might
use 64 bits (8 bytes).
28
EEE 802.3 Minimum Frame Length
Example 2
Two nodes are communicating using CSMA/CD
protocol. Speed transmission is 100 Mbits/sec and
frame size is 1500 bytes. The propagation speed
is 3108 m/sec. Calculate the distance between
the nodes such that the time to transmit the
frame time to recognize that the collision have
occurred.
29
IEEE 802.3 Minimum Frame Length
  • The standard frame length is at least 512 bits
    (64 bytes) long, which is much longer than our
    minimum requirement of 64 bits (8 bytes).
  • We only have to start worrying when the LAN
    reaches lengths of more than 2.5km.
  • 802.3 CSMA/CD bus LANs longer than 500m are
    usually composed of multiple segments joined by
    in-line passive repeaters, which output on one
    cable the signals received on another cable.
  • When we work out the minimum frame length for
    these longer LANs, we also have to take the
    delays caused by the passive repeaters (about
    2.5?sec each) into account as well.

30
Shortest Ethernet Frame
Why specify a shortest frame of 64byte?
  • 64 bytes sent at 10Mbps ? 51.2?sec
  • 500m/segment, 4 repeaters between nodes ?2500m
    ?25 ?sec propagation delay
  • The frame should be longer enough for sender to
    detect the collision(2x25 or about 50 ?sec )

Node A
Node B
R1
R2
R3
R4
500m ?25 ?sec propagation delay
31
IEEE 802.3 Non-Deterministic
  • The 802.3 CSMA/CD bus LAN is said to be a
    non-deterministic network. This means that no
    host is guaranteed to be able to send its frame
    within a reasonable time (just a good probability
    of doing so).
  • When the network is busy, the number of
    collisions rises dramatically and it may become
    very difficult for any hosts to transmit their
    frames.
  • A real-time computing application (such as an
    assembly line) will demand that data is
    transmitted within a specified time period.
  • Since the 802.3 bus LAN cannot guarantee this,
    its use for real-time applications may not only
    be undesirable but potentially dangerous in some
    situations.

32
Ethernet Performance

33
Ethernet Physical Layer standards
  • 10Base5
  • 10 Mbps, Baseband transmission, 500m cable length
  • 10Base2
  • 10 Mbps, Baseband transmission, 200m cable
    length
  • 10Base-T
  • 10 Mbps, Baseband transmission, UTP cable
  • 100Base-TX
  • 100 Mbps, Baseband transmission, UTP cable

34
Ethernet 10Base-T 100Base-TX
  • Wiring
  • Unshielded Twisted Pair (UTP)
  • Category 5 wiring is best
  • Cat 3 and Cat 4 in some older installations
  • Bundle of eight wires (only uses four)
  • Terminates in RJ-45 connector

35
10Base-T 100Base-TX hubs
  • UTP-based networks use hubs to interconnect NICs
  • each UTP cable runs directly from a NIC to a hub

36
10Base-T 100Base-TX hubs
  • Hubs have many ports, each of which has one
    incoming network cable
  • Hubs are usually located in computer rooms, or
    network distribution cupboards
  • a patch panel (or patch bay) is used to connect
    between hubs and the wall sockets throughout a
    building

37
10Base-T 100Base-TX wiring
  • Wiring
  • 100 meters maximum distance hub-to-station
  • Can use multiple hubs (max 4) to increase the
    distance between any two stations

200 m
100 m
100 m
38
10Base-T to 100Base-TX
  • Upgrading from 10Base-T to 100Base-TX
  • Need new hub
  • May have some 10 Mbps ports to handle 10Base-T
    NICs
  • May have autosensing 10/100 ports that handle
    either
  • Need new NICs
  • Only for stations that need more speed
  • No need to rewire
  • This would be expensive

39
Multiple Hubs in 10Base-T
  • Farthest stations in 10Base-T can be five
    segments (500 metres apart)
  • 100 metres per segment
  • Separated by four hubs

100m
100m
10Base-T hubs
100m
500m, 4 hubs
100m
100m
40
Multiple Hubs in 100Base-TX
  • Limit of Two Hubs in 100Base-TX
  • Must be within a few metres of each other
  • Maximum span 200 metres
  • Shorter distance span than 10Base-T

2 Co-located Hubs
100m
100Base-TX Hubs
100m
41
Latency and Congestion with hubs
  • Ethernet is a shared media LAN
  • Only one station can transmit at a time
  • Even in multi-hub LANs
  • Others must wait
  • This causes delay

All Other Stations Must Wait
One Station Sends
42
Fast Ethernet
  • The original fast Ethernet cabling.

43
Gigabit Ethernet
  • Gigabit Ethernet cabling.

44
IEEE 802.2 Logical Link Control
  • (a) Position of LLC. (b) Protocol formats.

45
Repeaters
  • Regenerate the signal
  • Provide more flexibility in network design
  • Extend the distance over which a signal may
    travel down a cable
  • Example ? Ethernet HUB

46
Ethernet Repeaters and Hubs
  • Connect together one or more Ethernet cable
    segments of any media type
  • If an Ethernet segment were allowed to exceed the
    maximum length or the maximum number of attached
    systems to the segment, the signal quality would
    deteriorate.

47
Ethernet Repeaters and Hubs
  • Used between a pair of segments
  • Provide signal amplification and regeneration
    to restore a good signal level before sending it
    from one cable segment to another

48
Ethernet Bridge
  • Join two LAN segments (A,B), constructing a
    larger LAN
  • Filter traffic passing between the two LANs and
    may enforce a security policy separating
    different work groups located on each of the
    LANs.

49
Local Internetworking
  • A configuration with four LANs and two bridges.

50
Ethernet Bridges
  • Simplest and most frequently used ? Transparent
    Bridge (meaning that the nodes using a bridge are
    unaware of its presence).
  • Bridge could forward all frames, but then it
    would behave rather like a repeater
  • Bridges are smarter than repeaters!

51
Ethernet Bridges
A bridge stores the hardware addresses observed
from frames received by each interface and uses
this information to learn which frames need to be
forwarded by the bridge.
52
Ethernet Switch ? Modern LANs
  • Fundamentally similar to a bridge
  • Supports a larger number of connected LAN
    segments
  • Richer management capability.
  • Logically partition the traffic to travel only
    over the network segments on the path between the
    source and the destination (reduces the wastage
    of bandwidth)

53
Ethernet Switch ? Benefits
  • Improved security
  • users are less able to tap-in into other user's
    data
  • Better management
  • control who receives what information (i.e.
    Virtual LANs)
  • limit the impact of network problems
  • Full duplex
  • rather than half duplex required for shared access

54
Switched LAN
  • Hub and Switched LAN
  • hub simulates a single shared medium
  • switch simulates a bridged LAN with one computer
    per segment

55
Ethernet Switches
  • Highly Scalable
  • 10Base-T switches
  • Competitive with 100Base-TX hubs in both cost and
    throughput
  • Increasingly used to desktops
  • 100Base-TX switches
  • Higher performance (and price)
  • Gigabit Ethernet switches
  • Very expensive

56
Ethernet Switches
  • No limit on number of Ethernet switches between
    farthest stations
  • So no distancelimit on size ofswitched networks

57
Ethernet Switches
  • Ethernet Switches must be Arranged in a
    Hierarchy (or daisy chain)
  • Only one possible path between any two stations,
    switches

1
Path4,5,2,1,3
2
3
4
6
5
58
Repeaters, Hubs, Bridges, Switches, Routers and
Gateways
  • (a) Which device is in which layer.
  • (b) Frames, packets, and headers.

59
Repeaters, Hubs, Bridges, Switches, Routers and
Gateways
  • (a) A hub. (b) A bridge. (c) a switch.

60
Repeater HUBs
61
Switches
62
Switches
Repeater HUBs
63
(No Transcript)
64
Ethernet Switches and Multicast Traffic
Multicast Traffic from F is delivered to all
output interfaces (ports) which asks for it
65
Virtual LANs (VLANs)
Cisco Systems
66
Cisco Systems
67
Virtual LANs (VLANs)
Cisco Systems
68
Virtual LANs (VLANs)
Cisco Systems
69
Switches Versus Routers
  • Switches
  • Fast
  • Inexpensive
  • No benefits of alternative routing
  • No hierarchical addressing
  • Routers
  • Slow
  • Expensive
  • Benefits of alternative routing
  • Hierarchical addressing

Switch where you can route where you must
70
Where Does Wireless RF Live?ISM Band
Industrial, Scientific, Medical
902-928 MHz
2400-2483.5 MHz
5725-5850 MHz
Old Wireless
802.11a
802.11/802.11b
Bluetooth
Cordless Phones
Home RF
Baby Monitors
Microwave Ovens
71
IEEE 802.11 Wireless Ethernet
  • Two configurations
  • Ad-hoc. No central control, no
  • connection to the outside world
  • Infrastructure. Uses fixed network
  • Access Point to connect to the
  • outside world

72
  • IEEE 802.11 Wireless Ethernet

Uses CSMA/CA protocol. CSMA part is the same as
in 802.3 Ethernet CA stands for Collision
Avoidance and works as follows If the carrier
is present for a specific time period,
transmitter sends a frame If no collision
receiver send ack Transmitter can also reserve
the channel by sending Request to Send (RTS)
73
  • IEEE 802.11 Wireless Ethernet

IEEE 802.11 does not implement Collision
Detection because it cannot detect collisions at
the receiver end (hidden terminal problem) To
avoid collisions the frame contains field
indicating the length of transmission Other
stations defer transmission
74
The 802.11 Protocol Stack

75
Where does 802.11 live in the OSI?
Application
Telnet, FTP, Email, Web, etc.
Presentation
Session
TCP, UDP
Transport
IP, ICMP, IPX
Network
Logical Link Control - 802.2 (Interface
to the upper layer protocols)
Data Link
MAC
Wireless lives at Layers 1 2 only!
802.3, 802.5, 802.11
LAN 10BaseT, 10Base2, 10BaseFL
Physical
WLAN FHSS, DSSS, IR
76
The 802.11 MAC Sublayer Protocol
  • (a) The hidden station problem.
  • (b) The exposed station problem.

77
CSMA-CA Acknowledgement
Carrier Sense Multiple Access with Collision
Avoidance
How CSMA-CA works
  • Device wanting to transmit senses the medium
    (Air)
  • If medium is busy - defers
  • If medium is free for certain period (DIFS) -
    transmits frame

Latency can increase if air is very busy!
Device has hard time finding open air to send
frame!
  • DIFS - Distributed Inter-Frame Space
  • (approx 128 µs)

78
The 802.11 MAC Sublayer Protocol
  • The use of virtual channel sensing using CSMA/CA.

79
The 802.11 Frame Structure
  • The 802.11 data frame.

80
Summary
  • IEEE 802.11b (WiFi) is a wireless LAN technology
    that is rapidly growing in popularity
  • Convenient, inexpensive, easy to use
  • Growing number of hot spots everywhere
  • airports, hotels, bookstores, Starbucks, etc
  • Estimates 70 of WLANs are insecure!

81
IEEE 802.5 and Token Ring
82
FDDI ? Fiber Distributed Data Interface
  • data rate 100Mbps, use as a backbone
  • With multi-mode fiber any given ring segment can
    be up to 200 km in length. A total of 500
    stations can be connected with a maximum
    separation of 2 km.
  • two complete rings to overcome failures

83
High Speed LANs
  • FDDI Fiber Distributed Data Interface
  • 100Mbps, distance up to 200km, 100 hosts mainly
    used as a backbone

84
Bandwidth Scaling
Mbps
Gigabit Ethernet(Switched) ATM
OC-12(Switched) ATM OC-3(Switched) Fast
Ethernet(Switched) FDDI(Switched) Token
Ring(Switched) Ethernet(Switched)
1000 900 800 700 600 500 400 300 200 100 0
Ethernet
FE
Switched LAN Type
Cisco Systems
Write a Comment
User Comments (0)
About PowerShow.com