Professional Documents
Culture Documents
1
PROTOCOL
3
WHY LAYERING
4
TASKS INVOLVED IN SENDING A LETTER
5
Open Systems Interconnection
• Network architecture:
– Definition of all the layers
– Design of protocols for every layer
• By the 1970s every computer vendor had developed its
own proprietary layered network architecture
• Problem: computers from different vendors could not be
networked together
• Open Systems Interconnection (OSI) was an international
effort by the International Organization for
Standardization (ISO) to enable multivendor computer
interconnection
6
OSI Reference Model
• Describes a seven-layer abstract reference model for a
network architecture
• Purpose of the reference model was to provide a
framework for the development of protocols
• OSI also provided a unified view of layers, protocols, and
services which is still in use in the development of new
protocols
• Detailed standards were developed for each layer, but
most of these are not in use
• TCP/IP protocols preempted deployment of OSI protocols
7
7-Layer OSI Reference Model
8
OSI reference model—seven layers
• All applications are built on the top of the seven
layers, specifically, on the top of the application layer.
• The top 4 layers are end-to-end and involves the
interaction of peer entities across the network,
however, the bottom 3 layers are point-to-point and
involve the interaction of peer entities across a single
hop.
9
OSI Model
Physical Layer
• Provides physical interface for transmission of information.
• Defines rules by which bits are passed from one system to another on a physical
communication medium.
• Covers all - mechanical, electrical, functional and procedural - aspects for physical
communication.
• Such characteristics as voltage levels, timing of voltage changes, physical data rates,
maximum transmission distances, physical connectors, and other similar attributes are
defined by physical layer specifications.
• Converts bits into electronic signals for outgoing messages
• Converts electronic signals into bits for incoming messages
• This layer manages the interface between the computer and the network medium (coax,
twisted pair, etc.)
• This layer tells the driver software for the MAU (media attachment unit, ex. network
interface cards (NICs, modems, etc.)) what needs to be sent across the medium
• The bottom layer of the OSI model
10
OSI Model
11
Sub-layers of the Data Link Layer
• MAC (Media Access Control)
– Gives data to the NIC
– Controls access to the media through:
• CSMA/CD Carrier Sense Multiple Access/Collision
Detection
• Token passing
• LLC (Logical Link Control)
– Manages the data link interface (or Service Access Points (SAPs))
– Can detect some transmission errors using a Cyclic Redundancy
Check (CRC). If the packet is bad the LLC will request the sender to
resend that particular packet.
OSI Model
Network Layer
• Implements routing of frames (packets) through the network.
• Defines the most optimum path the packet should take from the
source to the destination
• Defines logical addressing so that any endpoint can be identified.
• Handles congestion in the network.
• Facilitates interconnection between heterogeneous networks
(Internetworking).
• The network layer also defines how to fragment a packet into
smaller packets to accommodate different media.
13
Transport Layer
• Purpose of this layer is to provide a reliable mechanism for
the exchange of data between two processes in different
computers.
• Ensures that the data units are delivered error free.
• Ensures that data units are delivered in sequence.
• Ensures that there is no loss or duplication of data units.
• Provides connectionless or connection oriented service.
• Provides for the connection management.
• Multiplex multiple connection over a single channel.
14
Session Layer
• Session layer provides mechanism for controlling the dialogue
between the two end systems. It defines how to start, control and
end conversations (called sessions) between applications.
• This layer requests for a logical connection to be established on
an end-user’s request.
• Any necessary log-on or password validation is also handled by
this layer.
• Session layer is also responsible for terminating the connection.
• This layer provides services like dialogue discipline which can be
full duplex or half duplex.
• Session layer can also provide check-pointing mechanism such
that if a failure of some sort occurs between checkpoints, all data
can be retransmitted from the last checkpoint.
15
OSI Model
Presentation Layer
• Presentation layer defines the format in which the data is to
be exchanged between the two communicating entities.
• Also handles data compression and data encryption
(cryptography).
16
OSI Model
Application Layer
• Application layer interacts with application programs and is
the highest level of OSI model.
• Application layer contains management functions to
support distributed applications.
• Examples of application layer are applications such as file
transfer, electronic mail, remote login etc.
17
7 Application OSI REFERENCE MODEL SUMMARY
18
7 Application OSI REFERENCE MODEL SUMMARY
19
7 Application OSI REFERENCE MODEL SUMMARY
3 Network • Internetworking
• Routing algorithms
• Internet Protocol (IP) addressing
2 Data Link • Routers
1 Physical
20
7 Application OSI REFERENCE MODEL SUMMARY
Main topics:
4 Transport
• Connection-oriented and connectionless services
• Transmission Control Protocol (TCP)
3 Network • User Datagram Protocol (UDP)
2 Data Link
1 Physical
21
7 Application OSI REFERENCE MODEL SUMMARY
3 Network d) Synchronization.
2 Data Link
1 Physical
22
7 Application OSI REFERENCE MODEL SUMMARY
2 Data Link
1 Physical
23
7 Application OSI REFERENCE MODEL SUMMARY
1 Physical
24
OSI MODEL IN A NUT SHELL
25
OSI Model
26
An exchange using the OSI model
27
A private internet
28
Communication at the physical layer
29
The unit of communication at the physical
layer is a bit.
30
Communication at the data link layer
Physical Physical
Link 1 Link 3 Link 5 Link 6
D2 H2
Frame
D2 ame
Fr
H2
D2 H2 D2 H2
Frame Frame
31
The unit of communication at the data link
layer is a frame.
32
Communication at the network layer
Physical Physical
D3 H3
Datagram
D3 H3
Datagram
33
The unit of communication at the network
layer is a datagram.
34
Communication at transport layer
Physical Physical
D4 H4
Segment
D4 H4
Segment
35
The unit of communication at the transport
layer is a segment, user datagram, or a
packet, depending on the specific protocol
used in this layer.
36
Communication at application layer
A B
Application Legend Source Destination D Data H Header Application
Transport Transport
R1 R3 R4
Network Network
Physical Physical
D5 D5
Message
D5 D5
Message
37
The unit of communication at the
application layer is a message.
38
TCP/IP Protocol Suite
• Most widely used interoperable network protocol
architecture
• Specified and extensively used before OSI
– OSI was slow to take place in the market
• Funded by the US Defense Advanced Research
Project Agency (DARPA) for its packet switched
network (ARPANET)
– DoD automatically created an enormous market for
TCP/IP
• Used by the Internet and WWW
39
TCP/IP Protocol Suite
• TCP/IP does not have an official layer structure
• But protocols imply one
– Application layer
– Transport (host to host) layer
– Internet layer
– Network access layer
– Physical layer
40
OSI vs. TCP/IP
HTTP, SMTP, …
TCP, UDP
IP
41
Network Access and Physical Layers
• TCP/IP reference model does not discuss these
layers too much
– the node should connect to the network with a
protocol such that it can send IP packets
– this protocol is not defined by TCP/IP
– mostly in hardware
– a well known example is Ethernet
42
Internet Layer
• Connectionless, point to point internetworking
protocol (uses the datagram approach)
– takes care of routing across multiple networks
– each packet travels in the network independently of
each other
• they may not arrive (if there is a problem in the network)
• they may arrive out of order
– a design decision enforced by DoD to make the system
more flexible and responsive to loss of some subnet
devices
• Implemented in end systems and routers as the
Internet Protocol (IP)
43
Transport Layer
• End-to-end data transfer
• Transmission Control Protocol (TCP)
– connection oriented
– reliable delivery of data
– ordering of delivery
• User Datagram Protocol (UDP)
– connectionless service
– delivery is not guaranteed
• Can you give example applications that use TCP
and UDP?
44
Application Layer
• Support for user applications
• A separate module for each different
application
– e.g. HTTP, SMTP, telnet
45
IP (Internet Protocol)
• The core of the TCP/IP protocol suite
• Two versions co-exist
– v4 – the widely used IP protocol
– v6 – has been standardized in 1996, but still not widely deployed
• IP (v4) header minimum 20 octets (160 bits)
46
IPv6
• IPv6
– Enhancements over IPv4 for modern high speed
networks
– Support for multimedia data streams
• But the driving force behind v6 was to increase
address space
– 128-bit as compared to 32-bit of v4
• Not backward compatible
– all equipment and software must change
– that is why it will take some more time to migrate into
IPv6
47
TCP
• Transmission Control Protocol
– end to end protocol
– Reliable connection = provides flow and error control
• In TCP terms, a connection is a
temporary association between entities in different
systems
• TCP PDU
– Called “TCP segment”
– Includes source and destination port
• Identify respective users (applications)
• pair of ports (together with the IP addresses) uniquely identify
a connection; such an identification is necessary in order TCP
to track segments between entities.
48
TCP Header
49
UDP
• User Datagram Protocol
• Alternative to TCP
– end-to-end protocol
• Not guaranteed delivery
• No preservation of sequence
• No protection against duplication
• Minimum overhead
50
PDUs in TCP/IP
Dest. Port
Sequence number
Checksum
….
Dest. Address
Source address
….
52
Sending a packet from Argon to Neon
argon.tcpip-lab.edu neon.tcpip-lab.edu
"Argon" "Neon"
128.143.137.144 128.143.71.21
router137.tcpip-lab.edu router71.tcpip-lab.edu
"Router137" "Router71"
128.143.137.1 128.143.71.1
Router
53
Sending a packet from
128.143.71.21 Argon
is not to
on my local Neon
network.
Therefore, I need to send the packet to my
128.143.71.21
default gateway withisaddress
on my local network.
128.143.137.1
DNS:
DNS:
ARP:What
The is
WhatIPisthe
address
theIPMAC
address
of Therefore, I can send the packet directly.
of“neon.tcpip-lab.edu”
“neon.tcpip-lab.edu”?
address
ARP: TheofMAC is of
128.143.137.1?
address
128.143.71.21
128.143.137.1 is 00:e0:f9:23:a8:20
ARP: What is the MAC
ARP: TheofMAC
address address of
128.143.71.21?
argon.tcpip-lab.edu
"Argon"
128.143.137.1 is neon.tcpip-lab.edu
00:20:af:03:98:28
"Neon"
128.143.137.144 128.143.71.21
router137.tcpip-lab.edu router71.tcpip-lab.edu
"Router137" "Router71"
128.143.137.1 128.143.71.1
Router
frame frame
54