OSI Reference Model - WordPress – www.wordpress.com

jinkscabbageNetworking and Communications

Oct 23, 2013 (4 years and 20 days ago)

77 views

OSI  Reference  Model  
Heng
 
Sovannarith
 
heng_sovnanarith@yahoo.com  
Introduc=on  


In  the  1980s,  
the  European-­‐dominated  Interna1onal  
Standards  Organiza1on  (ISO)
,  began  to  develop  its  
Open  Systems  Interconnec1on  (OSI)  
networking  suite.    


It  is  now  considered  the  primary  architectural  model  
for  
inter-­‐compu1ng  and  internetworking  
communica1ons.  


To  allow  different  types  of  
network  hardware  and  
so?ware  to  communica1on  with  each  other  


To  breaks  network  communica=on  into  smaller,  
simpler  parts  that  are  easy  to  develop  


To  facili=es  standardiza=on  of  network  components  to  
allow  mul=ple  –  vendor  development  and  support  
Introduc=on  (cont.)  


Allow  
two  different  Machines  to  connect  
without  change  
in  hardware  and  soNware  


Designed  for  communica=on  across  
all  types  
of  computer  system  


It  defines  
seven  separated  layers  
but  related  
to  each  other.    
Introduc=on  (cont.)  


The  seven  layers  of  the  OSI  model  can  be  divided  into  two  
groups
:  upper  layers  (layers  7,  6,  5  &  4)  
and  
lower  layers  
(layers  3,  2,  1).    


The  upper  layers  of  the  OSI  model  deal  with  
applica1on  
issues
 and  generally  are  
implemented  only  in  so?ware
.    


The  highest  layer,  
the  applica1on  layer
,  is  closest  to  the  
end  user.    


The  lower  layers  of  the  OSI  model
 handle  data  transport  
issues.    


 The  lowest  layer,  
the  physical  layer
,  is  closest  to  the  
physical  network  medium  (the  wires,  for  example)  and  is  
responsible  for  placing  data  on  the  medium.  
Physical  Layer  


The  
Physical  Layer
 describes  
the  physical  
proper1es
 of  the  various  communica=ons  media,  
as  well  as  
the  electrical  proper1es  and  
interpreta1on  of  the  exchanged  signals
.  


This  layer  is  responsible  for  
moving  bits  across  
a  
shared  media  between  two  points.  


The  OSI  Model's  layer  1,  the  Physical  
Layer,  outlines  
the  characteris1cs  of  the  physical  
medium
 between  networked  devices-­‐-­‐cabling,  
wiring,  fiber  strands  and  the  air.    
Physical  Layer  (cont.)  


The  Physical  layer  
has  two  responsibili1es,  
send  and  receive  bits
 (bits  have  a  value  of  1  or  
0)  from  the  physical  medium  (copper  wire,  
fiber,  radio  frequencies,  barbed  wire,  string  
etc.)  .  


Ex:  this  layer  defines  the  size  of  Ethernet  
coaxial  cable,  the  type  of  BNC  connector  used,    
the  maximum  length  of  cable  and  so  on.  
Physical  Layer  (cont.)  


One  type  of  Physical  layer  device  commonly  
used  in  networks  is  
a  repeater
.    


A  repeater/hub  
is  used  to  regenerated  the  
signal  whenever  you  need  to  exceed  the  cable  
length  allowed  by  the  Physical  layer  standard.  


They  
don’t  examine  the  contents  of  the  
packet
 they  regenerated.  If  they  did,  they  
would  be  networking  a  the  Data  Link  Layer  
and  not  a  the  Physical  Layer  
Data  Link  Layer  


The  Data  Link  layer  provides  reliable  transit  of  data  
across  a  physical  network  link.      


Different  Data  Link  layer  specifica=ons  define  different  
network  and  protocol  characteris=cs,  
including  
physical  addressing
,  
network  topology
,  
error  
no1fica1on
,  
sequencing  of  frames
,  and  
flow  control
.    


 The  Data  Link  layer  translates  messages  from  the  
Network  layer  into  bits  for  the  Physical  layer  to  
transmit.    It  formats  messages  into  data  frames  and  
adds  a  customized  header  containing  the  source  and  
des=na=on  hardware  addresses.    
Data  Link  Layer  


Data  Link  layer  is  responsible  for  uniquely  iden=fying  each  
device  on  a  local  network.  


Physical  addressing
 (as  opposed  to  network  addressing)  defines  
how  devices  are  addressed  at  the  data  link  layer.  


Network  topology
 consists  of  the  data  link  layer  specifica=ons  
that  oNen  define  how  devices  are  to  be  physically  connected,  
such  as  in  a  bus  or  a  ring  topology.  


Error  no6fica6on
 alerts  upper-­‐layer  protocols  that  a  
transmission  error  has  occurred,  and  the  sequencing  of  data  
frames  reorders  frames  that  are  transmi\ed  out  of  sequence.  


Flow  control
 moderates  the  transmission  of  data  so  that  the  
receiving  device  is  not  overwhelmed  with  more  traffic  than  it  
can  handle  at  one  =me.  
Data  Link  Layer  


Ex:  this  layer  defines  the  framing,  addressing  
and  
checksumming
 of  Ethernet  packets.  


Data  link  protocols  address  things  such  as  the  
size  of  each  packet  of  data  to  be  sent,  a  mean  
of  addressing  each  packet  so  that  it’s  
delivered  to  the  intended  recipient,  and  the  
way  to  ensure  that  two  or  more  nodes  don’t  
try  to  transmit  data  on  the  network  at  the  
same  =me  
Data  Link  Layer  (cont.)  


The  Data  Link  layer  also  provide  the  basic  error  
detec=on  and  correc=on  to  ensure  that  the  data  sent  
is  the  same  as  the  data  received.  


If  an  uncorrectable  error  occurs,  the  data  link  standard  
must  specify  how  the  node  is  be  informed  of  the  error  
so  that  it  can  retransmit  the  data.  


At  the  Data  Link  layer,  each  device  on  network  has  an  
address  known  as  
MAC  (  Media  Access  Control)  
address  


Two  types  of  Data  Link  layer  devices  are  
bridges
 and  
switches  
Data  Link  Layer  (cont.)  


One  of  the  most  import  func=ons  of  the  Data  
Link  layer  is  to  provide  a  ways  for  packet  to  be  
send  safely  over  the  physical  media  with  
interference  from  other  nodes  a\emp=ng  to  
send  packet  at  the  same  =me.  


Two  popular  way  to  do  this  are  CSMA/CD  (Carrier  
Sense  Mul=ple  Access  with  Collision  Detec=on)  
and  token  passing.  


Ethernet  network  use  CSMA/CD  


Token  Ring  networks  use  token  passing  
Data  Link  Layer  (cont.)  


Carrier  sense  
mean  that  whenever  a  device  wants  to  
send  a  packet  over  the  network  media,  it  first  listens  to  
the  network  media  to  see  whether  anyone  else  is  
ready  sending  a  packet.  If  it  doesn’t  hear  any  other  
signals  on  the  media,  the  computer  assumes  that  the  
network  is  free,  so  it  sends  the  packet.  


Mul1ple  access  
mean  that  nothing  prevents  two  or  
more  devices  from  trying  to  send  a  message  at  the  
same  =mes.  However,  supposed  that  two  devices  
listen,  hear  nothing,  and  then  proceed  to  send  their  
packets  at  the  same  =me?    
Data  Link  Layer  (cont.)  


Collision  detec1on  
means  that  aNer  a  device  
sends  a  packet,  it  listens  carefully  to  see  
whether  the  packet  crashes  into  other  packet.  
If  there  is,  it  wait  a  random  period  of  =mes  
and  then  tries  to  send  the  packet  again.    
Data  Link  Layer  (cont.)  


It  should  be  noted  that  in  most  modern  
network  interface  adaptors,  the  Physical  and  
Data  link  func=ons  are  performed  by  the  
network  interface  adaptor.  
Data  Link  Layer  (cont.)  


The  Data-­‐Link  layer  consists  of  two  
sublayers
 –  
Logical  Link  Control  (LLC)  and  Media  Access  Control  
(MAC)  


Logical  Link  Control  (LLC)  
sublayer
   


It  serve  as  the  intermediary  between  the  physical  link  
and  all  higher  layer  protocols.  


It  ensures  that  protocols  like  IP  can  func=on  regardless  
of  what  type  of  physical  technology  is  being  used.  


Addi=onally,  the  LLC  
sublayer
 can  perform  flow-­‐control  
and  
errorchecking
,  though  such  func=ons  are  oNen  
provided  by  Transport  layer  protocols,  such  as  TCP.  
Data  Link  Layer  (cont.)  


Media  Access  Control  (MAC)  
sublayer
 


The  MAC  
sublayer
 controls  access  to  the  
physical  medium,  serving  as  mediator  if  
mul=ple  devices  are  compe=ng  for  the  same  
physical  link.  


Datalink
 layer  technologies  have  various  
methods  of  accomplishing  this  -­‐  Ethernet  uses  
Carrier  Sense  Mul=ple  Access  with  Collision  
Detec=on  (CSMA/CD),  and  Token  Ring  u=lizes  a  
token.    
Network  Layer  


The  Network  layer  provides  
rou1ng
 and  
related  func1ons  
that  enable  mul1ple  data  links  to  be  combined  into  an  
internetwork
.  


The  Network  Layer  describes  
how  a  series  of  exchanges  
over  various  data  links  can  deliver  data  
between  any  two  
nodes  in  a  network  


This  is  accomplished  by  the  
logical  addressing
 (as  opposed  
to  the  physical  addressing)  of  devices.    


The  network  layer  supports  both  
connec1on-­‐oriented  
and  
connec1onless  service  
from  higher-­‐layer  protocols.  


Routers
 work  at  this  level  and  provide  
the  rou1ng  services  
for  an  internetwork.  
Network  Layer  (cont.)  


The  Network  layer  (Layer-­‐3)  controls  
internetwork  communica=on,  and  has  two  key  
responsibili=es:    


Logical  addressing
 –  provides  a  unique  address  
that  iden=fies  both  the  host,  and  the  network  that  
host  exists  on.    


Rou1ng  
–  determines  the  best  path  to  a  par=cular  
des=na=on  network,  and  then  routes  data  
accordingly  
Network  Layer  (cont.)  


Two  of  the  most  common  Network  layer  
protocols  are:  


Internet  Protocol  (IP)  


Novell’s  Internetwork  Packet  Exchange  (IPX).  


IPX  is  almost  en=rely  deprecated.  IP  version  4  
(IPv4)  and  IP  version  6  (IPv6)  are  covered  in  
nausea=ng  detail  in  other  chapter.    
Network  Layer  (cont.)  


Rou1ng  a  Packet
 


The  router  receives  
the  packet  
and  
looks  up  
the  
des1na1on  IP  address
.  


If  the  packet  
isn't  des1ned  
for  the  router,  the  
router  looks  for  the  des=na=on  address  in  
the  
rou1ng  table
.  


Once  
the  des1na1on  interface  
is  found,  the  
packet  will  be  sent  to  the  interface.  


At  the  des=na=on  interface
,  the  packet  is  framed  
and  sent  out  
on  the  local  network.  
Network  Layer  (cont.)  


There  are  two  types  of  packets  at  the  Network  
layer.  


Data  Packets
 


Used  to  transport  user  data  through  internetwork.  


Uses  routed  protocols  such  as:  IP  and  IPX.  


Router  Update  Packets
 


Used  to  update  neighbor  routers  about  networks  
connected  to  routers  on  the  internetwork.  


Rou=ng  protocols:  RIP,  EIGRP,  OSPF.  


Builds  and  maintains  rou=ng  tables  on  each  router.  
Network  Layer  (cont.)  


The  
network
 layer  is  concerned  with  the  
following  primary  func=ons:  


Communica=on  with  the  Transport  layer  above.  


Encapsula=on  of  Transport  data  
into  
Network
 layer  Protocol  Data  Units  
-­‐-­‐  
(Packet).  


Management  of  connec=vity  and  rou=ng  between  
hosts  or  networks.  


Communica=on  with  the  
data  link
 layer  below.  
Transport  Layer  


The  
Transport  Layer
 describes  the  quality  and  
nature  of  the  data  delivery.    


It  does  
not  actually  send  data
,  despite  its  name.  
Instead,  this  layer  is  responsible  for  
the  reliable  
transfer  of  data
,  by  ensuring  that  data  arrives  at  
its  des=na=on  
error-­‐free
 and  
in  order
.  


The  transport  layer  implements  
reliable  
internetwork  data  transport  services  
that  are  
transparent  to  upper  layers.    
Transport  Layer  (cont.)  


Transport  layer  communica=on  falls  under  
two  categories:    


Connec1on-­‐oriented
 –  requires  that  a  connec=on  
with  specific  agreed-­‐upon  parameters  be  
established  before  data  is  sent.    


Connec1onless
 –  requires  no  connec=on  before  
data  is  sent.  
Transport  Layer  (cont.)  


Connec=on-­‐oriented  protocols  provide  several  
important  services:      


Segmenta1on  and  sequencing  
–  data  is  segmented  into  
smaller  pieces  for  transport.  Each  segment  is  assigned  a  
sequence  number,  so  that  the  receiving  device  can  
reassemble  the  data  on  arrival.  


Connec1on  establishment  
–  connec=ons  are  established,  
maintained,  and  ul=mately  terminated  between  devices.  


Acknowledgments  
–  receipt  of  data  is  confirmed  through  
the  use  of  acknowledgments.  Otherwise,  data  is  
retransmi\ed,  guaranteeing  delivery.    


Flow  control  (or  windowing)  
–  data  transfer  rate  is  
nego=ated  to  prevent  conges=on.    
Transport  Layer  (cont.)  
Transport  Layer  (cont.)  


The  TCP/IP  protocol  suite  incorporates  two  
Transport  layer  protocols:    


Transmission  Control  Protocol  (TCP)
 –  
connec=on-­‐oriented    


User  Datagram  Protocol  (UDP)
 -­‐  connec=onless  
Transport  Layer  (cont.)  


Transport-­‐layer  func=ons  typically  
include  
flow  control
,  
mul1plexing
,  
virtual  
circuit  management
,  and  
error  checking  and  
recovery
.  


They  provide  end-­‐to-­‐end  data  transport  
services  and  can  establish  a  logical  connec=on  
between  the  sending  host  and  des=na=on  
host  on  an  Internetwork.  
Transport  Layer  (cont.)  


Flow  Control  


Data  integrity  is  ensured  by  maintaining  flow  control  
and  allowing  users  the  op=on  to  request  reliable  data  
transport  between  systems.    


Flow  control  manages  data  transmission  between  
devices  so  that  the  transmiing  device  does  not  send  
more  data  than  the  receiving  device  can  process.  


 Reliable  data  transport  employs  a  connec=on-­‐
oriented  communica=on  session  between  systems.  
Transport  Layer  (cont.)  


The  protocols  ensure  that  the  following  are  
achieved:  


segments  delivered  are  acknowledged  to  sender  upon  
delivery.  


non  acknowledged  segments  are  re-­‐sent.  


segments  are  put  back  in  sequence  upon  arrival  at  their  
des=na=on.  


a  manageable  data  flow  is  maintained  to  avoid  
conges=on,  overloading,  and  data  loss.  
Transport  Layer  (cont.)  


Mul=plexing  


The  Transport  layer  is  responsible  for  providing  
mechanisms  for  mul=plexing  upper  layer  applica=ons.    


Mul=plexing  enables  data  from  several  applica=ons  to  
be  transmi\ed  onto  a  single  physical  link.  


Virtual  Circuit  


Virtual  circuits  (a  path  between  points  in  a  network)    
are  established,  maintained,  and  terminated  by  the  
transport  layer.  
Transport  Layer  (cont.)  


Error  Checking  and  Recovery  


Error  checking  involves  crea=ng  various  
mechanisms  for  detec=ng  transmission  errors,  
while  error  recovery  involves  taking  an  ac=on,  
such  as  reques=ng  that  data  be  retransmi\ed,  to  
resolve  any  errors  that  occur.  
Session  Layer  


The  session  layer  
establishes,  manages,  and  
terminates  communica1on  sessions
 between  
presenta=on  layer  en==es.    


If  a  session  is  
broken
,  this  layer  can  a\empt  to  
recover  the  session.    


Communica=on  sessions  
consist  of  service  
requests  and  service  responses  
that  occur  
between  applica=ons  located  in  different  
network  devices.  
Session  Layer  (cont.)  


These  requests  and  responses  are  coordinated  
by  protocols  implemented  at  the  session  
layer.  


Also  provides  
dialog  control  
(The  exchange  of  
informa=on  between  two  systems  on  the  
network  is  called  a  dialog)  between  devices  or  
nodes.  
Session  Layer  (cont.)  


Coordinates  and  organizes  communica=ons  
between  system  by  offering  three  different  
modes:  simplex,  half-­‐duplex,  and  full-­‐duplex.  


Full-­‐Duplex  
–  simultaneous  two-­‐way  communica=on    


Half-­‐Duplex  
–  two-­‐way  communica=on,  but  not  
simultaneous    


Simplex
 –  one-­‐way  communica=on  


The  layer  basically  keeps  different  
applica1ons'  
data
 separate  from  
other  applica1ons'  data
.  
Session  Layer  (cont.)  


Many  modern  protocol  suites,  such  as  TCP/IP,  
do  not  implement  Session  layer  protocols.  
Connec1on  management  
is  oNen  controlled  
by  lower  layers,  such  as  the  Transport  layer.    


Example  of  Session  Layer  Protocols:  
NFS,  
Network  File  System,  developed  by  Sun  
Microsystems  and  used  with  TCP/IP  and  Unix  
worksta=ons  to  allow  transparent  access  to  
remote  resources.    
Presenta=on  Layer  


The  Presenta=on  Layer  (Layer  6)  defining  
data  
formats
,  such  as  ASCII  text,  EBCDIC  text,  binary,  
BCD,  and  JPEG.  


Encryp1on  
also  is  defined  as  a  presenta=on  layer  
service.  


This  ensures  that  data  from  the  sending  
applica=on  can  be  
understood  by  the  receiving  
applica1on.      


Examples  include:  JPEG,  ASCII,  EBCDIC,  TIFF,  GIF,  
PICT,  encryp=on,  MPEG,  and  MIDI.  
Presenta=on  Layer  (cont.)  


If  two  devices  do  not  support  
the  same  
format  or  syntax
,  the  Presenta=on  layer  can  
provide  
conversion  or  transla1on  services  
to  
facilitate  communica=on.  


These  func=ons  can  also  be  performed  at  
lower  layers  as  well.  For  example,  the  
Network  layer  can  perform  encryp=on,  using  
IPSec
.  
Applica=on  Layer  


The  Applica=on  Layer  (Layer  7)  refers  to  
communica1ons  services  
to  applica=ons  and  is  the  
interface  between  the  network  and  the  applica=on.    


A  web  browser
 and  
an  email  client
 are  examples  of  
user  applica=ons.    


It    is  the  
OSI  layer  closest  to  the  end  user
,  which  
means  that  both  the  OSI  applica=on  layer  and  the  user  
interact  directly  with  the  soNware  applica=on.  


Examples  include:  Telnet,  HTTP,  FTP,  Internet  
browsers,  NFS,  SMTP  gateways  
Applica=on  Layer  (cont.)  


The  user  applica=on  itself  does  not  reside  at  
the  Applica=on  layer  –  
the  protocol  does
.    


The  user  interacts  with  the  applica=on,  which  
in  turn  interacts  with  
the  applica1on  
protocol
.  
Protocol  Data  Unit  


PDU  is  Informa=on  that  is  delivered  as  a  unit  among  
peer  en==es  of  a  network  and  that  may  contain  
control  informa=on,  address  informa=on,  or  data.  


PDUs  are  relevant  in  rela=on  to  each  of  the  first  4  
layers  of  the  OSI  model  as  follows:  


The  Layer  1  (Physical  Layer)  PDU  is  the  bit  


The  Layer  2  (Data  Link  Layer)  PDU  is  the  frame  


The  Layer  3  (Network  Layer)  PDU  is  the  packet  


The  Layer  4  (Transport  Layer)  PDU  is  the  segment  (e.g.  TCP  
segment)  


 (Layer  5  and  above  are  referred  to  as  data.)  
Five  Conversion  Steps  of  Data  
Encapsula=on  in  OSI  Reference  Model  


Data
 >>  
Segments
>>  
Packets
 >>  
Frames
 >>  
Bits  
1.

Upper  layers  convert  and  format  the  informa=on  
into  
data
 and  send  it  to  the  Transport  Layer.  
2.

The  Transport  layer  turns  the  data  into  
segments
 and  adds  
headers  then  sends  them  to  the  Network  layer.  
3.

The  Network  layer  receives  the  segments  and  converts  them  
into  
packets
 and  adds  header  informa=on  (logical  addressing)  
and  sends  them  to  the  Data  Link  Layer.  
4.

The  Data  Link  layer  receives  the  packets  and  converts  them  
into  
frames
 and  adds  header  informa=on  (physical  source  and  
des=na=on  addresses)  and  sends  the  frames  to  the  Physical  
Layer.  
5.

The  Physical  layer  receives  the  frames  and  converts  them  
into  
bits  
to  be  put  on  the  network  medium.  
Summary  
Applica1on
 
-­‐File,  prin=ng,  message,  database,  and  applica=on  services.  
Presenta1on
 
-­‐Data  encryp=on  /  decryp=on,  compression,  and  transla=ng  
services.  
Session
 
-­‐Dialog  control.  
Transport
 
-­‐End  to  end  connec=on.  
Network
 
-­‐Rou=ng.  
Data  Link
 
-­‐Framing.  
Physical
 
-­‐Physical  topology.  
TCP/IP  and  the  OSI  model