Layered Architecture

inexpensivedetailedNetworking and Communications

Oct 23, 2013 (4 years and 2 months ago)

97 views

Page 1
EEC 189Q:
Computer Networks
Layered Architecture
Reference: Chapter 2.1-2.2, 2.3.1
Chuah, Fall 2004
2
Recap from last lecture …
 Circuit vs. Packet switching
 Multiplexing strategies
- Deterministic vs. statistical multiplexing
 Fundamental issues in networking
Communication network is a complex, distributed system
- How do we implement it? How do we control it?
Page 2
Chuah, Fall 2004
3
What is The Internet?
 The Internet :
- Collection of networks and routers that span the world and
use the TCP/IP protocols to form a single, cooperative virtual
network
 intranet:
connection of different LANs within an organization
- private
- may use leased lines
- usually small, but possibly hundreds of routers
- may be connected to the Internet (or not), often by
firewall
Chuah, Fall 2004
4
Elements of a Network
• Hosts, end-systems
– pc’s, workstations, servers
– PDA’s, phones, toasters
running network apps
• Communication links
– Point-to-point, multi-access
– fiber, copper, radio, satellite
• Routers:forward packets
(chunks) of data thru network
• Internet: network of networks
• Internet is a specific internet
local ISP
company
network
regional ISP
router
workstation
server
mobile
Page 3
Chuah, Fall 2004
5
Internet Architecture
LANs
International
lines
ISP ISPcompany
university
national
network
regional
network
NAP
on-line
services
company
access via
modem
Chuah, Fall 2004
6
Backbone
ISP
ISP
Internet Structure: Network of Networks
 Roughly hierarchical
 Internet backbone (core)
- Tier-1 ISPs (e.g., AT&T, Sprint, UUNet, BBN/Genuity) providing
national/international coverage
 Regional ISPs (Tier-2, Tier-3)
 Access networks at the edge
- Residential, enterprise, campus network, small local ISPs
Page 4
Chuah, Fall 2004
7
NAPs, NSPs, ISPs
 NSP: National Service Provider (Tier 1 Backbones)
- Example: Internet MCI, Sprint Link, UUNET
 NAP: National Access Point
NAPNAP
NAPNAP
NAPNAP
NAPNAP
National ProviderNational Provider
National ProviderNational Provider
Regional Regional
ProviderProvider
POPPOP
customerscustomers
Chuah, Fall 2004
8
Internet
Network
Leveraging Sprint’s SONET-based, gigabit switch Internet
backbone
Private
Peering
Private
Peering
Private
Peering
MAE-West
Exchange Point
Pacific Bell
Exchange Point
Private
Peering
Ameritech
Exchange Point
Private
Peering
Private
Peering
Sprint
Exchange Point
Private
Peering
MAE-East
Exchange Point
Private
Peering
Page 5
Chuah, Fall 2004
9
Sprint
Network
Click here for
a closer look
at the Sprint
network on the
East Coast
Click here for
a closer look
at the Sprint
network in
Northern
California
Pearl City in Hawaii is
a future network location
Click here for a closer look at the
Sprint network in Washington state
Legend
DS3
OC3
OC12
OC48
Seattle
Atlanta
Chicago
Roachdale
Stockton
San Jose
Anaheim
Fort Worth
Orlando
Kansas City
Cheyenne
New York
Pennsauken
Relay
Wash. DC
Tacoma
Chuah, Fall 2004
10
Page 6
Chuah, Fall 2004
11
Chuah, Fall 2004
12
Links for Long Haul Transmission
 Types of links
- DS1/T1: 1.544 Mbps (24x 64Kbps)
- DS3/T3: 44.736 Mbps
- STS-1/OC-1: 51.84 Mbps
- STS-3/OC-3: 155.2 Mbps
- STS-12/OC-12: 622.080 Mbps
- STS-48/OC-48: 2.488 Gbps
- STS-192/OC-192: 9.953 Gbps
 Higher levels of services
offered commercially
- Frame Relay
- ATM
 Possibilities
- IP over SONET
- IP over ATM
- IP over Frame Relay
- IP over WDM
Page 7
Chuah, Fall 2004
13
How do we study this cloud of network?
 How was it designed?
 Why is the Internet the way it is today?
 Can we reduce its complexity to something
tractable?
Chuah, Fall 2004
14
Layered Architecture
 Layering simplifies the architecture of
complex system
 Layer N relies on services from layer N-1
to provide a service to layer N+1
 Interfaces define the services offered
 Service required from a lower layer is
independent of it’s implementation
- Information/complexity hiding
- Layer N change doesn’t affect other layers
- Similar to object oriented methodology
Page 8
Chuah, Fall 2004
15
Protocols
 Protocol: rules by which network elements communicate
 Protocols define the agreement between peering entities
- The format and the meaning of messages exchanged
 Protocols in everyday life
- Examples: traffic control, open round-table discussion etc
Chuah, Fall 2004
16
Protocols and Services
 Protocols are used to implement services
- Peering entities in layer N provide service by communicating
with each other using the service provided by layer N-1
 Logical vs physical communication
Page 9
Chuah, Fall 2004
17
ISO OSI Reference Model
 ISO – International Standard Organization
 OSI – Open System Interconnection
 Started to 1978; first standard 1979
- ARPANET started in 1969; TCP/IP protocols ready by
1974
 Goal: a general open standard
- Allow vendors to enter the market by using their own
implementation and protocols
Chuah, Fall 2004
18
OSI Reference Model
Application
Presentation
Session
Transport
Network
Datalink
Physical
OSI Protocol Stack
OSI: conceptually define service, interface,
& protocol
 Service – says what a layer does
 Interface – says howto access the
service
 Protocol – says howis the service
implemented
- A set of rules and formats that govern the
communication between two peers
Page 10
Chuah, Fall 2004
19
ISO OSI Reference Model
 Seven layers
- Lower three layers are peer-to-peer
- Next four layers are end-to-end
Application
Presentation
Session
Transport
Network
Datalink
Physical
Application
Presentation
Session
Transport
Network
Datalink
Physical
Network
Datalink
Physical
Physical medium
Peer-layer communication
Layer-to-layer communication
Chuah, Fall 2004
20
Data Transmission
 A layer can use only the service provided by the layer
immediate below it
 Each layer may change and add a header to data packet
data
data
data
data
data
data
data
data
data
data
data
data
data
data
Page 11
Chuah, Fall 2004
21
Protocol Packets
 Protocol data units (PDUs): packets exchanged between peer entities
 Service data units (SDUs): packets handed to a layer by an upper layer
 Data at one layer is encapsulated in packet at a lower layer
- Envelope within envelope: PDU = SDU + (optional) header or trailer
Chuah, Fall 2004
22
Implementation of Layers
Page 12
Chuah, Fall 2004
23
Physical Layer (1)
 Service: transmitting raw bits (0/1) over
wire/physical link between two systems
 Interface:specifies how to send a bit
 Protocol:coding scheme used to represent a bit,
voltage levels, duration of a bit
 Examples: coaxial cable, optical fiber links;
transmitters, receivers
Bits
0 0 01 1 1 1 1 0 0 0 0 0 0 11
NRZ
+V
-V
Chuah, Fall 2004
24
Datalink Layer (2)
 Service:
- Framing, i.e., attach frames separator
- Send data frames between peers attached to the same physical
media
- Others (optional):
• Arbitrate the access to common physical media
• Ensure reliable transmission
• Provide flow control
 Interface:send a data unit (packet) to a machine
connected to the samephysical media
 Protocol:layer addresses, implement Medium Access
Control (MAC) (e.g., CSMA/CD)…
 Example: Ethernet, PPP
Page 13
Chuah, Fall 2004
25
Network Layer (3)
 Service:
- Deliver a packet to specified destination
• Naming and addressing
• Routing of packets within a network
• Avoidance of failed links
- Perform segmentation/reassemble
(fragmentation/defragmentation)
- Others:
• Packet scheduling
• Buffer management
 Interface:send a packet to a specified destination
 Protocol:define global unique addresses; construct routing
tables
 Example: IP
Chuah, Fall 2004
26
Transport Layer (4)
 Service:
- Provide an error -free and flow-controlled end-host to
end-host connection
- Multiplex multiple transport connections to one network
connection
- Split one transport connection in multiple network
connections
 Interface:send a packet to specify destination
 Protocol:implement reliability and flow control
 Examples: TCP and UDP
Page 14
Chuah, Fall 2004
27
Session Layer (5)
 Service:
- Session setup (authentication)
- Recovery from failure (broken session)
- Full-duplex
- Access management, e.g., token control
- Synchronization, e.g., provide check points for long transfers
 Interface:depends on service
 Protocols:token management; insert checkpoints
Chuah, Fall 2004
28
Presentation Layer (6)
 Service:convert data between various
representations to common format
 Interface:depends on service
 Protocol:define data formats, and rules to convert
from one format to another
 Example: Little endian vs big endian byte orders
• http://www.cs.umass.edu/~verts/cs32/endian.html
Page 15
Chuah, Fall 2004
29
Application Layer (7)
 Service:Process-to-process communication
- any service provided to the end user
- all layers exist to support this layer
 Interface:depends on the application
 Protocol:depends on the application
 Examples: FTP, Telnet, HTTP
Chuah, Fall 2004
30
Why layering?
Key technique to implement complex systems &
communication protocols
 Abstraction
- Explicit structure allows identification, relationship of different pieces
- Layered reference model for discussion
 Modularity -> eases maintenance, updating of system
- Change of implementation of layer’s service transparent to rest of
system
- e.g., change in gate procedure doesn’t affect rest of system
 Resuse
- Software/code, system component, protocol
Page 16
Chuah, Fall 2004
31
Design Challenges
 How do you divide functionality across each
layer?
- Which layer should implement what functionality?
 Hop-by-hop basis or end-to-end basis
 Duplication of functionality between layers
- Error recovery at link layer and transport layer
Chuah, Fall 2004
32
Data and Control Planes
 Data plane: concerned with
- Packet forwarding
- Buffer management
- Packet scheduling
 Control Plane: concerned with installing and
maintaining state for data plane
Another way of looking at things…..
Page 17
Chuah, Fall 2004
33
Example: Routing
 Data plane: use Forwarding Table to forward packets
 Control plane: construct and maintain Forwarding
Tables (e.g., Distance Vector, Link State protocols)
H1
H2
R1
R2
R3
R4
R5
R6
H2 R4

H2 R6

Fwd table
Fwd table
Chuah, Fall 2004
34
OSI vs. TCP/IP
 OSI: conceptually define: service, interface, protocol
 Internet: provide a successful implementation
Application
Presentation
Session
Transport
Network
Datalink
Physical
Network
Link
Transport
Application
Physical
IP
LAN
Packet
radio
data transfer btw neighboring
network elements (Ethernet, PPP)
bits on wire
Telnet
FTP
HTTP
TCP
UDP
host-host
data transfer
routing
datagrams
src->dest
Page 18
Chuah, Fall 2004
35
Internet Protocol “Zoo”
applicatio
n
SMTP
Telnet
NFS/Sun RPC
FTP
DNS
HTTP
RealAudio
RealVideo
Chuah, Fall 2004
36
Internet Architecture
 Packet-switched datagram
network
 IP Hour-glass Architecture
- All hosts and routers run IP
- IP is the glue
- Common intermediate
representation
IP
TCP UDP
ATM
Satellite
Ethernet
IP Hour-glass
Page 19
Chuah, Fall 2004
37
The Internet Network layer
routing
table
Routing protocols
•Path selection
•RIP, OSPF, BGP
IP protocol
•Addressing conventions
•Packet handling conventions
ICMP protocol
•Error reporting
•Router “signaling”
Transport layer: TCP, UDP
Link layer
physical layer
Network
layer
Chuah, Fall 2004
38
Internet Protocol (IP)
 Universal service in a heterogeneous world
- IP over everything
 Virtual overlay network
 Globally unique logical address for a host
 Address resolution
- logical to physical address mapping
Page 20
Chuah, Fall 2004
39
Internet Protocol
 Connectionless unreliable datagram service
 Packets carry a source and a destination address
 Each packet routed independently
 No guarantee that network will not lose packets
• Error recovery is up to end-to-end protocols
Chuah, Fall 2004
40
Transport between Neighbors
 Using underlying link layer transmission
mechanism
- Example: Ethernet, Token Ring, PPP
 Mapping from logical IP address to physical
MAC address
- Address Resolution Protocol (ARP)
Page 21
Chuah, Fall 2004
41
End to End Transport Protocols
TCP service:
 Connection-oriented:setup
required between client,
server
 Reliable transport between
sender and receiver
 Flow control:sender won’t
overwhelm receiver
 Congestion control:throttle
sender when network
overloaded
UDP service:
 Unreliable data transfer
between sender and
receiver
 Does not provide:
connection setup,
reliability, flow control,
congestion control
Q:Why UDP?
Chuah, Fall 2004
42
World-Wide Web
Hypertext transfer protocol
 Web’s application layer
protocol
 Client/server model
- client:browser that
requests, receives,
“displays” Web objects
- server:Web server sends
objects in response to
requests
PC running
Explorer
Server
running
NCSA Web
server
Mac running
Navigator
http request
http request
http response
http response
Page 22
Chuah, Fall 2004
43
HTTP Protocol
Uses TCP transport service:
 Client initiates TCP connection (creates socket) to server, port 80
 Server accepts TCP connection from client
 Http messages (application-layer protocol messages) exchanged
between browser (http client) and Web server (http server)
 TCP connection closed
Chuah, Fall 2004
44
Summary
 Computer networks use packet switching
 Fundamental issues in networking
- Addressing/Naming and routing/forwarding
- Error/Flow/Congestion control
 Layered architecture for maintainability
 Internet is based on TCP/IP protocol suite
Page 23
Chuah, Fall 2004
45
Proof-of-Concept
 With layered architecture, it doesn’t matter how
you implement the layer, as long as it provides
the service follows the protocol as specified!
The Bongo Project
:
http://eagle.auc.ca/~dreid/
Chuah, Fall 2004
46
Links for Long Haul Transmission
 Types of links
- DS1/T1: 1.544 Mbps (24x 64Kbps)
- DS3/T3: 44.736 Mbps
- STS-1/OC-1: 51.84 Mbps
- STS-3/OC-3: 155.2 Mbps
- STS-12/OC-12: 622.080 Mbps
- STS-48/OC-48: 2.488 Gbps
- STS-192/OC-192: 9.953 Gbps
 Higher levels of services
offered commercially
- Frame Relay
- ATM
 Possibilities
- IP over SONET
- IP over ATM
- IP over Frame Relay
- IP over WDM