Chapter 13

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 19

CHAPTER 13

Packets, Frames & Topologies

Notes for Douglas E. Comer, Computer Networks and Internets (5th Edition)
Circuit Switching
guaranteed isolation from paths used by other pairs of senders and receivers
Circuit Switching
 Instead of having each circuit correspond to a physical path, multiple circuits
are multiplexed over shared media, and the result is known as a virtual circuit
 three general properties define a circuit switched paradigm:

 Point-to-point communication: circuit is formed between exactly


two endpoints

 Separate steps for circuit creation, use, and termination: circuit


established when needed

 Performance equivalent to an isolated physical path:


communication between two parties is not affected in any way by
communication among other parties, even if all communication is
multiplexed over a common medium
Packet Switching
communication from multiple sources competes for the use of shared media
Packet Switching
 Three general properties define a packet switched paradigm:

 Arbitrary, asynchronous communication: allow a sender to


communicate with one recipient or multiple recipients, and vs versa
 Furthermore, communication can occur at any time, and a sender
can delay arbitrarily long between successive communications

 No set-up required before communication begins: a packet


switched system remains ready to deliver a packet to any
destination at any time

 Performance varies due to statistical multiplexing among


packets: multiplexing occurs among packets, once a sender gains
access to the underlying channel, the sender transmits an entire
packet, and then allows other senders to transmit a packet
Local and Wide Area Packet Networks

Recall: Packet switching technologies are commonly classified


according to the distances they span.
Standards for Packet Format and ID

• Each packet sent across a packet network must contain the ID of the intended
recipient.
• All senders must agree on the exact details thus standards have been created by
various organizations.
 The most famous: Institute for Electrical and Electronic Engineers (IEEE)
• In 1980, IEEE organized the Project 802 LAN/MAN Standards Committee to
produce standards for networking.
IEEE 802 Model and Standards
 
IEEE 802 divides Layer 2 of the protocol stack into two conceptual sub-layers:

The Logical Link Control (LLC)


 
The LLC sublayer specifies addressing and the use of addresses for
multiplexing/demultiplexing. 

The Media Access Control (MAC)


 
The MAC sublayer specifies how multiple computers share the underlying medium.
LAN Topologies

Each network is classified into a category according to its topology (or


general shape) and MAC protocol.

Examples:

• Ethernet Bus
• Ethernet Star (hub or switch)
• Token Passing Ring
• Token Passing Bus
LAN Topologies: Bus
• Bus topology usually consists of a single cable to
which computers attach
• The ends of a bus network must be terminated to
prevent electrical signals from reflecting back
along the bus
• Any computer attached to a bus can send on the
cable and all computers receive the signal
• The computers attached to a bus network must
coordinate to prevent or manage collisions
 
LAN Topologies: Ring
• In a ring topology computers are connected in a
closed loop (with possible gateways to other
networks).
• Ring topologies usually have a direction
associated with the transmission (i.e, clockwise
or counterclockwise).
• In ring topologies, an acknowledgement of
successful transmission can be sent for free.
 
LAN Topologies: Mesh
• Mesh networks provide a direct connection
between every pair of computers.
• Main disadvantage of a mesh: Cost!
Mesh networks are not scalable.
 The number of connections needed for
a mesh network grows faster than the
number of computers.
• Because connections are expensive, few
LANs employ a mesh topology  

LAN Topologies: Star


• In star topologies, all computers attach to a
central point (or hub).
• In practice, star networks seldom have a
symmetric shape (i.e., the hub is not located
an equal distance from all computers).
 Instead, a hub often resides in a
location separate from the computers
attached to it.
Packet Identification, Demultiplexing, MAC Addresses
IEEE 802 standards include: packet addressing
Consider packets traversing a shared medium as in the figure:
 
 

• Each computer is assigned a unique address and each packet contains the address of
the intended recipient. 
• In the IEEE 802 addressing scheme, each address consists of 48 bits.
• IEEE 802 uses the term Media Access Control address (also called the MAC
address, Ethernet address or physical address).
• Each Network Interface Card (NIC) contains a unique IEEE 802 address assigned
when the device was manufactured.
• IEEE assigns a block of addresses to each vendor and allows the vendor to assign a
unique value to each device.
Unicast, Broadcast, and Multicast Addresses

The IEEE addressing supports three types of addresses that correspond to three
types of packet delivery:
 
 

• The standard specifies that a MAC broadcast address consists of 48 bits that are all 1s
(i.e., FF:FF:FF:FF:FF:FF).
• MAC broadcast can be viewed as a special form of multicast.
• Each multicast address corresponds to a group of computers.
• The Broadcast address corresponds to a group that includes all computers on the
network.
Unicast, Broadcast, and Multicast Addresses
Frames and Framing
Defn: Framing refers to the structure added to a sequence of bits or bytes that allows
a sender and receiver to specify and recognize the exact format of the message.

In a packet-switched network, each frame corresponds to a packet at Layer 2.


 
A frame consists of two conceptual parts:
1. A header that contains information used to process the frame.
2. A payload that contains the message being sent.

Notes:
• We say the the message is opaque because the network only examines the frame
header.
• The payload can contain an arbitrary sequence of bytes that are only meaningful
to the sender and receiver.
• Some technologies delineate each frame by sending a short prelude before the
frame and a short postlude after it.
Frames and Framing
 
Frames depend on the network standard to specify:
• a minimum/maximum size
• Format for the message
 
Defn: A hardware packet (or Layer 2 packet) is called a frame.
 
data communications mechanism can transfer an arbitrary 8-bit byte
mechanism is used to send packets.
Assume that a packet header consists of 6 bytes and the payload consists of an
arbitrary number of bytes.
Two special characters are used to delineate the frame :
In the ASCII character set, the Start Of Header (SOH)
the End Of Transmission (EOT)

Frame Format Used with RS-232


Case 1: Byte Stuffing with RS-232 as an Example (Cont’d)

Q: What happens when the special characters are used in the message being
transmitted?
 
A: We must translate the special characters into alternative form to avoid
confusion.
 
This is called byte stuffing.
 
 Illustration of Frame with Byte Stuffing:
Figure (a) shows the message the sending computer wishes to transmit.
Figure (b) shows the Bytes that are actually transmitted.

RS-232 Substitution Table


Case 2: Bit Stuffing with PPP as an Example

What if the transmission scheme is bit-oriented rather than byte oriented?


 
Two Real-world examples of bit stuffed networks are:
• HDLC (High-Level Data Link Control), ISO standard
• PPP (Point-to-Point Protocol)

PPP is a popular data link layer protocol for communication between two end-
points. It provides authentication, encryption, and compression. PPPoE (Point-to-
Point Protocol over Ethernet) is often used to provide a link from a modem to an ISP
(Internet Service Provider).

Bit-oriented protocols view the a frame as a collection of bits.


 
A special bit sequence 01111110 is used at both the beginning and end of frames.

01111110 111111111 control protocol check 01111110


FLAG Information (variable) FLAG

The PPP Frame Format


Case 2: Bit Stuffing with PPP as an Example (Cont’d)
Problem: This bit sequence (01111110) may occur naturally in the bit stream.
 
Solution: Use bit stuffing. Any time five consecutive 1 bits of the data message
need to be transmitted, an additional 0 is “stuffed” in following the five 1s. At the
receiving end, after five ones a 0 is always removed.

Note: Using this scheme it is not possible to make all frames the same size.

Data for transmission (passed down from upper Layer 3 at Source):

010111111011111010111111111010101
Bit-stuffed frame ready to send by Layer 2:

01111110 HEADER TRAILER 01111110

---------- DATA SENT OVER NETWORK FROM SOURCE TO DESTINATION ----------

Bit-stuffed frame received at destination Layer 2:

01111110 HEADER TRAILER 01111110

Data delivered (ready to passed up to upper Layer 3 at Destination):

You might also like