The OSI Protocol Stack:

uptightexampleΔίκτυα και Επικοινωνίες

24 Οκτ 2013 (πριν από 3 χρόνια και 7 μήνες)

53 εμφανίσεις

Computing Science @ Capilano College

The OSI Protocol Stack:

logical vs. physical communication paths

Networks and the Internet


Computing Science @ Capilano College

Computing Science @ Capilano College

A Simplified OSI Protocol Stack

Application,
Presentation, &
Session Layers


Transport &
Network Layers


Data Link &
Physical Layers

In this simplified model, we’ll use just
3 layers.
(Each is a group from the 7 layer model that
work at a similar level of abstraction)
.


Each layer provides a
protocol

that
abstracts one distinct communication
problem for the layers above.


This provides a simple, abstract
interface at each layer


a
logical
communication path

--

for sending
and receiving messages between
computers running the same protocol
at the same layer.


Computing Science @ Capilano College

Abstraction in the Protocol Stack

Application,
Presentation, &
Session Layers


Transport &
Network Layers


Data Link &
Physical Layers

The top layer is most abstract, and
provides for “whole document”
communication between applications.


The middle layer takes care of
dividing the document into a series of
packets
, that will be re
-
assembled in
the correct sequence by the receiver.


The bottom layer provides access to
the physical medium. Each bit is
encoded and sent to its destination,
where the packets are re
-
assembled.

Computing Science @ Capilano College

Logical Communications

at the Application Level

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

At the Application level, two
applications

want to exchange entire
documents
.

For example, an mail server can send a complete e
-
mail message to the mail
client application, or a web server can send a complete HTML document to a
web browser, or a file transfer application can download a file from a file server.

This layer is primarily responsible for establishing & maintaining connections to
remote computers, and allowing users to send and receive messages, files, etc.


Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Sample protocols used at this layer:

HTTP
: Hypertext documents;

FTP
: General File Transfers;

SMTP

&
POP
: e
-
mail messages


Logically transfer whole documents.

Computer 1

Computer 2

Computing Science @ Capilano College

Logical Communications

at the Packet Level

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

At the Packet level, documents are broken down into
packets



a relatively small
package of data


which are then individually
addressed
, ready for delivery. The
packets are then
routed

to their destination by sending them along to a “nearby”
computer, who will forward it along, and so on until it reaches its destination.

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Sample protocols used at this layer:

TCP
: Transport Control;

IP
: Internet Protocol;

Logically transfer whole documents.

Logically transfer packets.

Computer 1

Computer 2

Computing Science @ Capilano College

Logical Communications

at the Physical Level

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

At the Physical level, each bit in a packet is encoded for transmission across the
physical communication channel. This layer is primarily responsible for
ensuring that every bit arrives correctly at its destination, so it typically does a lot
of error checking, collision detection, and re
-
sending of garbled data.

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Logically transfer whole documents.

Logically transfer packets.

Sample protocols used at this layer:

CSMA / CD



Parity check, collision detection, & resend

Logically transfer bits.

Computer 2

Computer 1

Computing Science @ Capilano College

Physical Communications

for the sender

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Thus, the actual, physical path taken by data sent by Computer 1 would be:

1)
A document is prepared according to the application layer protocol and sent to the
Transport layer;

2)
The document is broken into packets and addressed to Computer 2. A checksum is added
to each packet for error checking, and the packets are sent to the layer below.

3)
The bits of packet are transmitted across the physical connection to Computer 2, using
parity bits and other methods to ensure they all arrive without error.

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Computer 2

Computer 1

Physical Communication Channel

(3)

(2)

(1)

Computing Science @ Capilano College

Physical Communications

along the network

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Once the data is encoded onto the physical network:

1)
The data is routed to its destination (Computer 2 in this case) by passing it along from
one computer to the next along the network;

2)
When the data reaches an intermediate computer, the packets are reassembled so that the
Network layer can determine if and where they need to be routed to next.

3)
Eventually, the data arrives at its final destination, and the physical signal is decoded
back into a stream of bits...

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Computer 2

Computer 1

Physical Communication Channel



Routers,
Servers, &
other
computers
on the
network

Computing Science @ Capilano College

Physical Communications

for the receiver

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

When the data arrives at its destination, Computer 2, it must be re
-
assembled:

1)
Parity bits on each byte are checked, and a re
-
send requested if an error is found;

the packets are re
-
assembled from the individual bits and sent up.

2)
Each packet is checked for errors, and all addresses and error codes are removed;

The packets are then reassembled in the correct order to re
-
create the original document.

3)
The complete document is now available for the application program to be saved,
displayed, or played for the user!

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Computer 2

Computer 1

Physical Communication Channel

(1)

(2)

(3)

Computing Science @ Capilano College

Physical Communications

between nodes

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Each node on the network will act as both
sender

and
receiver
:

1)
To establish and maintain the communication channel.

2)
To send packets back an forth;

3)
To acknowledge packets received or request a re
-
transmission

Application,
Presentation, &
Session Layers

Transport &
Network Layers

Data Link &
Physical Layers

Computer 2

Computer 1

Physical Communication Channel



Routers,
Servers, &
other
computers
on the
network

Computing Science @ Capilano College

Things to know about Networks


The physical communication channel could be constructed from a variety of
different mediums, including electromagnetic signal on copper wire using
amplitude or frequency modulation; or light signal on fiber
-
optic cable using
laser flashes; or RF signals, microwave signals, or infrared signals, etc.


Transmission & encoding schemes
: packet, circuit vs. packet switching,
ASCII, analog signal, wavelength, frequency, amplitude;


Network Protocols
: All protocols listed used in this presentation,
handshaking, synchronous vs. asynchronous, simplex, half
-
duplex, full
-
duplex


Error detection codes
: checksum, parity, even vs. odd parity.


Network communications
: bandwidth, broadband, server, client, router,
physical vs. logical address


Network topologies and types
: star, bus, token ring, LAN, WAN, Internet,
intranet, Ethernet, peer
-
to
-
peer, client/server