Protocol data unit
A protocol data unit (PDU) is the basic unit of exchange between entities that communicate using a specified networking protocol, serving as the structured block of data transmitted at a given layer of a network model.[1] In the Open Systems Interconnection (OSI) reference model, PDUs enable interoperable data transmission across its seven layers through processes of encapsulation—where headers and trailers are added—and decapsulation, where they are removed, ensuring reliable communication between systems.[1] Each OSI layer defines its own type of PDU, reflecting the specific functions and control information required at that level, such as addressing, error detection, and sequencing.[1] PDUs typically consist of a header containing protocol-specific control information, a payload carrying the actual data from higher layers, and sometimes a trailer for additional checks like cyclic redundancy checks (CRC).[1] For example, at the application layer, a PDU is often called a message (e.g., in protocols like HTTPS or SMTP); at the transport layer, it becomes a segment for TCP or a datagram for UDP; the network layer uses packets (e.g., IP packets); the data link layer employs frames (e.g., Ethernet frames) or cells (e.g., in ATM); and the physical layer transmits raw bits.[1] The size of PDUs is constrained by the maximum transmission unit (MTU), such as 1,500 bytes for standard Ethernet frames, which influences network efficiency and fragmentation handling.[1] This layered approach to PDUs, formalized in the OSI model, with development beginning in the late 1970s and formal publication by the International Organization for Standardization (ISO) in 1984, underpins modern networking protocols like TCP/IP, allowing modular design and troubleshooting in complex environments.[2] By standardizing data units, PDUs facilitate seamless integration across diverse hardware and software, from local area networks to global internet communications.[1]Fundamentals
Definition
A protocol data unit (PDU) is the basic unit of data exchanged between peer entities within a specific protocol layer of a communication architecture. Formally defined in the Open Systems Interconnection (OSI) Basic Reference Model, an (N)-PDU is a unit of data specified by an (N)-protocol, consisting of (N)-protocol control information (PCI) and, in cases where user data is present, (N)-user data. This structure ensures that data transmission adheres to the rules and conventions of the protocol at that layer, facilitating reliable exchange across networked systems. The components of a PDU are distinctly separated for functional clarity. The PCI encompasses the control elements, such as headers and trailers, that manage protocol operations; these include addressing information to identify source and destination entities, sequencing details for ordered delivery, and mechanisms for error detection and correction to maintain data integrity during transmission. In contrast, the user data portion—also known as the service data unit (SDU)—represents the payload received from the higher-layer protocol, which becomes encapsulated within the current layer's PDU without alteration to its content. This SDU serves as the input from the upper layer, enabling the abstraction of services while the PCI handles layer-specific processing. The primary purpose of a PDU is to support structured and modular data transfer in layered communication systems, promoting independence between layers by hiding implementation details of lower layers from higher ones. By encapsulating the SDU with appropriate PCI, PDUs allow each layer to perform protocol-specific functions, such as routing, synchronization, or multiplexing, without requiring awareness of underlying transmission mechanisms. This design enhances interoperability and scalability in network architectures. The term "protocol data unit" originated in the development of the OSI reference model during the late 1970s, when the International Organization for Standardization (ISO) initiated efforts to standardize open systems interconnection amid growing diversity in computer networking protocols. It was formalized in the ISO/IEC 7498-1 standard, with the 1994 edition providing the enduring definitions still in use today.[3]Role in Layered Architectures
In layered network architectures, such as the Open Systems Interconnection (OSI) reference model, protocol data units (PDUs) serve as the fundamental building blocks for data exchange across multiple abstraction layers. Each layer in the stack processes data by encapsulating the service data unit (SDU) received from the layer above with its own protocol control information (PCI), forming an (N)-PDU specific to that layer's protocol. This process promotes modularity by allowing each layer to operate independently, focusing solely on its defined functions while relying on lower layers for transmission without needing to understand their internal implementations. PDUs enable peer-to-peer communication between entities at the same layer across the network. An (N)-PDU is exchanged between peer (N)-entities using the services of the (N-1) layer, where the (N)-PDU becomes the SDU for the lower layer. This hierarchical interaction ensures that data flows downward through the transmitting stack—being encapsulated at each layer—and upward through the receiving stack—being decapsulated—while maintaining logical separation between layers. Such a structure facilitates coordinated operation among distributed entities without direct access to underlying transport mechanisms. The abstraction provided by PDUs hides the complexities of lower-layer implementations from higher layers, allowing developers to concentrate on layer-specific tasks such as routing at the network layer or session management at the session layer. By treating the lower layer's PDU as an opaque SDU, upper layers achieve independence, enabling easier protocol evolution and interoperability across diverse systems. This layered modularity simplifies the design of complex networks by decomposing responsibilities into discrete, interchangeable components. PDUs incorporate layer-specific mechanisms for error handling and flow control through their PCI fields, which are tailored to the responsibilities of each layer. For instance, PCI may include sequence numbers, acknowledgments, or checksums to detect and recover from transmission errors, while control flags can regulate data flow to prevent congestion. These features ensure reliable communication without burdening other layers, as each PDU carries only the control information necessary for its protocol's peer interactions.Packet-Switched Networks
Encapsulation and Decapsulation
In packet-switched networks, encapsulation is the process by which data from higher layers is progressively wrapped with protocol control information (PCI) as it descends through the protocol stack, transforming raw application data into a transmittable protocol data unit (PDU) suitable for network transmission.[4] At the originating host, the application layer generates the initial service data unit (SDU), which is passed to the next lower layer. This layer treats the incoming SDU as its own payload and prepends a header—containing addressing, sequencing, error detection, or other control fields—potentially appending a trailer as well, forming a new PDU. This step is repeated at each subsequent layer, with each adding its specific PCI to the PDU from the layer above, until the physical layer transmits the fully encapsulated bit stream over the medium.[4] Decapsulation performs the inverse operation at the receiving host, where the PDU ascends through the protocol stack, with each layer stripping away its corresponding PCI to recover the original SDU for delivery to the upper layer. Upon arrival at the physical layer, the bit stream is reconstructed into the lowest-layer PDU. The data link layer then removes its header and trailer, verifying integrity if applicable, and passes the resulting SDU upward. This peeling process continues layer by layer, ensuring that the original application data is accurately restored without alteration, while each layer processes only the PCI relevant to its function.[4] Within packet-switched networks, these encapsulation and decapsulation mechanisms enable the division of messages into variable-length PDUs, or packets, that can be routed independently through the network based on destination addresses embedded in the headers, allowing efficient sharing of resources among multiple flows without establishing dedicated end-to-end paths.[4] This contrasts with circuit-switched systems, where a fixed physical or virtual path is reserved for the duration of a connection, precluding the need for such dynamic packet formation and independent routing.[5] A key challenge in this process arises from the cumulative overhead of multiple encapsulations, as each added header or trailer increases the overall PDU size, consuming additional bandwidth and potentially exceeding the maximum transmission unit (MTU) limits imposed by underlying links.[6] To mitigate this, networks enforce MTU constraints—typically ranging from 576 bytes in early IP designs to 1500 bytes on Ethernet—to avoid excessive fragmentation, where oversized PDUs are split into smaller fragments that must be reassembled at the destination, introducing delays, error risks, and processing burdens.[6] Path MTU discovery protocols have been developed to dynamically determine the smallest MTU along a route, optimizing encapsulation to minimize such issues while preserving end-to-end reliability.[6]PDU Formats and Headers
A Protocol Data Unit (PDU) in packet-switched networks generally comprises three main components: a header, a payload, and an optional trailer. The header prepends control information to the payload, which carries the Service Data Unit (SDU) from the higher layer, while the trailer, if present, appends additional data for integrity checks. This structure facilitates the transmission of data across network layers by encapsulating the SDU with protocol-specific metadata.[7] The header contains essential fields that enable routing, ordering, and verification of the PDU. Key fields include source and destination addresses, which specify the sender and receiver using logical or physical identifiers; sequence numbers, which maintain data order and support retransmission; length indicators, which denote the total PDU size; type identifiers, which classify the payload content; protocol version numbers, which ensure compatibility; and checksums, which detect transmission errors. These fields collectively manage the PDU's lifecycle within the network stack.[7] PDUs exhibit variability in length to suit different network requirements, with fixed-length formats such as cells offering predictable processing and reduced latency in high-speed switches, and variable-length formats such as packets allowing flexibility for diverse data sizes but increasing parsing complexity. Fixed-length PDUs simplify buffer management and hardware implementation by eliminating the need for dynamic boundary detection, whereas variable-length PDUs optimize bandwidth for irregular payloads at the cost of additional overhead in segmentation and reassembly.[7][8] Header and trailer sizes contribute to protocol overhead, typically ranging from 5-20% of the total PDU length depending on the payload size, which influences overall bandwidth utilization in packet-switched environments. Smaller payloads amplify relative overhead, reducing effective throughput, while larger payloads mitigate this by spreading fixed header costs across more data bits, though they may introduce delays in error recovery. Balancing these trade-offs is critical for efficient network performance.[8]OSI Model
PDUs by Layer
In the OSI model, each layer processes specific protocol data units (PDUs) tailored to its responsibilities, with data flowing downward through encapsulation (adding headers/trailers) and upward through decapsulation (removing them).- Layer 1 (Physical): The PDU is a bit, representing the raw binary signals transmitted over the physical medium, such as electrical impulses or light pulses. It handles the conversion of bits to signals without error correction or addressing.[9]
- Layer 2 (Data Link): The PDU is a frame, which includes the payload from higher layers, plus a header with addressing (e.g., MAC addresses) and a trailer for error detection (e.g., CRC). It ensures reliable transmission between directly connected nodes.[9]
- Layer 3 (Network): The PDU is a packet (or datagram), containing a header for logical addressing (e.g., IP addresses), routing information, and the transport layer segment as payload. It enables routing across multiple networks.[9]
- Layer 4 (Transport): The PDU is a segment (for connection-oriented protocols like TCP) or datagram (for connectionless like UDP), including end-to-end addressing (ports), sequencing, and error recovery in the header, with application data as payload. It provides reliable or best-effort delivery between hosts.[9]
- Layers 5-7 (Session, Presentation, Application): PDUs here are generally data units, handling session management, data syntax/encryption, and application-specific protocols. They focus on user-level communication without network-specific addressing.[9]
Layer-Specific Naming
In the OSI model, protocol data units (PDUs) are assigned layer-specific names to delineate their functional roles and transmission scopes within the seven-layer architecture. At the Physical layer (Layer 1), the PDU is termed a bit or symbol, representing the fundamental binary signals transmitted over physical media. The Data Link layer (Layer 2) designates its PDU as a frame, encapsulating data for error detection and local link transmission. For the Network layer (Layer 3), the PDU is called a packet or datagram, suited for routing across interconnected networks. The Transport layer (Layer 4) uses segment or datagram for its PDU, emphasizing end-to-end delivery and reliability mechanisms. In the upper layers—Session (Layer 5), Presentation (Layer 6), and Application (Layer 7)—the PDU is generally referred to as a message or data unit, focusing on dialog control, data formatting, and user-level interactions. This naming convention is deliberate, reflecting the operational boundaries and responsibilities of each layer to facilitate clear conceptual separation in network design and analysis. For instance, the term "frame" underscores the link-local scope of Layer 2 operations, confined to adjacent nodes with synchronization and error checking, whereas "packet" or "datagram" highlights the internetwork routing capability at Layer 3, enabling path-independent forwarding across diverse subnetworks. Similarly, "segment" at Layer 4 connotes the division of data into manageable units for transport services, distinguishing it from lower-layer constructs. This structured nomenclature aids engineers and implementers in mapping protocol behaviors to model layers, reducing confusion in layered protocol specifications. The evolution of this layer-specific naming traces back to the development of the OSI reference model in the late 1970s by the International Organization for Standardization (ISO), culminating in the publication of ISO 7498 in 1984, with a revision as ISO/IEC 7498-1 in 1994 (equivalent to ITU-T Recommendation X.200). Prior to OSI, early network protocols like those in the ARPANET employed ad-hoc terminology without a unified framework, leading to inconsistencies in documentation and interoperability challenges across vendor-specific systems. The OSI model standardized these terms to promote unambiguous communication in open systems, drawing from collaborative efforts involving ISO Technical Committee 97 and international experts, as detailed in foundational works on the architecture. This shift marked a pivotal advancement in promoting vendor-neutral standards over proprietary designs.[10] ISO provides explicit guidelines in its OSI-related standards for employing this terminology consistently in technical documentation, protocol implementations, and educational materials to ensure global interoperability. Recommendations emphasize using the precise layer-specific names rather than generic terms like "packet" for all units, avoiding misinterpretation in multilayer protocol stacks. For example, ISO/IEC 7498-1 advises that descriptions of service interfaces and protocol exchanges should align with these names to support modular design and verification. Adherence to these guidelines has influenced subsequent standards bodies, including the Internet Engineering Task Force (IETF), in maintaining terminological precision within layered architectures.Internet Protocol Suite
PDUs by Layer
In the Internet Protocol Suite (TCP/IP model), PDUs are defined across its four layers: Application, Transport, Internet, and Network Access (or Link). At the Application layer, the PDU is typically a message containing application-specific data (e.g., HTTP request). The Transport layer uses a segment for TCP, which provides reliable delivery, or a datagram for UDP, which is connectionless. The Internet layer employs an IP datagram (or packet) for routing. Finally, the Network Access layer encapsulates data in a frame, such as an Ethernet frame, for transmission over physical media.[11][12]Key Examples
In the Internet Protocol Suite, the IP datagram serves as the primary PDU at the network layer, encapsulating higher-layer data for routing across interconnected networks. The IPv4 header, as defined in the original specification, has a minimum length of 20 bytes and includes essential fields such as the 4-bit Version field (indicating IPv4), the 8-bit Time to Live (TTL) field for preventing infinite loops by decrementing per hop, and the 16-bit Header Checksum for error detection in the header itself.[13] This structure supports fragmentation, where large datagrams exceeding the maximum transmission unit (MTU) of a link are divided into smaller fragments, each carrying the original header plus a 16-bit Identification field and Fragment Offset to enable reassembly at the destination.[13] At the transport layer, the TCP segment represents a connection-oriented PDU that ensures reliable, ordered delivery of data streams. Its header is at least 20 bytes long, featuring 32-bit Sequence and Acknowledgment numbers for tracking byte-level ordering and flow control, a 16-bit Window size to advertise the receiver's buffer capacity, and control flags like SYN, ACK, FIN, and RST to manage connection establishment, maintenance, and teardown.[14] These elements enable TCP's mechanisms for error correction, congestion avoidance, and retransmission, making it suitable for applications requiring guaranteed delivery, such as file transfers. In contrast, the UDP datagram provides a lightweight, connectionless alternative at the transport layer, prioritizing low overhead over reliability. Its fixed 8-byte header includes 16-bit Source and Destination Port fields for demultiplexing, a 16-bit Length field covering the header and data, and a 16-bit Checksum for optional integrity verification, which can be set to zero if not used.[12] This minimal design suits real-time applications like video streaming, where occasional packet loss is tolerable to minimize latency. Bridging the physical and network layers, the Ethernet frame acts as a link-layer PDU for local area network transmission, encapsulating IP datagrams within a structure that includes a 7-byte Preamble and 1-byte Start Frame Delimiter (SFD) for synchronization, 6-byte Destination and Source MAC addresses for node identification, a 2-byte Type/Length field (indicating Ethernet II framing with values like 0x0800 for IPv4), variable-length data payload (typically 46-1500 bytes to meet the minimum frame size), and a 4-byte Frame Check Sequence (FCS) for cyclic redundancy check error detection. This frame format facilitates the handover of IP traffic to the physical medium, enabling collision detection in shared environments.[15] A practical illustration of PDU stacking occurs in a typical web request, where an HTTP request PDU is encapsulated within a TCP segment (with sequence numbers ensuring ordered delivery), which is then placed in an IP datagram (routed via TTL and addresses), and finally framed in an Ethernet frame (using MAC addresses for local delivery) before transmission over the wire.[14][13] This layered encapsulation allows modular processing, with each PDU adding layer-specific headers for end-to-end functionality across diverse networks.Other Protocols
Internetwork Packet Exchange (IPX)
The Internetwork Packet Exchange (IPX) is a legacy network layer protocol developed by Novell in the 1980s as part of its NetWare operating system for local area networks (LANs). Derived from the Xerox Network Systems Internet Datagram Protocol (IDP), IPX facilitated routed communication in proprietary Novell environments, serving as the core transport for file and print services during the 1980s and early 1990s. Its adoption peaked with NetWare's dominance in enterprise LANs, but it declined in the mid-1990s as TCP/IP emerged as the standard for internetworking, leading Novell to shift focus toward IP support in NetWare 5 (1998) and eventually phase out IPX in favor of open protocols.[16][17][18] IPX provides a connectionless datagram service at the OSI network layer, routing packets without establishing end-to-end connections or ensuring delivery, with reliability left to upper-layer protocols such as Sequenced Packet Exchange (SPX). Unlike IP, which separates network and host addressing, IPX integrates addressing into a single 12-byte scheme: a 4-byte network number for routing across internetworks, a 6-byte node address (typically the hardware MAC address for direct LAN delivery), and a 2-byte socket for multiplexing to specific processes or services on the node. This design enabled efficient, broadcast-capable communication in segmented Novell networks, supporting up to 65,535 sockets per node for concurrent services like NetWare Core Protocol (NCP).[17][16] The IPX protocol data unit (PDU) comprises a fixed 30-byte header followed by a variable data payload, which encapsulates upper-layer headers and application data, with a typical maximum size of 576 bytes in early implementations to match common LAN MTUs. The header fields include a 2-byte checksum (optional; set to 0xFFFF when disabled for performance), a 2-byte packet length indicating the total PDU size (minimum 30 bytes, maximum 65,535 bytes), a 1-byte transport control field tracking hops (capped at 16 for Routing Information Protocol or 127 for NetWare Link Services Protocol), and a 1-byte packet type specifying the encapsulated protocol (e.g., 0x05 for SPX or 0x00 for routing updates). Destination and source addresses each consist of 4-byte network, 6-byte node, and 2-byte socket fields, enabling precise routing without additional subnet masks.[17] Key features of the IPX PDU emphasize simplicity for legacy LANs: socket-based multiplexing allows multiple applications to receive datagrams on the same node via unique socket numbers (e.g., 0x0451 for NCP), while the absence of fragmentation fields in the header means IPX relies on the underlying link layer's maximum transmission unit (e.g., 1,500 bytes for Ethernet) rather than reassembling split packets. The optional checksum, introduced in advanced NetWare versions like SFT III and NetWare 4, provides basic error detection but was often disabled in earlier deployments to reduce overhead, reflecting IPX's optimization for low-latency, high-throughput LAN environments.[17]Asynchronous Transfer Mode (ATM)
Asynchronous Transfer Mode (ATM) is a cell-relay, circuit-switched networking technology developed for broadband integrated services digital network (B-ISDN), enabling the transport of voice, video, and data over high-speed links with guaranteed quality of service (QoS). Standardized by the ITU-T through its I-series recommendations starting in the late 1980s and evolving through the 1990s, ATM uses small, fixed-length protocol data units called cells to achieve low latency and efficient multiplexing for diverse traffic types. The core PDU in ATM is the ATM cell, a fixed 53-octet structure comprising a 5-octet header and a 48-octet payload field. The header facilitates routing and management: it includes the Virtual Path Identifier (VPI, 8-12 bits depending on interface) and Virtual Channel Identifier (VCI, 16 bits) to establish and identify virtual circuits; the Payload Type (PT, 3 bits) to distinguish user data, management cells, or congestion notifications; the Cell Loss Priority (CLP, 1 bit) to mark cells eligible for discard during congestion; and the Header Error Control (HEC, 8 bits) for error detection and correction using a cyclic redundancy check polynomial. At the user-network interface (UNI), the header also features a 4-bit Generic Flow Control (GFC) field, typically set to zero and unused in practice, while the network-node interface (NNI) repurposes those bits for an expanded VPI. This uniform cell format ensures predictable processing delays in ATM switches, supporting bit rates up to 622 Mbps or higher in B-ISDN deployments. To adapt variable-length higher-layer PDUs to the fixed-size ATM cells, ATM employs adaptation layers (AAL), with AAL type 5 (AAL5) being the most prevalent for connection-oriented data services like IP over ATM. The AAL5 protocol processes input SDUs through its common part convergence sublayer (CPCS), producing a CPCS-PDU that appends a 2-octet length field (indicating payload size up to 2^16 - 1 octets), an 8-octet trailer reserved for user-defined purposes, and a 32-bit CRC-32 for integrity verification, with zero to 47 octets of padding to align the payload. The segmentation and reassembly (SAR) sublayer then divides the CPCS-PDU (excluding the trailer and CRC) into 48-octet segments, adding a 1-octet SAR header per cell with a 2-bit payload type (indicating the start, continuation, or end of the frame) and 6-bit sequence number for reassembly and error recovery. This mechanism supports efficient encapsulation of protocols like Ethernet frames while minimizing overhead to about 8% for large payloads. ATM's design emphasizes QoS through five traffic classes (constant bit rate for voice emulation, variable bit rate for compressed video, available bit rate for bursty data, unspecified bit rate, and real-time variable bit rate), enforced via virtual circuit parameters and cell scheduling in switches.Media Access Control PDUs
Media Access Control (MAC) protocol data units (PDUs), often called MAC frames, operate at the MAC sublayer of the data link layer in the OSI model. They are responsible for framing data from the logical link control (LLC) sublayer or higher layers, adding addressing, control information, and error-checking mechanisms to coordinate access to shared physical media in local area networks (LANs). MAC PDUs ensure reliable transmission over media like twisted-pair cables or wireless channels by incorporating fields for source and destination identification, frame synchronization, and integrity verification. Unlike higher-layer PDUs, MAC frames are tailored to specific access methods such as carrier-sense multiple access with collision detection (CSMA/CD) in wired networks or request-to-send/clear-to-send (RTS/CTS) in wireless environments.[19] A prominent example of MAC PDUs is the Ethernet frame defined in IEEE 802.3, widely used in wired LANs. The basic Ethernet MAC frame structure includes several fixed and variable fields to support efficient data transfer at speeds ranging from 10 Mbps to 400 Gbps. The frame begins with an 8-byte preamble (7 bytes of alternating 1s and 0s for synchronization, followed by a 1-byte start frame delimiter) to align the receiver's clock. This is followed by a 6-byte destination address (DA) and 6-byte source address (SA), both using 48-bit MAC addresses for unicast, multicast, or broadcast identification. A 2-byte Length/Type field indicates either the payload length (if ≤1500 bytes) or an EtherType value (if ≥1536) to denote the upper-layer protocol, such as IPv4 (0x0800). The variable-length Data field (46–1500 bytes, padded if necessary to meet the minimum frame size) carries the LLC PDU or higher-layer data, and a 4-byte frame check sequence (FCS) provides cyclic redundancy check (CRC-32) for error detection. Optional elements, like the 4-byte 802.1Q VLAN tag inserted after the SA, support features such as priority tagging and virtual LANs. This structure enables collision avoidance and detection in half-duplex modes while supporting full-duplex operation in modern implementations.[20][19] In wireless networks, IEEE 802.11 (Wi-Fi) defines MAC PDUs known as MAC protocol data units (MPDUs), which address challenges like hidden terminals and interference through additional control fields. The MPDU header starts with a 2-byte Frame Control field, subdivided into protocol version, frame type (management, control, or data), subtype, and flags for features like power management or encryption (WEP or WPA). A 2-byte Duration/ID field reserves the medium or identifies access points in probe requests. Up to four 6-byte Address fields (Address 1–4) handle complex scenarios, such as sender/receiver in ad-hoc modes or distributor addresses in infrastructure setups, using the same 48-bit MAC addressing as Ethernet. The 2-byte Sequence Control field includes fragment and sequence numbers for reassembly and duplicate detection, while an optional 2-byte QoS Control field (in 802.11e and later) prioritizes traffic. The variable Frame Body (up to 2312 bytes) encapsulates higher-layer data, followed by a 4-byte FCS for CRC-32 integrity. MPDUs can be aggregated (A-MPDU) for efficiency in high-throughput modes, combining multiple frames into a single physical layer PDU to reduce overhead. This format supports distributed coordination function (DCF) for contention-based access and point coordination function (PCF) for contention-free periods.[21]| Field | Size (bytes) | Purpose (Ethernet Example) |
|---|---|---|
| Preamble | 7 | Synchronization pattern |
| Start Frame Delimiter (SFD) | 1 | Marks frame start |
| Destination Address (DA) | 6 | Recipient MAC address |
| Source Address (SA) | 6 | Sender MAC address |
| Length/Type | 2 | Payload length or protocol type |
| Data/Payload | 46–1500 (variable) | Upper-layer data (padded if needed) |
| Frame Check Sequence (FCS) | 4 | Error detection (CRC-32) |