Systems Approach to Computer Networks

📡Systems Approach to Computer Networks Unit 5 – Protocol Layers and Service Models

Protocol layers and service models form the backbone of modern computer networks. These concepts break down complex communication tasks into manageable pieces, enabling efficient data transfer across diverse network infrastructures. By understanding these principles, we gain insight into how networks function and evolve. The layered approach allows for modular design and implementation of network protocols. Each layer provides specific services, with well-defined interfaces between them. This structure supports interoperability, scalability, and the continuous improvement of network technologies to meet evolving communication needs.

Key Concepts

  • Protocol layers divide complex network communication tasks into manageable pieces
  • Each layer provides services to the layer above it and requests services from the layer below
  • Well-defined interfaces between layers enable interoperability of protocols
  • Encapsulation adds headers and trailers to data as it moves down the protocol stack
  • Decapsulation removes headers and trailers as data moves up the protocol stack
  • Service models define the services provided by each layer and the interfaces between them
  • Protocol design principles guide the development of efficient and effective network protocols
  • Real-world applications rely on the protocol stack to enable reliable communication over networks

Protocol Stack Overview

  • A protocol stack is a hierarchical arrangement of protocols that work together to enable network communication
  • Lower layers provide services to higher layers, allowing each layer to focus on specific tasks
  • The OSI model and TCP/IP model are two widely-used protocol stack architectures
  • Each layer in the stack has a specific role and communicates with its peer layer on other devices
  • Data flows vertically through the layers on a single device and horizontally between peer layers on different devices
  • As data moves down the stack, each layer adds a header (and sometimes a trailer) containing layer-specific information
  • As data moves up the stack, each layer removes and processes its corresponding header (and trailer)

OSI Model vs. TCP/IP Model

  • The OSI (Open Systems Interconnection) model is a conceptual framework with seven layers
    • Application, Presentation, Session, Transport, Network, Data Link, and Physical layers
  • The TCP/IP model is a practical implementation with four layers
    • Application, Transport, Internet (Network), and Link (Network Interface) layers
  • The OSI model provides a more granular and modular approach, while the TCP/IP model combines some layers for simplicity
  • Both models share similar core concepts, such as encapsulation, decapsulation, and layer-specific protocols
  • The TCP/IP model is more widely used in real-world network implementations (Internet)
  • The OSI model serves as a valuable reference for understanding and designing network protocols

Layer-by-Layer Breakdown

  • Application Layer: Provides high-level services to applications (HTTP, FTP, SMTP)
  • Presentation Layer (OSI): Handles data representation, compression, and encryption
  • Session Layer (OSI): Manages sessions between applications, synchronization, and checkpointing
  • Transport Layer: Ensures reliable, end-to-end delivery of data segments (TCP, UDP)
    • Segments data, adds port numbers for multiplexing, and provides error checking
  • Network Layer: Responsible for logical addressing and routing of packets (IP)
    • Adds source and destination IP addresses and handles fragmentation if necessary
  • Data Link Layer: Provides reliable data transfer between adjacent network nodes (Ethernet, Wi-Fi)
    • Adds MAC addresses for local delivery and performs error detection (CRC)
  • Physical Layer: Defines the physical characteristics of the network medium and the transmission of raw bits

Service Models and Interfaces

  • Service models define the services provided by each layer and the interfaces between them
  • Service primitives are the operations that a layer provides to the layer above it (request, indication, response, confirm)
  • The service access point (SAP) is the interface between two adjacent layers, identified by a unique address
  • The service data unit (SDU) is the data passed between two adjacent layers
  • The protocol data unit (PDU) is the SDU with added layer-specific headers (and trailers)
  • Well-defined interfaces enable the independent development and interoperability of protocols at each layer
  • Service models help to maintain a modular and flexible protocol stack architecture

Encapsulation and Decapsulation

  • Encapsulation is the process of adding layer-specific headers (and trailers) to data as it moves down the protocol stack
    • Each layer treats the data from the layer above as payload and adds its own header
  • Decapsulation is the reverse process of removing headers (and trailers) as data moves up the protocol stack
    • Each layer removes its corresponding header and passes the remaining data to the layer above
  • Encapsulation and decapsulation enable the separation of concerns and the independent operation of each layer
  • The terms used for the PDU at each layer vary (segment, packet, frame)
  • Encapsulation and decapsulation are essential for the proper functioning of the protocol stack and the delivery of data to its intended destination

Protocol Design Principles

  • Layering: Divide complex tasks into manageable layers with well-defined interfaces
  • Encapsulation: Each layer adds its own header (and trailer) to the data from the layer above
  • Modularity: Protocols at each layer should be independent and interchangeable
  • Efficiency: Minimize overhead and optimize performance through careful design choices
  • Reliability: Ensure reliable data delivery through error detection, correction, and retransmission mechanisms
  • Scalability: Design protocols that can accommodate growth in network size and complexity
  • Simplicity: Keep protocols as simple as possible while meeting the required functionality
  • Standardization: Adhere to widely-accepted standards to ensure interoperability between different implementations

Real-World Applications

  • Web browsing: Uses HTTP (Application), TCP (Transport), IP (Network), and Ethernet (Data Link) protocols
  • Email: Relies on SMTP (Application), TCP (Transport), IP (Network), and various link layer protocols
  • Voice over IP (VoIP): Employs SIP or H.323 (Application), RTP/UDP (Transport), IP (Network), and link layer protocols
  • File transfer: Uses FTP or SFTP (Application), TCP (Transport), IP (Network), and link layer protocols
  • Remote access: Utilizes SSH or Telnet (Application), TCP (Transport), IP (Network), and link layer protocols
  • Streaming media: Depends on HTTP or RTSP (Application), TCP or UDP (Transport), IP (Network), and link layer protocols
  • Online gaming: Uses proprietary application protocols, UDP (Transport), IP (Network), and link layer protocols


© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.

© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.