The Network Layer: Data Plane

Learn how the internet's network layer moves packets from host to host. Separate forwarding from routing, follow a packet through a router's ports, lookup and switching fabric, and see where packets queue and how they are scheduled. Decode IPv4 headers and fragments, trace DHCP and NAT, compare IPv6 with IPv4 and its transition methods, and write match-plus-action rules for software-defined networks. Finish by weighing middleboxes against the internet's end-to-end design.

IntermediateLesson 5 of 8 in Computer Networks Course

What you will learn

  1. Separate the network layer's two jobs, forwarding and routing, follow a packet through the parts of a router, and explain where packets wait, get dropped and get scheduled.
    • Tell forwarding from routing and the data plane from the control plane
      Define the network layer's role, forwarding, routing, forwarding tables and the two planes, and describe the best-effort service the internet's network layer offers.
    • Trace a packet through a router's ports and switching fabric
      Name the parts of a router, explain how an input port finds the output link with longest prefix matching, and compare the ways a switching fabric moves packets between ports.
    • Explain where packets queue and how routers drop and schedule them
      Explain input and output queuing, head-of-the-line blocking and buffer sizing, and compare drop policies and the FIFO, priority, round-robin and weighted fair queueing schedulers.
  2. Decode every field of the IPv4 header, check a header checksum, and split a datagram into fragments that fit a link's maximum transmission unit.
    • Decode the fields of an IPv4 header
      Name each IPv4 header field with its size and purpose, decode a header from its bytes, and compute and verify the header checksum.
    • Fragment a datagram to fit a link's MTU
      Explain the maximum transmission unit, split an IPv4 datagram into fragments with correct lengths, offsets and flags, and explain reassembly and path MTU discovery.
  3. Follow how a host gets its address and settings automatically, and how a NAT router lets many privately addressed devices share one public IPv4 address.
    • Follow how DHCP configures a host
      Describe the settings a host needs, the four-message DHCP exchange with its addresses and ports, leases and renewal, and the role of relay agents.
    • Trace address and port translation through a NAT router
      Explain how network address translation lets a private network share one public address, trace a translation table, and weigh what NAT breaks against what it solves.
  4. Read the IPv6 header, explain what changed from IPv4 and why, and explain how dual stack, tunneling and translation let the two protocols coexist.
    • Read the IPv6 header and explain what changed
      Name the fields of the fixed IPv6 header, follow a chain of extension headers, and explain why IPv6 dropped the header checksum, router fragmentation and in-header options.
    • Explain dual stack, tunneling and translation
      Explain why IPv4 and IPv6 must coexist for years, how dual stack, tunneling and NAT64 with DNS64 bridge them, and what each method costs.
  5. Write match-plus-action rules that make one device act as a router, switch, firewall or load balancer, explain how software-defined networking uses them, and weigh middleboxes against the internet's design principles.
    • Write match-plus-action flow table entries
      Describe flow tables with their match fields, priorities, actions and counters, and decide which entry an arriving packet matches.
    • Use flow tables to build network behavior in SDN
      Build forwarding paths, firewalls, switching and load balancing from flow table entries across several switches, and explain how SDN separates and centralizes control.
    • Assess middleboxes against the internet's design principles
      Define middleboxes and their main kinds, explain the IP hourglass and the end-to-end argument, and weigh the benefits of middleboxes against the problems they create.

Network Layer Data Plane study guide

5 chapters

1

Follow a packet through a router

A packet crosses a network through many small, local decisions. To understand one of them, separate the logic that builds a forwarding table from the hardware that applies it. Then follow the packet from an input port, through the switching fabric, to an output link. Even when every lookup is correct, competing packets can create queues, delay and loss. The fabric, buffers and scheduler determine what happens during that competition.

1.1 Separate forwarding from routing

The network layer carries datagrams between hosts across a path of routers. The sending host puts a transport segment inside a datagram. Each router reads the network-layer header and passes the datagram toward its destination. At the receiving host, the network layer hands the segment to TCP, UDP or another upper-layer protocol.

One local decision and one network-wide plan

Forwarding moves an arriving packet from an input link to an output link at one router. It can also discard a packet or send copies to several links. The decision happens for every packet, usually in hardware on a nanosecond timescale.

Routing determines paths across the network. Routing software exchanges information and computes routes, typically over much longer timescales, such as seconds. Planning a road trip resembles routing; taking the chosen exit at one interchange resembles forwarding. The router does not rerun its routing algorithm for each arriving packet.

Suppose a forwarding entry maps 10.20.0.0/16 to interface 2. When a datagram for 10.20.7.1 arrives, the lookup selects interface 2. The per-packet operation applies an existing decision. A link failure may later cause the routing process to replace the entry.

The two planes and their tables

The data plane performs these local packet operations. The control plane decides routes and supplies the tables. Traditional routers each run a routing component, exchange routing messages and compute their own tables. In software-defined networking, a logically centralized controller installs entries remotely; switches still handle packets locally.

The routing information base (RIB) stores routes learned by the control plane. The forwarding information base (FIB) is the lookup structure derived from those routes for the data plane. Commands sometimes call either structure a "routing table," so its role matters more than the informal name.

A router is one kind of packet switch, a device that moves packets according to header fields. A link-layer switch normally selects by a destination MAC address. A router normally selects by a destination IP address. Network-layer processing exists in both hosts and routers; application and transport communication is between the end hosts.

What IP promises

A network's service model states its delivery guarantees. Possible guarantees include delivery within a deadline, arrival in order, a minimum bandwidth or reliable delivery. Internet IP supplies best-effort service: none of those guarantees, and no built-in security guarantee. A datagram can be lost, delayed, duplicated or reordered. IP does not retransmit it.

IP is also connectionless. Each datagram carries the information used to forward it; the network layer does not first establish an end-to-end connection. Packets in one conversation can follow different paths.

Useful applications still work because other parts of the system provide what they need. TCP detects loss and restores byte order at the endpoints. Congestion control adjusts sending rates, operators add capacity, and nearby content servers shorten paths. A successful TCP transfer therefore does not mean that IP itself guaranteed delivery.

Key Takeaways

  • Forwarding applies a table at one router; routing determines network-wide paths.
  • The control plane builds tables and the data plane handles packets.
  • The RIB stores route information; the FIB supports forwarding lookups.
  • IP offers connectionless, best-effort delivery without retransmission.

1.2 Choose an output and cross the switching fabric

A router's data path has an input side, an internal connection and an output side. Its control software supplies the information those components apply.

The four parts

An input port receives bits, removes the incoming link-layer framing and looks up the output port. The switching fabric transfers the packet internally. An output port buffers packets, builds the outgoing frame and transmits it. The routing processor runs control-plane and management software, or communicates with an SDN controller. Input and output functions for one bidirectional link usually share a line card.

At 10 Gb/s, a 64-byte packet contains 512 bits and occupies 51.2 ns, giving about 19.5 million packet arrivals per second. At 100 Gb/s, the corresponding gap is 5.12 ns. These packet-only calculations explain the pressure for hardware lookups. A copy of the forwarding table on each line card lets ports work without consulting a central processor for every packet.

Longest prefix matching

An IP table groups destinations into prefixes. A destination can match several entries; longest prefix matching selects the matching entry with the greatest prefix length.

PrefixOutput interface
10.0.0.0/80
10.20.0.0/161
10.20.30.0/242
0.0.0.0/03

10.20.30.77 matches all four entries, so /24 selects interface 2. For 10.20.31.5, /16 wins and selects interface 1. For 10.99.1.1, /8 selects interface 0. Only the default /0 matches 172.16.0.1, giving interface 3. Table order does not decide the result.

Prefixes can end within an octet. 192.168.8.0/21 covers third-octet values 8–15; 192.168.12.0/22 covers 12–15. Thus 192.168.12.9 takes /22, while 192.168.9.200 takes /21. Compare prefix bits, not the number of matching dotted groups. Overlap allows a broad aggregated route alongside an exception with a more specific prefix.

A ternary content-addressable memory (TCAM) compares entries in parallel, including wildcard bits, and can return a match in about one clock cycle within its hardware capacity. Input processing also checks the IP version, IPv4 checksum and TTL, updates TTL and checksum, and records counters.

Three ways to move the packet

Memory switching copies a packet into shared memory and out again. Each packet consumes two memory transfers, so a memory system supporting B transfers per second has a ceiling of B/2 packets per second before other costs.

Bus switching sends the packet over one shared bus with an output label. One packet crosses at a time; bus bandwidth limits aggregate throughput.

An interconnection network, such as a crossbar, can move packets to different outputs simultaneously. A crossbar for N inputs and N outputs uses 2N buses. Two packets competing for the same output still need arbitration. Large routers combine stages, fixed-size cells and parallel fabric planes; a fabric rate of N times the line rate is the ideal aggregate capacity for N inputs.

Key Takeaways

  • Input ports perform local lookups before the fabric transfers packets to outputs.
  • Longest prefix matching chooses the most specific matching destination prefix.
  • The /0 default applies only when no longer prefix matches.
  • Line-card table copies and hardware lookups support high packet rates.
  • Memory and shared-bus fabrics limit aggregate transfers.
  • A crossbar serves different outputs in parallel, but output contention remains.

1.3 Explain queues, drops and scheduling

A correct forwarding decision does not ensure immediate transmission. A packet may wait for the switching fabric or for its output link, and finite buffers can run out of space.

Where the queue forms

Input queuing occurs when the fabric cannot accept packets as quickly as inputs supply them. With one FIFO per input, head-of-the-line (HOL) blocking traps a packet behind an earlier packet waiting for a busy output, even when the later packet's output is free. For large switches with uniform random traffic, this arrangement has a throughput limit near 58.6% of line rate. Separate virtual output queues at each input remove this particular blockage.

Output queuing occurs when arrivals for one output exceed its line rate. If three equal packets reach one output during a packet time, one can depart and two wait. A fast fabric does not make the output link faster.

How much buffer?

The classic sizing rule is B=RTT×C, with RTT in seconds and capacity C in bits per second. A 250 ms RTT and 10 Gb/s link give 2.5 Gb, or 312.5 MB. With N long-lived, unsynchronized TCP flows, the alternative rule B=RTT×CN gives 25 Mb, or 3.125 MB, for 10,000 flows. These are sizing rules with different traffic conditions, not interchangeable guarantees for every queue.

Large buffers can cause bufferbloat. Almost 1 MB queued ahead of an admitted packet on a 10 Mb/s link takes about 0.8 s to drain: convert the bytes to 8,000,000 bits, then divide by the rate. With tail drop, a new packet reaching a completely full buffer is discarded instead.

Dropping is different from scheduling

Buffer management decides which packets to discard or mark. Tail drop rejects new arrivals at a full buffer. Priority-based dropping removes lower-priority traffic first. Active queue management acts earlier: RED increases its drop or marking probability as average queue length rises. With ECN, a router can mark congestion in an eligible IP packet, allowing the endpoints to reduce load without that packet being lost.

Scheduling chooses the next packet to transmit:

  • FIFO serves arrival order.
  • Strict priority serves the highest-priority nonempty class, usually FIFO within each class. A non-preemptive scheduler finishes the packet already transmitting. If low-priority packet 1 is in progress when high 2, low 3 and high 4 arrive, departures are 1, 2, 4, 3.
  • Round robin gives each nonempty class a packet turn and skips empty queues. For A holding a1, a2, a3 and B holding b1, departures are a1, b1, a2, a3. A work-conserving scheduler keeps transmitting whenever any packet waits.
  • Weighted fair queueing (WFQ) accounts for packet lengths to approximate weighted bit-by-bit service. A continuously backlogged class receives approximately its weight divided by the active weight sum, times link rate. Weights 5:3:2 on 100 Mb/s give 50, 30 and 20 Mb/s when all are busy. If the third empties, the others receive 62.5 and 37.5 Mb/s. Weights provide shares, not fixed caps; counting packet turns alone gives different bandwidth shares when packet sizes differ.

These mechanisms let operators prioritize, slow or block traffic. Whether providers may treat lawful content or applications differently is the policy issue called network neutrality. Its legal rules depend on the country and date.

Key Takeaways

  • HOL blocking can delay traffic for an otherwise free output.
  • Output queues form when arrivals exceed the outgoing line rate.
  • Buffer sizing depends on RTT, capacity and traffic behavior.
  • Bufferbloat trades reduced loss for excessive waiting time.
  • Buffer management chooses drops or marks; scheduling chooses departures.
  • Non-preemptive priority finishes the current packet before switching classes.
  • WFQ shares bandwidth by weight while accounting for packet length.
2

Read IPv4 headers and fragments

An IPv4 header tells a router how to handle a datagram and tells the destination how to interpret its payload. Reading it means keeping bit fields, byte counts and word counts separate. The same header also carries the information needed when a datagram must be split for a smaller link. Work from the total size to the payload, then use offsets and flags to follow the pieces all the way to destination reassembly.

2.1 Decode an IPv4 header and check it

An IPv4 datagram consists of a header followed by a payload, usually a transport segment. The usual header is 20 bytes; options can extend it to 60. Total length is a 16-bit byte count, allowing up to 65,535 bytes. Ethernet commonly carries IP packets up to 1,500 bytes.

Read fields in their wire order
FieldBitsMeaning
Version; IHL4; 4IP version; header length in 32-bit words
Type of service8Six DSCP bits and two ECN bits
Total length16Header plus payload, in bytes
Identification16Associates fragments of one original datagram
Flags; Fragment offset3; 13Fragmentation controls; payload position in 8-byte units
TTL; Protocol8; 8Remaining lifetime; payload protocol
Header checksum16Error check for the IPv4 header
Source; Destination32 eachEnd-to-end IPv4 addresses

Options follow these fields when IHL exceeds 5. Since each IHL word is four bytes, IHL 5 means 20 bytes and IHL 15 means 60. Subtract this header size from Total length to find payload size.

DSCP supports traffic classification and ECN carries congestion information. Each router reduces TTL by at least 1. On expiry it discards the datagram and normally sends ICMP Time Exceeded. TTL commonly starts at 64, 128 or 255. Protocol identifies TCP (6), UDP (17), ICMP (1) or encapsulated IPv6 (41); it does not identify an application port.

Decode a complete header

Consider these hexadecimal bytes:

45 00 00 34 1C 46 40 00 40 06 32 2C C0 00 02 0A C6 33 64 14

45 gives version 4 and IHL 5. Total length 0034 is 52 bytes, leaving 32 payload bytes. Identification 1C46 is 7238. The flags/offset word 4000 sets DF, clears MF and gives offset 0. TTL 40 is 64, Protocol 06 means TCP, and the checksum is 322C. The source bytes decode to 192.0.2.10 and destination bytes to 198.51.100.20.

Compute the header checksum

Set the checksum field to zero and add the 16-bit words using one's-complement arithmetic. Fold each carry above bit 16 back into the low end, then invert the bits.

For this header the words are 4500 0034 1C46 4000 4006 0000 C000 020A C633 6414. Their ordinary sum is 0x2CDD1. Folding gives 0xCDD1 + 0x0002 = 0xCDD3; inversion gives 0x322C. Verification includes the stored checksum and produces 0xFFFF when no error is detected. Lowering TTL from 64 to 63 changes 4006 to 3F06, so the updated checksum is 0x332C.

The checksum protects only the IP header. TCP separately checks its segment and an IP-address pseudo-header end to end. UDP's checksum is optional over IPv4; zero means it was omitted. With 20-byte IP and TCP headers, a 1,500-byte datagram carries 1,460 application bytes, so combined header overhead is about 2.7%.

Normal forwarding preserves the source and destination IP addresses while replacing link-layer addressing at each link. NAT is an exception that rewrites IP addresses. IPv4 options, such as route recording, make the header variable and often require slower processing.

Key Takeaways

  • IHL counts four-byte words; Total length counts header plus payload bytes.
  • TTL limits circulation and Protocol identifies the payload protocol.
  • The IPv4 checksum covers the header and changes when TTL changes.
  • One's-complement addition folds carries before the final inversion.
  • Ordinary forwarding preserves IP endpoints while link-layer addressing changes.

2.2 Split IPv4 datagrams and rebuild their payload

A link's maximum transmission unit (MTU) limits the IP datagram size it can carry. When an IPv4 packet is too large for the next link, a router can fragment it if DF is clear. Every fragment needs its own IP header, so the MTU is not all available for data.

Find the fragment sizes

For a datagram without options:

  1. Subtract the header length from the original total length.
  2. Subtract one header from the MTU to find space per fragment.
  3. Round that space down to a multiple of 8 for every non-final fragment.
  4. Split the payload, putting any remainder in the final fragment.
  5. Divide the payload bytes preceding each piece by 8 to get its offset.
  6. Add a header to each piece for its Total length; set MF on all but the final piece.

The fragments share an Identification value. Together with source, destination and protocol, it identifies their original datagram. MF means more fragments follow in payload order. Offset measures position within the original payload, never the original header.

A 4,000-byte datagram

With a 20-byte header and MTU 1,500, the payload is 3,980 bytes. Space for data is 1,480 bytes, already divisible by 8.

FragmentData bytesTotal bytesOffsetMF
First1,4801,50001
Second1,4801,5001851
Third1,0201,0403700

The second offset is 1,480 divided by 8. The third is 2,960 divided by 8. The payload still totals 3,980 bytes, but three headers make the transmitted total 4,040 bytes.

For a 2,400-byte datagram with a 20-byte header and MTU 1,000, the 980-byte space rounds down to 976. The data pieces are 976, 976 and 428 bytes. Total lengths are 996, 996 and 448; offsets are 0, 122 and 244; MF values are 1, 1 and 0. Filling every non-final fragment to 1,000 total bytes would violate the offset alignment rule.

Reassemble at the destination

Only the destination host reassembles the original datagram. Fragments can arrive out of order or be fragmented again on a smaller link. The destination places data by offset and learns the ending position from the fragment with MF 0. That final fragment arriving first does not mean reassembly is complete: every earlier byte must also be present. Missing fragments eventually cause reassembly to time out.

Fragmentation adds headers and makes loss more costly: one missing fragment prevents delivery of the whole transport segment. Port numbers occur in the first fragment, which complicates filtering and NAT for later fragments. Overlapping fragments can also create security problems.

Discover the path limit

With Don't Fragment (DF) set, an oversized IPv4 datagram is dropped. The router returns ICMP Destination Unreachable, type 3 code 4, reporting that fragmentation is needed and giving the next-link MTU. Path MTU discovery uses this feedback to reduce packet size. Blocking the feedback can create a black hole in which small packets work but large ones disappear.

For TCP over an MTU of 1,500 with 20-byte IP and TCP headers, the data MSS is 1,460 bytes. IPv6 routers never fragment: they return ICMPv6 Packet Too Big so the source can reduce its packet size or fragment at the source.

Key Takeaways

  • A fragment's total length includes its own IP header.
  • Non-final fragment data lengths must be multiples of 8 bytes.
  • Offsets count 8-byte units within the original payload.
  • All fragments share Identification; only the final fragment has MF 0.
  • The destination reassembles and needs every part of the payload.
  • DF causes an oversized IPv4 packet to be dropped with MTU feedback.
3

Configure hosts and share IPv4 addresses

A new host needs settings before it can exchange useful IP traffic. DHCP supplies those settings and manages how long the address stays assigned. On many IPv4 networks, NAT then translates the host's private address and transport port for communication outside the network. Follow the configuration exchange first, then track the changing packet fields in both directions through a translation table.

3.1 Follow a DHCP lease from discovery to renewal

A host needs an IP address, a subnet mask or prefix length, a default gateway and DNS server addresses. Dynamic Host Configuration Protocol (DHCP) supplies these settings automatically. On a small network the router often acts as the server; a larger network can use a dedicated server for several subnets.

Discover, Offer, Request, ACK

DHCP uses UDP, with server port 67 and client port 68. A new client does not yet have an address or know a server, so the initial exchange uses broadcast delivery.

  1. Discover: the client sends from 0.0.0.0:68 to 255.255.255.255:67. A transaction ID associates replies with this exchange, and the message carries the client's MAC address.
  2. Offer: a server proposes an address, lease duration and settings. More than one server can reply.
  3. Request: the client broadcasts its chosen address and server identifier. The other offering servers can see that they were not selected.
  4. ACK: the selected server confirms the lease. The client can complete configuration and use the address.

For example, a laptop joins a network whose DHCP server is 192.168.1.1. The offer is 192.168.1.101 with mask 255.255.255.0, gateway 192.168.1.1, DNS server 192.168.1.1 and a lease of 86,400 s. After the laptop broadcasts its Request and receives the ACK, it has a 24-hour lease and the settings for local and remote traffic.

An Offer alone is not the completed assignment. A NAK rejects a request that is no longer valid, such as one associated with the wrong network, and the client must restart address acquisition.

Keep or give up the address

A lease allows reuse after a host leaves. With default timers, renewal starts at half the lease duration: the client unicasts a Request to the original server. If renewal fails, at 87.5% of the duration it broadcasts a Request so any suitable server can extend the lease. A 24-hour lease therefore has default renewal and rebinding times of 12 and 21 hours after acquisition.

If the lease expires without extension, the client must stop using that address. A client can send Release when leaving, while Decline reports that the offered address is already in use. The address assigned on a later visit may differ because DHCP manages a reusable pool, not permanent ownership.

Reach a server on another subnet

Routers do not forward the client's limited broadcast as ordinary traffic. A DHCP relay agent on the client's subnet passes the message to a configured remote server. Its gateway-address field identifies the client subnet, allowing the server to choose the correct pool. Replies return through the relay to the client.

The relay and the default gateway serve different jobs even when the same router provides both. Relaying gets the configuration exchange to a remote server; the default gateway carries the configured host's traffic toward other networks. Likewise, the DNS server resolves names and need not be the DHCP server.

A valid address with the wrong default gateway can still leave a host unable to reach off-link destinations. IPv6 has separate configuration mechanisms, including SLAAC from router advertisements and DHCPv6.

Key Takeaways

  • DHCP supplies an address, mask, gateway, DNS settings and lease duration.
  • Initial acquisition uses Discover, Offer, Request and ACK over UDP ports 68 and 67.
  • The initial broadcast Request identifies the selected offer.
  • Default renewal and rebinding begin at 50% and 87.5% of the lease.
  • A relay lets a server configure clients on a different subnet.

3.2 Trace a NAT mapping in both directions

Private IPv4 addresses can be reused in independent networks. The private blocks are 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16. They are not globally routed on the public internet. Network address translation (NAT) lets privately addressed devices communicate using a public address at the network's boundary.

Record the mapping before following the reply

Home routers commonly perform network address and port translation (NAPT). The router changes an outbound packet's source address and source transport port, and records the private/public pair. A returning packet's destination pair is translated back. One-to-one NAT also exists and maps addresses without changing ports.

A laptop at 192.168.1.101:50123 connects to 203.0.113.80:443. Its NAT router has public address 198.51.100.7 and allocates port 40001:

DirectionSourceDestination
Before outbound translation192.168.1.101:50123203.0.113.80:443
After outbound translation198.51.100.7:40001203.0.113.80:443
Reply before inbound translation203.0.113.80:443198.51.100.7:40001
Reply after inbound translation203.0.113.80:443192.168.1.101:50123

The table contains 198.51.100.7:40001 ↔ 192.168.1.101:50123. If a phone at 192.168.1.102 uses the same private port to contact that server, the router can allocate public port 40002. The public port distinguishes the return traffic; the private port alone would not.

Rewriting the IPv4 address changes the header checksum. TCP and checksummed UDP also cover IP addresses through their pseudo-headers, so their checksums must be adjusted. NAPT also rewrites a transport port. The server normally sees the translated public source, not the private one.

Mappings have lifetimes

Outbound traffic usually creates dynamic mappings. An unsolicited inbound packet with no matching mapping is dropped in this basic arrangement. To expose an internal service, a static port-forwarding entry can be installed, or a host can request a mapping through UPnP or Port Control Protocol. STUN helps a host discover its public mapping; TURN relays traffic when direct communication cannot be established.

Idle mappings expire. UDP behavioral requirements call for a timeout of at least two minutes, with five or more recommended. Keepalive traffic can preserve a mapping. The 16-bit port field provides 65,536 numerical values per protocol, but reserved ports and mapping behavior mean that number is not an exact guarantee of simultaneous connections.

What NAT solves and what it costs

Sharing a public address has prolonged IPv4 use. Providers can also use carrier-grade NAT, often assigning customers addresses from the shared block 100.64.0.0/10. A home connection may then pass through both the home NAT and a provider NAT.

Translation reduces direct end-to-end reachability and complicates protocols that carry addresses in their message bodies, such as SIP or active-mode FTP. NAT also reaches into transport fields. IPv6 addresses the underlying scarcity with a larger address space.

NAT's rejection of unmatched inbound traffic is not content inspection. A malicious program can open an outbound connection through the same mapping mechanism as a legitimate client. Firewall policy remains a separate security function.

Key Takeaways

  • NAPT shares public IPv4 addresses by translating address-and-port pairs.
  • Outbound packets change source fields; replies change destination fields.
  • Mappings distinguish hosts even when their private source ports are equal.
  • Translation requires affected IP and transport checksums to be updated.
  • Mapping expiry and missing inbound mappings complicate reachability.
  • NAT conserves addresses but does not inspect traffic for threats.
4

Read IPv6 and connect across IPv4

IPv6 changes both the address space and the work done on each packet. Its fixed header moves optional information into separate headers, and oversized packets return to the source for correction. Deployment also has to work around existing IPv4 systems. Distinguish running two protocols, carrying one inside the other, and translating between them: these solve different communication problems and have different packet-size costs.

4.1 Read the fixed IPv6 header and its extensions

IPv4 has 32-bit addresses, roughly 4.3 billion possible values. IANA distributed its final central-pool IPv4 blocks in February 2011. IPv6 expands addresses to 128 bits, about 3.4 × 10³⁸ values, and simplifies routine header processing. RFC 8200 specifies its basic packet format.

A fixed 40-byte header
FieldBitsPurpose
Version4Value 6 identifies IPv6
Traffic class8DSCP and ECN traffic handling
Flow label20Marks packets belonging to a flow
Payload length16Bytes after the fixed header
Next header8Type of the immediately following header
Hop limit8Remaining forwarding hops
Source address128Sender's IPv6 address
Destination address128Receiver's IPv6 address

The fields total 320 bits, or 40 bytes. Hop limit serves the role of IPv4 TTL: each forwarding router reduces it by 1 and discards the packet when it expires. Flow label can help routers and load balancers treat a flow consistently, for example by selecting a stable path. It does not promise bandwidth.

Payload length excludes the fixed header but includes extension headers. A 1,000-byte TCP segment with no extensions therefore gives Payload length 1,000 and total size 1,040 bytes. IPv4 Total length, in contrast, includes its header.

Follow the Next header chain

Next header identifies either an upper-layer protocol or an extension. Values include TCP 6, UDP 17 and ICMPv6 58; extension types include Hop-by-Hop Options 0, Routing 43, Fragment 44 and Destination Options 60. An extension's own Next header identifies what follows it.

For a source fragment carrying 600 bytes of a TCP segment, an 8-byte Fragment header makes Payload length 608. The fixed header says Next header 44; the Fragment header says Next header 6. The total fragment size is 648 bytes. Reading only the first Next header would mistake an extension for the transport protocol.

What IPv6 removes from routine forwarding

IPv6 has no fixed-header checksum, so changing Hop limit does not require a network-header checksum update. Link-layer and transport error checks still matter. UDP checksums are normally mandatory over IPv6, with a narrow exception for certain tunnels; they are optional over IPv4.

IPv6 routers never fragment. An oversized packet is discarded and triggers ICMPv6 Packet Too Big; the source then reduces size or uses a Fragment header. Every IPv6 link must support an IPv6 MTU of at least 1,280 bytes, with lower-layer adaptation where necessary. Fragmentation still exists at the source.

Options move to extension headers, keeping the basic header length fixed. The two addresses occupy 32 of the 40 bytes, or 80%. At a total size of 1,500 bytes, the 40-byte IPv6 header is about 2.7% overhead, compared with about 1.3% for the usual 20-byte IPv4 header.

Address notation and local operation

Write addresses as eight hexadecimal groups. Remove leading zeros in a group, and compress one run of zero groups using "::". Thus 2001:0db8:0000:0000:0000:0000:0000:0001 becomes 2001:db8::1; 2001:db8::/32 is reserved for documentation.

Hosts can use SLAAC with router advertisements or DHCPv6. IPv6 has multicast instead of broadcast. ICMPv6 carries Neighbor Discovery, which replaces ARP's local address-resolution role, as well as essential error feedback. The larger address space generally removes the need for address-sharing NAT.

Key Takeaways

  • The fixed IPv6 header is 40 bytes and has 128-bit source and destination addresses.
  • Payload length excludes the fixed header but includes extensions.
  • Next header links extensions to each other and to the upper-layer protocol.
  • IPv6 removes the IP header checksum and router fragmentation.
  • The source can fragment; an IPv6 link must support an MTU of at least 1,280 bytes.
  • SLAAC, DHCPv6, multicast and Neighbor Discovery support IPv6 host operation.

4.2 Choose dual stack, tunneling or translation

An IPv4-only host cannot directly exchange IP packets with an IPv6-only host. Every forwarding device must understand the packet it handles, so replacing a network-layer protocol takes coordinated change across a huge installed network. IPv4 and IPv6 consequently coexist. The small ARPANET could switch to TCP/IP on January 1, 1983; the internet cannot repeat that kind of universal "flag day."

Run both with dual stack

A dual-stack host or router implements both IP versions and has addresses for both. DNS can return A records for IPv4 and AAAA records for IPv6. The client can then connect using a version supported by both endpoints.

Happy Eyeballs avoids a long delay when one path is broken by overlapping connection attempts across available addresses and families, usually starting with IPv6 and allowing IPv4 to follow shortly afterward. The connection that succeeds is used. Dual stack does not translate packets; a particular connection uses one IP version.

Carry IPv6 through an IPv4 stretch

A tunnel places a complete IPv6 datagram inside an IPv4 payload. The outer IPv4 header names the tunnel entrance and exit, and Protocol 41 identifies encapsulated IPv6. IPv4-only routers can carry the packet using that outer header without interpreting the inner one.

Suppose host A, 2001:db8:1::10, sends to host F, 2001:db8:2::20. Router B, 192.0.2.1, is the tunnel entrance; router E, 198.51.100.2, is the exit. Routers C and D between them handle only IPv4.

B forwards the IPv6 packet, reducing its Hop limit, and adds the outer header from B to E. C and D reduce the outer IPv4 TTL as they forward. E removes the outer header, reduces the inner Hop limit when forwarding toward F, and sends the IPv6 packet onward. A starting Hop limit of 64 reaches F as 62. The tunnel acts as one IPv6 link; its internal IPv4 routers do not each consume an IPv6 hop. The inner source and destination remain A and F.

The wrapper uses space. With a 20-byte outer IPv4 header and an underlying MTU of 1,500, at most 1,480 bytes remain for the entire inner IPv6 datagram. Tunneling is also used in VPNs and mobile networks.

Translate for incompatible endpoints

NAT64 converts between IPv6 and IPv4 headers while keeping translation state. DNS64 can synthesize an IPv6 destination from an IPv4 server address, often using 64:ff9b::/96. For 192.0.2.33, the final four bytes are hexadecimal C0 00 02 21, giving 64:ff9b::c000:221.

An IPv6-only client sends toward that synthesized address. NAT64 sends the corresponding IPv4 packet to the server, then translates the reply back. DNS64 provides the usable destination; NAT64 performs the packet conversion. Some IPv6-only mobile access networks use this arrangement.

Translation cannot preserve every feature: IPv4 has no direct counterpart for the IPv6 flow label or its extension-header structure. A tunnel preserves a packet inside a wrapper, while translation changes its protocol representation.

Deployment remains uneven across networks and countries. A host gaining IPv6 does not gain direct IPv4 compatibility; it still needs IPv4 support or a translation path to communicate with an IPv4-only service.

Key Takeaways

  • Dual stack implements both protocols without converting packets.
  • A tunnel encapsulates IPv6 in IPv4, with Protocol 41 in the outer header.
  • Tunnel-internal IPv4 routers decrement only the outer TTL.
  • A 20-byte tunnel wrapper reduces the available inner MTU by 20 bytes.
  • DNS64 synthesizes an address and NAT64 translates packets for IPv4-only services.
5

Program forwarding and evaluate middleboxes

Destination lookup is one way to decide what happens to a packet. A flow table can match several header fields and choose forwarding, dropping or rewriting actions. SDN coordinates these local decisions across a network. Once devices also translate, filter or balance traffic, they raise an architectural question: which functions belong inside the network, and which still need the knowledge available only at the endpoints?

5.1 Apply flow-table matches, priorities and actions

Generalized forwarding extends destination-based lookup into a broader match-plus-action model. A switch compares packet header fields with entries and performs the selected action. The same device can act as an IP router, Ethernet switch, firewall, translator or load balancer depending on the installed rules.

Read an entry

An entry specifies match fields, priority and actions. It also has counters, such as matched packets and bytes and elapsed time since installation. An idle timeout removes an entry after a period without matches; a hard timeout removes it after a fixed time since installation even if traffic continues.

OpenFlow 1.0 provides twelve match fields: ingress port; source MAC, destination MAC, EtherType, VLAN ID and VLAN priority; source IP, destination IP, IP protocol and IP type-of-service DSCP bits; and transport source and destination ports. These span several layers. TTL is not a supported match field in that version. Later versions support additional fields, including IPv6 fields.

A wildcard accepts any value in its field. For example, destination 10.2.. denotes 10.2.0.0/16. All fields wildcarded creates a match for every packet. A rule naming TCP port 22 also needs the appropriate IP/TCP protocol match so the transport-port field has the intended meaning.

Resolve overlapping matches

For overlapping wildcard rules, the greatest explicit priority wins. Specificity alone does not choose the winner. OpenFlow 1.0 has an additional rule: a completely exact entry, with no wildcard fields, precedes wildcard entries. A rule matching one exact IP address while leaving other fields wildcarded is still a wildcard entry.

Consider two entries, with all unspecified fields wildcarded:

MatchPriorityAction
IPv4, TCP, destination port 22100Drop
IPv4, destination 10.2.0.0/1610Forward on port 3

A TCP packet for 10.2.0.5:22 matches both and is dropped. A TCP packet for 10.2.0.5:443 matches only the forwarding entry. This differs from longest prefix matching: the winner comes from the assigned priority, not the destination prefix length.

Take an action

Forwarding can select one output, several outputs for copying, or delivery to the controller. An empty action list drops the packet. Modify actions rewrite supported header fields, for example a destination IP address and transport port, before the packet is sent onward.

A table miss has no matching entry. In OpenFlow 1.0 the switch sends the packet to the controller; more general flow-table designs can configure a miss to drop or request controller help. The controller can install an entry so later packets stay on the fast local path.

Flow matching reads headers. Looking inside application payloads is deep packet inspection, a separate function that ordinary OpenFlow matching does not supply. Likewise, OpenFlow is a switch-control protocol, while SDN is the broader architecture that separates control from forwarding. Programmable data-plane languages such as P4 can define which headers a device parses, extending programmability beyond a fixed list of match fields.

Key Takeaways

  • Flow entries combine matches, priorities, actions, counters and timeouts.
  • OpenFlow 1.0 matches a fixed set of fields across several layers.
  • Wildcard-entry priority is explicit; a fully exact OpenFlow 1.0 entry takes precedence.
  • Forward, drop, controller delivery and header modification implement different behaviors.
  • Table-miss handling must be distinguished from an explicit drop entry.
  • Header matching does not inspect application payloads.

5.2 Coordinate local rules into an SDN network

A switch can apply a rule correctly while a packet still fails farther along the path. Software-defined networking (SDN) uses a controller and network applications to coordinate the forwarding behavior of several switches.

Separate the roles

SDN combines flow-based forwarding, separation of data and control planes, control functions outside the switches, and software interfaces for programming the network. A southbound interface, such as OpenFlow, carries instructions between controller and switches. A northbound interface lets network applications request behavior from the controller.

The controller is logically centralized: it presents one coordinated control system. Production systems can replicate that control across several physical servers for scale and reliability. A packet already covered by a flow entry is handled in the switch without a controller round trip.

Build a path one switch at a time

Traffic from 10.1.0.0/16 at s1 must reach 10.3.0.0/16 through s2 and s3. With other fields wildcarded, the relevant path entries are:

  • On s1: ingress 1, source 10.1.0.0/16, destination 10.3.0.0/16 → output 4 toward s2.
  • On s2: ingress 2, source 10.1.0.0/16, destination 10.3.0.0/16 → output 3 toward s3.
  • On s3: destination 10.3.0.6 → output 1 toward that host.

Each output must lead to a link whose receiving switch has a compatible entry. A missing entry can produce a black hole; incompatible entries can send packets in a loop. Matching the source as well as the destination allows traffic from different source networks to take different paths to the same destination. Plain destination-only lookup cannot make that distinction.

Use the same mechanism for several jobs

A firewall can forward source 10.3.0.0/16 at priority 200 and drop all traffic at priority 100. Add an IPv4/TCP destination-port-22 drop at priority 300 to block SSH even from the allowed source network. These are wildcard rules, so their explicit priorities decide overlap. Reversing those priorities would allow the broader permit to defeat the intended SSH block.

An Ethernet forwarding entry can match destination MAC 22:A7:23:11:E1:02 and output port 3 regardless of IP addresses. A load-balancing pair can send traffic to 10.4.0.0/16 from source 10.1.0.0/16 on port 3, and from 10.2.0.0/16 on port 4, provided both paths reach that destination. Address and port rewriting before forwarding can implement NAT behavior.

Keep local and network-wide correctness separate

Inspecting one switch proves only that switch's match and action. To verify a path, follow the packet's actual header and ingress port through every switch, including any header changes. Also check the return direction when the application needs replies: installing an outward path does not automatically install its reverse.

SDN is used in data centers, networks between data centers such as Google's B4, and cellular core networks. Software control and commodity "white-box" switches let operators change behavior without depending on one vendor's dedicated appliance feature cycle. Computing the routes belongs to the control plane; matching the installed entries remains data-plane work.

Key Takeaways

  • SDN coordinates flow-based forwarding through separate control software.
  • Southbound interfaces reach switches; northbound interfaces reach applications.
  • Logical centralization can be implemented by replicated controller servers.
  • Every hop needs a compatible entry for the packet that actually arrives.
  • Source-sensitive paths, filtering, switching and rewriting use the same match/action model.

5.3 Weigh middleboxes against end-to-end design

A middlebox is a device on the communication path that does more than an ordinary IP router's standard forwarding job. RFC 3234 includes functions such as translation, filtering and traffic optimization. A single home gateway can combine routing, NAT and a firewall.

Why operators put functions on the path

NAT shares addresses. Security devices, including firewalls and intrusion detection systems, block or flag traffic based on headers or content. Performance devices include load balancers, caches, content-delivery servers and WAN optimizers. A packet can meet several such functions on one journey.

A load balancer presents one service address to clients and distributes connections across servers. For an ordinary stateful connection, packets need to reach the same backend. A hash of the 5-tuple—source address, destination address, source port, destination port and protocol—can make that selection consistent. Choosing a different backend for every packet would break a connection whose state exists only at the selected server.

These functions once commonly used closed appliances. They can now run on commodity switches, under SDN control, or as network functions virtualization (NFV): software implementations of functions such as NAT or firewalls on ordinary servers. NFV describes how the function is implemented; SDN describes how control is organized.

The IP hourglass

The internet has many applications and transport protocols above IP and many link and physical technologies below it. IP forms their common narrow waist. A new application does not need a different network layer for each link technology, and a new link does not need separate support for every application.

The architectural tradition described in RFC 1958 places connectivity at the center, uses IP as the common mechanism, and puts much intelligence at the endpoints. Middleboxes add functions inside that common path, thickening the waist and making communication depend on behavior beyond ordinary IP forwarding.

Apply the end-to-end argument

The end-to-end argument, first presented by Saltzer, Reed and Clark in 1981, asks where a function can be implemented completely and correctly. If that requires application knowledge available only at the endpoints, the endpoint implementation is still needed even when the network supplies a partial version.

For a reliable file transfer, error-free link delivery is insufficient. A router memory error, software bug or disk problem can still change the file. The receiving application must check the whole received file, for example with an agreed checksum, and request repair if the result differs. Local retransmission on a noisy Wi-Fi link can still improve performance by repairing common errors quickly. It does not replace the file-level check.

The cost of depending on today's protocols

Middleboxes can reduce address use, improve security policy enforcement and speed delivery. They can also restrict direct communication and cause ossification: devices assume a familiar protocol format and reject or alter unfamiliar behavior. A new transport can fail even when the endpoint software supports it.

QUIC uses UDP to pass through common deployed NAT and firewall behavior, and encrypts most transport information so intermediate devices have less opportunity to depend on its details. The design balances deployability with room to evolve. Today's internet includes programmable switches, content-delivery systems and large data centers; end-to-end design remains a guide for deciding what endpoint checks are essential within that more complex network.

Key Takeaways

  • Middleboxes add translation, security or performance functions to the data path.
  • A stateful connection needs a consistent backend selection.
  • IP's narrow waist lets upper and lower technologies evolve independently.
  • End-to-end correctness can require endpoint checks despite reliable links.
  • Local recovery can improve performance without replacing endpoint verification.
  • Middleboxes can make new protocols difficult to deploy through ossification.

Network Layer Data Plane examples

5 Walkthroughs

1

Follow a packet from lookup to departure

15 steps
Trace forwarding, compare router resources, and predict how waiting packets are served.
  1. 1
    IntroductionStart with one arriving packet

    A router has learned how to reach a network, but several packets arrive at once. To predict what happens, follow three decisions: the table selects an output, the switching fabric moves the packet, and the scheduler selects a departure.

    These decisions can succeed separately: the right output may be known even when the packet must wait for a resource.

  2. 2
    AnalogySeparate the plan from the next exit

    Planning a road trip resembles routing: deciding a path across many roads. Taking the selected exit at one interchange resembles forwarding: acting locally on that plan.

    At a router, the control plane supplies the forwarding table, and the data plane applies it to packets. A new packet needs a lookup; a failed link may require the control plane to revise the plan.

  3. 3
    ChallengeIdentify the work after a link failure

    A router learns that a link failed, changes its table, then sends an arriving packet through a different interface. Which part is control-plane work and which part is data-plane work?

    ---reveal---

    Changing the forwarding information is control-plane work. Applying the new entry to the arriving packet is data-plane forwarding. The packet does not itself cause a complete route computation at every hop.

  4. 4
    Key InsightKeep IP delivery separate from TCP recovery

    IP provides best-effort delivery. A datagram may disappear or arrive out of order, and IP does not retransmit it.

    TCP detects loss, retransmits missing data and restores byte order at the endpoints. Seeing a complete file arrive therefore does not establish that the network layer guaranteed each packet. The application benefits from several layers doing different jobs.

  5. 5
    ExplanationEnter the router

    An input port receives the frame, extracts the IP datagram and looks up an output using its local forwarding information. The switching fabric connects that input to the chosen output.

    The output port can buffer the datagram, add outgoing link-layer framing and transmit it. A separate routing processor supplies control and management; it is not consulted for every ordinary hardware lookup.

  6. 6
    ExampleFind every matching prefix

    The table has 10.0.0.0/8 → output 0, 10.44.0.0/16 → output 1, 10.44.16.0/20 → output 2 and /0 → output 3. The destination is 10.44.23.9.

    It matches /8 and /16. The /20 also matches because its third-octet range is 16–31. The default matches every address. Finding all candidates comes before selecting the longest one.

  7. 7
    ExampleChoose the most specific match

    Of the matching prefixes, /20 is longest, so the packet leaves on output 2. Neither the first matching row nor the largest output number decides the result.

    For destination 10.44.40.9, the /20 no longer matches, so /16 selects output 1. A forwarding exception only applies inside its own bit prefix; the broader entry remains useful outside it.

  8. 8
    ChallengeUse a prefix that ends inside an octet

    The table also has 10.44.24.0/21 → output 4. Where do packets for 10.44.26.8 and 10.44.19.8 go?

    ---reveal---

    The /21 covers third-octet values 24–31, so 10.44.26.8 takes output 4. The address 10.44.19.8 still matches /20 but not /21, so it takes output 2. Compare the prefix bits before comparing the prefix lengths.

  9. 9
    ConnectionSee why the fabric matters

    A shared bus moves one packet at a time, even when two packets want different outputs. A crossbar can connect different inputs to different outputs concurrently.

    That parallelism has a limit: two packets requesting the same output still compete. Table lookup selects a destination for the packet; it does not reserve enough output capacity to transmit every simultaneous arrival.

  10. 10
    ExplanationLocate a blocked packet

    At an input FIFO, the front packet waits for busy output A. The next packet wants idle output B, but cannot pass the front packet. This is head-of-the-line blocking.

    Separate virtual output queues let the input offer a packet for B without first sending its packet for A. An output queue is a different problem: packets already reaching one output faster than its link can send them.

  11. 11
    ExampleTurn queued bytes into delay

    An admitted packet has 600,000 bytes waiting ahead on a 12 Mb/s link. First convert the queue to bits: 4,800,000 bits. Dividing by 12,000,000 bits per second gives 0.4 s before transmission can start.

    A large buffer can therefore cause noticeable delay without being full. If tail drop is in use and the buffer becomes completely full, a new arrival is discarded instead of joining that queue.

  12. 12
    ChallengeApply non-preemptive priority

    Low-priority packet K is already transmitting. High-priority M arrives, then low-priority N, then high-priority P. What is the departure order?

    ---reveal---

    K finishes first because service is non-preemptive. M and P follow in their high-priority FIFO order, then N. Priority changes the next selection; it does not interrupt bits of a packet that are already being transmitted.

  13. 13
    Key InsightShare bits, not just packet turns

    Round robin gives nonempty classes packet turns. With unequal packet lengths, equal turns need not mean equal bandwidth.

    WFQ accounts for length to approximate weighted bit-by-bit service. Weights 2:1 on a 90 Mb/s link give about 60 and 30 Mb/s when both classes stay backlogged. If one becomes empty, a work-conserving scheduler lets the other use the available capacity.

  14. 14
    ChallengeConnect forwarding and queuing

    A /24 lookup selects output 5 correctly. Three equal packets reach that output during one packet-transmission time; the link sends one. Would replacing the lookup table or making the fabric faster remove the remaining queue?

    ---reveal---

    No. Two packets still wait because the output link can transmit only one in that time. The lookup determined where to go; a faster fabric cannot increase that outgoing link's line rate.

  15. 15
    RecapDiagnose the stage that limits delivery

    Ask what evidence a delay gives you. A wrong output points toward forwarding information or matching. A free output left unused behind an input head points toward HOL blocking. Several arrivals for one busy link point toward output contention.

    A drop policy decides what remains buffered, while a scheduler decides which stored packet departs next. These observations locate different causes even when the application sees the same symptom: a late or missing packet.

2

Decode a header and fragment its payload

12 steps
Work through IPv4 sizes, a checksum, and the offsets needed for destination reassembly.

Save this lesson to follow every Walkthrough step by step.

  1. 1
    IntroductionRead counts before calculating
  2. 2
    ExampleDecode the first byte and size
  3. 3
    ExplanationKnow which fields change
  4. 4
    ExampleFold a checksum carry
  5. 5
    ChallengeSeparate header data from application data
  6. 6
    ExampleFind space for fragment data
  7. 7
    ExampleSplit the payload and add headers
  8. 8
    ExamplePlace fragments in the original payload
  9. 9
    ChallengeReassemble out of arrival order
  10. 10
    TipRound down when the MTU leaves an odd fit
  11. 11
    ChallengeCombine header interpretation with MTU handling
  12. 12
    RecapCheck fragment work against the byte ranges
3

Join a network and follow a translated connection

11 steps
Follow DHCP configuration, then use the resulting host address in a two-way NAPT trace.

Save this lesson to follow every Walkthrough step by step.

  1. 1
    IntroductionStart before the host has an address
  2. 2
    ExampleDiscover a DHCP server
  3. 3
    ExampleChoose and confirm the offer
  4. 4
    ChallengeWork out the lease checkpoints
  5. 5
    ExampleCreate the outbound translation
  6. 6
    ExampleUse the mapping on the reply
  7. 7
    ChallengeKeep equal private ports distinct
  8. 8
    Key InsightSeparate mapping from security policy
  9. 9
    ConnectionRecognize a second translation boundary
  10. 10
    ChallengeConnect a renewed address to existing NAT state
  11. 11
    RecapRead the two kinds of state separately
4

Follow IPv6 through a mixed-version path

12 steps
Read an extension chain, account for tunnel overhead, and distinguish encapsulation from translation.

Save this lesson to follow every Walkthrough step by step.

  1. 1
    IntroductionChoose the right compatibility mechanism
  2. 2
    ExplanationRead the fixed header
  3. 3
    ExampleFollow an extension to TCP
  4. 4
    ChallengeRespond to a smaller IPv6 link
  5. 5
    ConnectionUnderstand the missing checksum
  6. 6
    ExplanationUse dual stack for two available families
  7. 7
    ExampleWrap the packet across an IPv4 section
  8. 8
    ExampleTrace the two lifetime fields
  9. 9
    ChallengeAllow room for the wrapper
  10. 10
    ExampleTranslate for an IPv4-only server
  11. 11
    ChallengeCombine packet reading with tunnel capacity
  12. 12
    RecapName the scope of each header
5

Turn flow rules into a working path

14 steps
Resolve overlapping rules, coordinate switches, and decide what middleboxes can and cannot establish.

Save this lesson to follow every Walkthrough step by step.

  1. 1
    IntroductionBuild behavior from local decisions
  2. 2
    ExplanationRead the match and action
  3. 3
    ExampleResolve two wildcard matches
  4. 4
    ChallengeDistinguish exact from partly specified
  5. 5
    TipSeparate duration from inactivity
  6. 6
    ExplanationPut control outside the switches
  7. 7
    ExampleInstall the first link of a path
  8. 8
    ExampleComplete the intermediate and final decisions
  9. 9
    ChallengeDiagnose a returning path
  10. 10
    ConnectionRecognize middlebox work
  11. 11
    ExplanationKeep a common waist for many technologies
  12. 12
    ChallengeDecide where complete verification belongs
  13. 13
    ChallengeConnect a correct path to a correct result
  14. 14
    RecapUse evidence at the right level

Network Layer Data Plane practice questions

40 Practice Questions in 4 sets

Set 1: Explain configuration, queues and coexistence10 Practice Questions

Question 1 of 10

A transfer uses TCP over IP. TCP resends missing data and delivers bytes in order. What delivery guarantee does IP itself supply?
  1. Guaranteed delivery once TCP opens a connection.
  2. Best-effort delivery without a delivery or ordering guarantee.
  3. Guaranteed ordering with possible packet loss.
  4. Guaranteed delivery with an unspecified time limit.
Show answerHide answer
Answer: B
IP remains best effort even when the transport protocol adds reliability. TCP detects missing data, retransmits it and restores byte order at the endpoints. Attributing that successful delivery to IP would assign a higher-layer mechanism to the network-layer service model.

Question 2 of 10

Two input packets want different idle output ports. A shared-bus fabric can move only one packet at a time. What architectural change would allow both internal transfers simultaneously?
  1. A larger FIFO buffer at each existing output.
  2. A higher-priority class for each of the two packets.
  3. A second table copy on each input line card.
  4. A crossbar fabric with the required input-output connections.
Show answerHide answer
Answer: D
A crossbar can connect different inputs to different outputs concurrently. The shared bus serializes transfers even though the desired outputs are distinct and idle. Larger buffers store waiting packets, but they do not create an additional simultaneous path through that bus.

Question 3 of 10

A 120 Mb/s WFQ output has weights 6, 3 and 1. The third class becomes empty; the other two stay backlogged and use different packet sizes. What approximate bandwidths should the active classes receive?
  1. 80 Mb/s and 40 Mb/s.
  2. 72 Mb/s and 36 Mb/s.
  3. 60 Mb/s and 60 Mb/s.
  4. 90 Mb/s and 30 Mb/s.
Show answerHide answer
Answer: A
The active weight sum becomes 9, so the shares are 6/9 and 3/9 of 120 Mb/s: 80 and 40. Keeping 72 and 36 would leave the empty class's share unused. WFQ accounts for packet lengths, so unequal sizes do not turn these weighted bandwidth shares into equal packet turns.

Question 4 of 10

With the IPv4 checksum field zeroed, the ordinary sum of the header's 16-bit words is 0x1BEEF. What checksum should be stored?
  1. 0x4110.
  2. 0xBEF0.
  3. 0x410F.
  4. 0xBEEE.
Show answerHide answer
Answer: C
Fold the carry by adding 0x0001 to 0xBEEF, giving 0xBEF0. Inverting all 16 bits gives 0x410F, the checksum to store. The near result 0x4110 comes from inverting the low word before accounting for the end-around carry.

Question 5 of 10

A 1,420-byte IPv4 datagram has DF set. Its next link has MTU 1,280. What does the router do?
  1. Split it into two fragments and forward both.
  2. Forward it with the DF flag cleared.
  3. Drop it and return ICMP fragmentation-needed feedback.
  4. Reassemble it with the next packet before forwarding.
Show answerHide answer
Answer: C
The packet exceeds the link MTU, and DF prohibits fragmentation. The router drops it and returns ICMP fragmentation-needed feedback with the MTU so the source can reduce size. Splitting it would be possible for an eligible IPv4 datagram with DF clear, but not for this one.

Question 6 of 10

A host receives an eight-hour DHCP lease at 06:00 using default timers. Its server stops responding before renewal, but the lease has not expired. At 13:00, what kind of renewal request should the client begin sending?
  1. A unicast Request only to the original server.
  2. A broadcast Request to any suitable DHCP server.
  3. A broadcast Discover using a newly assumed address.
  4. A unicast Release followed by continued address use.
Show answerHide answer
Answer: B
Default renewal begins at 10:00, four hours into the lease. Rebinding begins after seven hours, at 87.5% of eight hours, so at 13:00 the client broadcasts Requests for a server that can extend the lease. Remaining with unicast-only renewal misses this transition; expiry is still an hour away.

Question 7 of 10

Two private hosts use TCP source port 54000 to reach the same server and port through one NAPT public address. How can return packets be distinguished?
  1. Assign a different public source port to each mapping.
  2. Keep both source ports and match only the public address.
  3. Rewrite the server's port to a separate private port.
  4. Deliver each reply to both hosts and let TCP decide.
Show answerHide answer
Answer: A
NAPT gives the connections distinct public ports and records their corresponding private address-port pairs. Replies then have different public destinations even though both hosts chose private port 54000. Keeping the same public endpoint for both connections to this server would leave those replies indistinguishable.

Question 8 of 10

Two IPv6 networks need to communicate across an IPv4-only transit section. What mechanism can preserve their IPv6 packets while crossing that section?
  1. Run dual-stack IPv4 and IPv6 only at the two endpoints.
  2. Translate each IPv6 packet to IPv4, then rebuild it.
  3. Send IPv6 packets directly through the IPv4-only routers.
  4. Encapsulate the IPv6 packets inside an IPv4 tunnel.
Show answerHide answer
Answer: D
A tunnel puts each complete IPv6 packet inside an IPv4 packet that the transit routers can forward. The tunnel exit removes the outer header and continues IPv6 forwarding. Rewriting the IPv6 destination into an IPv4 form would be protocol translation, not preservation of the original inner packet.

Question 9 of 10

Traffic from 10.7.0.0/16 to 10.9.0.0/16 should follow a → b → c. Switch a outputs toward b; c has a rule toward the destination host. At b, the only relevant entry matches ingress 5, but the link from a arrives on ingress 6; a wildcard drop handles the rest. Why is the path broken?
  1. Switch a must recompute c's destination prefix for each packet.
  2. Switch c's host rule forces b to select ingress 5.
  3. The packet misses b's path entry and matches its drop entry.
  4. The controller must forward every packet between a and c itself.
Show answerHide answer
Answer: C
The packet arrives at b on ingress 6, so it cannot match the entry requiring ingress 5 even though its addresses fit the intended path. It therefore reaches b's fallback drop. A correct action at a and a valid host entry at c cannot replace the missing compatible decision at the intermediate hop.

Question 10 of 10

A service keeps each TCP connection's state on one backend server. Its load balancer chooses a server independently for every packet. What change would preserve connection continuity?
  1. Alternate servers after every two consecutive packets.
  2. Choose a consistent backend from each connection's 5-tuple.
  3. Choose the currently shortest queue for each packet independently.
  4. Choose a backend using only the packet's payload length.
Show answerHide answer
Answer: B
Packets belonging to one connection need the backend holding that connection's state. A consistent 5-tuple-based selection groups those packets together. Independent per-packet queue selection can appear efficient, but it may deliver later packets to a server that has none of the connection's existing state.
Set 2: Read packets and follow local decisions10 Practice Questions

Save this lesson to see every answer and practice every set.

Question 1 of 10

A router receives a datagram and uses an installed table to choose output 4. What network-layer job is it performing?
  1. Computing a new route.
  2. Updating the routing table.
  3. Forwarding the datagram.
  4. Opening a TCP connection.
Show answerHide answer

Save this lesson to see this answer.

Question 2 of 10

A table has 10.0.0.0/8 → port 1, 10.36.0.0/16 → port 2, 10.36.8.0/21 → port 3 and /0 → port 4. Where does a packet for 10.36.14.9 leave?
  1. Port 3.
  2. Port 1.
  3. Port 2.
  4. Port 4.
Show answerHide answer

Save this lesson to see this answer.

Question 3 of 10

An admitted packet has 250,000 bytes queued ahead of it on a 20 Mb/s output. How long does that queued data take to transmit?
  1. 0.0125 s.
  2. 0.80 s.
  3. 0.20 s.
  4. 0.10 s.
Show answerHide answer

Save this lesson to see this answer.

Question 4 of 10

An IPv4 packet has IHL 7 and Total length 180 bytes. How many bytes are in its IP payload?
  1. 173 bytes.
  2. 152 bytes.
  3. 160 bytes.
  4. 208 bytes.
Show answerHide answer

Save this lesson to see this answer.

Question 5 of 10

A 3,300-byte IPv4 datagram with a 20-byte header and DF clear meets MTU 1,200. Fragments use the largest permitted non-final payloads. What are the final fragment's Total length, offset and MF?
  1. 940 bytes; offset 295; MF 0.
  2. 948 bytes; offset 294; MF 0.
  3. 928 bytes; offset 294; MF 0.
  4. 948 bytes; offset 299; MF 0.
Show answerHide answer

Save this lesson to see this answer.

Question 6 of 10

A new DHCP client has received two Offers and selected one. What message announces its selection to both servers?
  1. A unicast DHCP Discover.
  2. A broadcast DHCP ACK.
  3. A unicast DHCP Release.
  4. A broadcast DHCP Request.
Show answerHide answer

Save this lesson to see this answer.

Question 7 of 10

A NAT table contains 203.0.113.9:61003 ↔ 10.8.0.14:53002. A matching TCP reply arrives for the public endpoint. What destination pair does NAT write before delivering it inside?
  1. 10.8.0.14:53002.
  2. 10.8.0.14:61003.
  3. 203.0.113.9:53002.
  4. 203.0.113.9:61003.
Show answerHide answer

Save this lesson to see this answer.

Question 8 of 10

An IPv6 packet has Payload length 920 and no extension headers. What is the size of the complete IPv6 packet?
  1. 920 bytes.
  2. 880 bytes.
  3. 960 bytes.
  4. 940 bytes.
Show answerHide answer

Save this lesson to see this answer.

Question 9 of 10

Two OpenFlow 1.0 wildcard entries match a TCP packet: destination 10.9.0.0/16 at priority 80 forwards on port 2; IPv4/TCP destination port 22 at priority 120 drops. The packet is for 10.9.4.7:22. What happens?
  1. The packet is dropped.
  2. The packet uses port 2.
  3. It goes to the controller.
  4. Both entries are applied.
Show answerHide answer

Save this lesson to see this answer.

Question 10 of 10

A factory transfers a calibration dataset over links that repair frame errors. The data could still be altered in router memory or when saved at the receiving machine. What check is needed to establish that the saved dataset matches the original?
  1. A larger link-layer checksum on the final link.
  2. A transport-port check at each router.
  3. A successful frame acknowledgment on every link.
  4. An endpoint check of the complete saved dataset.
Show answerHide answer

Save this lesson to see this answer.

Set 3: Trace packet changes across the path10 Practice Questions

Save this lesson to see every answer and practice every set.

Question 1 of 10

A non-preemptive priority output is sending low-priority packet L0. While it transmits, H1, L1 and H2 arrive in that order, where H is high priority. No more packets arrive. What is the departure order?
  1. L0, H1, H2, L1.
  2. H1, H2, L0, L1.
  3. L0, H1, L1, H2.
  4. L0, L1, H1, H2.
Show answerHide answer

Save this lesson to see this answer.

Question 2 of 10

A 1,180-byte IPv4 datagram has IHL 6 and carries TCP with a 24-byte header. It crosses an ordinary router with no NAT. How many application bytes does it carry, and what IP fields must change during normal forwarding?
  1. 1,136 bytes; TTL and destination address.
  2. 1,132 bytes; source address and transport ports.
  3. 1,132 bytes; TTL and Header checksum.
  4. 1,156 bytes; TTL and Header checksum.
Show answerHide answer

Save this lesson to see this answer.

Question 3 of 10

An IPv4 fragment has offset 150, MF 1 and 800 data bytes. A later router splits it into two equal data pieces with separate 20-byte headers. What offsets and MF flags do the two new fragments need?
  1. Offsets 0 and 50; MF 1 and 0.
  2. Offsets 150 and 200; MF 1 and 0.
  3. Offsets 150 and 202; MF 1 and 1.
  4. Offsets 150 and 200; MF 1 and 1.
Show answerHide answer

Save this lesson to see this answer.

Question 4 of 10

Clients on subnet A broadcast DHCP Discover, but the only DHCP server is on subnet B across a router. What function lets the server receive and identify requests from subnet A?
  1. A NAT rule that changes every Discover to the server's source address.
  2. A DHCP relay that supplies the client subnet's gateway-address field.
  3. A DNS server that answers the Discover with the server's address.
  4. A forwarding rule that broadcasts all IP packets across both subnets.
Show answerHide answer

Save this lesson to see this answer.

Question 5 of 10

A private host opens a connection to a malicious service through NAT. Why can NAT's dynamic mapping allow the service's reply to reach the host?
  1. The outbound connection created a mapping for its return traffic.
  2. Private source addresses make the service's content trustworthy.
  3. The NAT checksum verifies that the payload is harmless.
  4. An outbound connection gives every public sender a permanent mapping.
Show answerHide answer

Save this lesson to see this answer.

Question 6 of 10

An IPv6 source sends a fragment with an 8-byte Fragment header and 704 bytes of transport-segment data. What are Payload length and total packet size?
  1. 704 bytes and 744 bytes.
  2. 752 bytes and 792 bytes.
  3. 712 bytes and 744 bytes.
  4. 712 bytes and 752 bytes.
Show answerHide answer

Save this lesson to see this answer.

Question 7 of 10

An IPv6 packet has a 40-byte fixed header, one 8-byte extension and a TCP header of 20 bytes. It crosses an IPv4 tunnel whose outer header is 20 bytes and whose limiting IPv4 MTU is 1,400. What is the largest application payload that fits without fragmentation?
  1. 1,332 bytes.
  2. 1,312 bytes.
  3. 1,352 bytes.
  4. 1,360 bytes.
Show answerHide answer

Save this lesson to see this answer.

Question 8 of 10

An OpenFlow 1.0 table has a completely exact entry matching every supported field of a packet, action output 7. A wildcard IPv4/TCP port-443 drop has priority 500. The packet matches both. What happens?
  1. It is dropped because 500 outranks an exact entry.
  2. It is sent to the controller to resolve the overlap.
  3. It leaves on port 7 through the completely exact entry.
  4. It is copied to port 7 before the wildcard entry drops it.
Show answerHide answer

Save this lesson to see this answer.

Question 9 of 10

A network application asks an SDN controller to install a traffic policy. The controller then programs switches using OpenFlow. What interfaces carry those two interactions?
  1. Southbound to the controller; northbound to the switches.
  2. Northbound to the controller; southbound to the switches.
  3. Northbound for both policy requests and switch programming.
  4. Southbound for both policy requests and switch programming.
Show answerHide answer

Save this lesson to see this answer.

Question 10 of 10

A new transport protocol works between two updated hosts on a test link. On an internet path, a middlebox rejects packets because it recognizes only older transport formats. What architectural problem does this illustrate?
  1. Protocol ossification caused by an in-path dependency.
  2. Head-of-the-line blocking in an input FIFO.
  3. A flow-label collision at the destination host.
  4. Insufficient end-to-end application encryption at the sender.
Show answerHide answer

Save this lesson to see this answer.

Set 4: Diagnose behavior and combine packet rules10 Practice Questions

Save this lesson to see every answer and practice every set.

Question 1 of 10

A table has 10.80.0.0/16 → A, 10.80.64.0/18 → B, 10.80.96.0/19 → C and /0 → D. The /19 entry is withdrawn. Which outputs now serve 10.80.105.6 and 10.80.130.6, respectively?
  1. A and A.
  2. B and B.
  3. C and A.
  4. B and A.
Show answerHide answer

Save this lesson to see this answer.

Question 2 of 10

Input X has a head packet waiting for busy output A and a second packet for idle output B. Input Y also waits for A. Output B remains unused while the fabric can connect distinct outputs simultaneously. What change removes the input dependency that wastes B?
  1. Double output B's buffer while retaining each input FIFO.
  2. Keep separate virtual output queues at each input.
  3. Give all packets for output A strict priority over B.
  4. Increase output B's line rate while retaining each input FIFO.
Show answerHide answer

Save this lesson to see this answer.

Question 3 of 10

A destination receives two fragments with the same reassembly identity and 20-byte headers: offset 0, Total length 820, MF 1; offset 200, Total length 220, MF 0. What payload range is still missing?
  1. Bytes 800–1,599.
  2. Bytes 820–1,599.
  3. Bytes 800–1,799.
  4. Bytes 100–199.
Show answerHide answer

Save this lesson to see this answer.

Question 4 of 10

An IPv6 router receives a packet too large for its next link. Who can create IPv6 fragments in response to the resulting MTU feedback?
  1. The router itself.
  2. The next router.
  3. The source host.
  4. The receiving host.
Show answerHide answer

Save this lesson to see this answer.

Question 5 of 10

Host P sends IPv6 with Hop limit 37. Router Q enters an IPv4 tunnel, three IPv4-only routers carry it, and router R exits and forwards directly to host S. No other routers are present. What Hop limit does S receive, and whose addresses appear in the outer IPv4 header?
  1. 32; P and S.
  2. 35; Q and R.
  3. 35; P and S.
  4. 33; Q and R.
Show answerHide answer

Save this lesson to see this answer.

Question 6 of 10

DNS64 uses 64:ff9b::/96 for an IPv4-only server at 198.51.100.18. What synthesized IPv6 address represents that server?
  1. 64:ff9b::c633:6418.
  2. 64:ff9b::c651:6412.
  3. 64:ff9b::c633:1264.
  4. 64:ff9b::c633:6412.
Show answerHide answer

Save this lesson to see this answer.

Question 7 of 10

At t = 0, an OpenFlow 1.0 wildcard permit is installed with priority 300, idle timeout 12 s and hard timeout 40 s. It matches packets at 5, 14, 23 and 32 s. A wildcard drop at priority 100 matches the same traffic and never expires. Where does an otherwise matching packet go at t = 41 s?
  1. It is dropped by the surviving priority-100 entry.
  2. It follows the permit kept alive by matching traffic.
  3. It is sent to the controller as a flow-table miss.
  4. It follows the permit until its idle timeout at 44 s.
Show answerHide answer

Save this lesson to see this answer.

Question 8 of 10

An SDN firewall has two wildcard rules: source 10.11.0.0/16 → output 2 at priority 200, and all traffic → drop at priority 100. A new IPv4/TCP destination-port-22 drop has priority 150. What happens to TCP port-22 traffic from 10.11.3.8?
  1. The SSH rule drops it.
  2. The catch-all drops it.
  3. It leaves on port 2.
  4. It is a table miss.
Show answerHide answer

Save this lesson to see this answer.

Question 9 of 10

A network introduces a new link technology and a new application. Both support the existing IP service. A designer proposes one new network-layer protocol for every application/link pair. What feature of the internet architecture makes that multiplication unnecessary?
  1. Each application must understand every underlying link frame format.
  2. A middlebox translates all application data into a single transport format.
  3. The common IP waist lets upper and lower technologies change independently.
  4. An SDN controller removes the need for a network layer at the endpoints.
Show answerHide answer

Save this lesson to see this answer.

Question 10 of 10

A home router performs NAPT, and the provider performs another NAPT upstream. An inbound service has a static mapping on the home router but none at the provider. Why can a new external client still fail to reach it?
  1. The upstream translator lacks a mapping to pass the connection inward.
  2. The home rule makes the provider's public port directly reachable by itself.
  3. Static inbound mappings are required only at the translator nearest the server.
  4. Both translators must use the same private address block for inbound service.
Show answerHide answer

Save this lesson to see this answer.

Stuck on your own question? Homework Help

Key Terms

83 Key Terms, each with its definition

A

Active queue management
Active queue management drops or marks packets before a buffer fills to signal congestion and control queue growth.
A RED policy can mark eligible packets as average queue length rises before the buffer is full.

B

Best-effort service
Best-effort service is IP's delivery model, which guarantees neither delivery, timing, order, bandwidth nor security.
TCP can recover a lost segment even though the underlying best-effort IP service did not deliver it.
Black hole
A forwarding black hole is a point where traffic intended to continue along a path is dropped instead of reaching its destination.
A missing intermediate-switch permit can create a black hole despite correct entries at both ends.
Bufferbloat
Bufferbloat is excessive queuing delay caused by large standing packet queues, even when the network is successfully forwarding data.
A call can suffer long pauses when bulk traffic fills a large buffer on the shared uplink.

C

Carrier-grade NAT
Carrier-grade NAT is provider-operated translation that lets multiple customers share public IPv4 addresses upstream of their networks.
A home connection can cross its own router's NAT and then a second translator operated by the provider.
Control plane
The control plane is the logic that determines network routes and installs the information used by forwarding devices.
An SDN controller updates the control plane's choices by installing entries in several switches.
Crossbar
A crossbar is a switching interconnection that can transfer packets between different input-output pairs simultaneously.
A crossbar serves two distinct outputs at once, but two packets for the same output still compete.

D

Data plane
The data plane is the part of a network device that performs per-packet forwarding operations using installed information.
An input port makes a data-plane lookup without requesting a fresh route computation for the packet.
Datagram
A datagram is a network-layer packet consisting of an IP header and a payload that is forwarded between hosts.
A host places a TCP segment inside a datagram before sending it toward the first router.
Default gateway
A default gateway is the first-hop router a host uses to send traffic toward destinations outside its local network.
DHCP can tell a host to send nonlocal traffic through the router at 192.168.30.1.
Default route
A default route is a zero-length destination prefix used for packets without a more specific matching forwarding entry.
A datagram outside all listed specific networks can follow the IPv4 default route 0.0.0.0/0.
DHCP
The Dynamic Host Configuration Protocol (DHCP) supplies hosts with leased IPv4 addresses and related network settings over UDP.
A laptop uses DHCP to learn its address, subnet mask, default gateway and DNS server automatically.
DHCP relay
A DHCP relay passes client messages between a local subnet and a remote server, identifying the client subnet to that server.
One central DHCP server can serve several subnets when each has a relay forwarding client requests.
DNS64
DNS64 synthesizes an IPv6 destination from an IPv4 server address so an IPv6 client can send traffic through a NAT64 translator.
Using the well-known prefix, DNS64 can represent server 192.0.2.33 as 64:ff9b::c000:221.
Don't Fragment flag
The Don't Fragment (DF) flag tells IPv4 routers not to split the datagram, requiring discard if it exceeds the next-link MTU.
A source sets DF while using ICMP feedback to discover a packet size that fits the path.
DSCP
A Differentiated Services code point (DSCP) is a six-bit IP header value used to classify traffic for handling policies.
A router can read DSCP to place voice traffic in a scheduling class separate from bulk transfers.
Dual stack
Dual stack means implementing IPv4 and IPv6 together so a host or router can communicate using either protocol family.
A dual-stack client can connect to an IPv4 server or an IPv6 server using the corresponding stack.

E

ECN
Explicit Congestion Notification (ECN) lets a router mark congestion in eligible IP traffic so endpoints can respond without that drop.
An ECN mark informs the transport endpoints that load should fall even though the packet arrived.
Encapsulation
Encapsulation places a packet or segment inside another packet, adding an outer header for a distinct delivery scope.
An IPv6-over-IPv4 tunnel adds IPv4 endpoint addresses without replacing the inner IPv6 addresses.
End-around carry
An end-around carry adds a carry beyond a 16-bit checksum sum back into its low end as part of one's-complement addition.
A sum of 0x1FFFF folds to 0x0001 after the first fold creates another carry that is folded again.
End-to-end argument
The end-to-end argument places a function at endpoints when only their knowledge permits a complete, correct implementation.
A receiving application still verifies a file even when each link repairs detected frame errors.
Extension header
An IPv6 extension header carries optional network-layer information outside the fixed header and links to the following header.
A source-fragmented IPv6 packet places an 8-byte Fragment extension before its fragment data.

F

Flow label
A flow label is a 20-bit IPv6 field that marks packets belonging to a flow so devices can treat them consistently.
A load balancer can use a flow label as information for keeping related IPv6 packets on one path.
Flow priority
A flow priority is an explicitly assigned rank used to choose among matching wildcard entries, with larger values taking precedence.
A priority-300 TCP-port-22 drop overrides a matching priority-200 source-prefix permit.
Flow table
A flow table stores header matches, priorities, actions, counters and timeouts that define local packet handling.
One entry can drop SSH traffic while another forwards permitted traffic toward a destination network.
Forwarding
Forwarding is the local action of applying a table to move, drop or copy a packet arriving at one router.
A router forwards a datagram on interface 3 after matching its destination in the installed table.
Forwarding information base
A forwarding information base (FIB) is the data-plane lookup structure derived from route information for packet forwarding.
A line card holds a FIB copy so it can select outputs locally for arriving IP datagrams.
Fragment
A fragment is an IP packet containing a portion of an original payload plus its own header information for reassembly.
A large IPv4 datagram can become three fragments, each small enough for the next link's MTU.
Fragment offset
Fragment offset gives a fragment's data position in the original IP payload, measured in units of eight bytes.
An offset of 100 places the fragment's first data byte at byte 800 of the original payload.

G

Generalized forwarding
Generalized forwarding selects packet actions by matching multiple supported header fields, extending destination-only lookup.
A switch can match both source IP and TCP destination port before choosing whether to forward or drop.

H

Happy Eyeballs
Happy Eyeballs overlaps connection attempts across available addresses and families to avoid long waits on an unusable path.
A client can begin an IPv4 attempt shortly after IPv6 instead of waiting for a long IPv6 timeout.
Hard timeout
A hard timeout removes a flow entry after a fixed interval since installation, even if packets continue to match it.
A rule with a 60-second hard timeout expires at that age despite a packet matching one second earlier.
Head-of-the-line blocking
Head-of-the-line blocking occurs when a waiting front packet prevents a later packet in the same input FIFO from using a free output.
A packet for idle output B waits because the packet ahead of it needs the already busy output A.
Header checksum
The IPv4 header checksum is a one's-complement error check over the IP header that excludes the datagram's payload.
Changing TTL changes protected header bits, so the router must update the header checksum.
Hop limit
Hop limit is the IPv6 field reduced by forwarding routers to bound circulation, taking the role served by IPv4 TTL.
An IPv6 packet is discarded instead of being forwarded when its remaining Hop limit is exhausted.

I

Identification
Identification is an IPv4 field shared by fragments that, with source, destination and protocol, identifies their original datagram.
Fragments arriving out of order can still be grouped for reassembly using the shared identity.
Idle timeout
An idle timeout removes a flow entry after a configured interval without matching traffic, independently of its earlier activity.
A frequently used rule remains installed until a long enough quiet interval triggers its idle timeout.
Input port
An input port is a router component that receives incoming traffic, processes its link framing and selects an output for a packet.
The input port removes the incoming frame header before looking up the datagram's destination.
Internet Header Length
Internet Header Length (IHL) is the IPv4 field that gives the IP header length in 32-bit words, including any options.
An IHL value of 6 describes a 24-byte header, leaving less payload space in a fixed-size datagram.
IP hourglass
The IP hourglass is the architecture in which many upper-layer protocols and lower-layer technologies meet at a common IP waist.
A new link technology can support existing IP applications without separately redesigning each application.

L

Lease
A DHCP lease is a time-limited right to use an assigned address that must be extended if the host wants to keep using it.
An eight-hour lease reaches its default first-renewal point four hours after acquisition.
Load balancer
A load balancer distributes service traffic across backend servers while preserving the consistency needed by each connection.
Packets from one TCP connection stay with the backend server that holds that connection's state.
Logical centralization
Logical centralization presents one coordinated control system even when several physical servers implement that system.
Replicated controller servers can provide one logical view while improving reliability and scale.
Longest prefix matching
Longest prefix matching selects the matching destination entry with the greatest prefix length in an IP forwarding table.
If a destination matches both /16 and /24 entries, longest prefix matching selects the /24.

M

Maximum transmission unit
A maximum transmission unit (MTU) is the largest IP packet a link can carry without requiring fragmentation at the IP layer.
A 1,500-byte link MTU must accommodate the IP header as well as the payload carried with it.
Middlebox
A middlebox performs an in-path function beyond the standard job of an IP router, such as translation, filtering or caching.
A home gateway can route packets while also performing the separate middlebox functions of NAT and filtering.
More Fragments flag
The More Fragments (MF) flag indicates that additional payload follows this fragment in the original datagram.
MF is zero in the final piece even if that piece happens to arrive before the earlier fragments.

N

NAPT
Network address and port translation (NAPT) maps private address-port pairs to public pairs so hosts can share public IPv4 space.
A home router assigns different public ports to two hosts using the same private source port.
NAT64
NAT64 translates packets and maintains state between IPv6 and IPv4, allowing IPv6-only clients to reach IPv4 services.
A translator converts a client's IPv6 request to an IPv4 packet addressed to the legacy server.
Neighbor Discovery
Neighbor Discovery is an ICMPv6 mechanism for finding local routers and neighbors and resolving local link-layer addressing.
IPv6 uses Neighbor Discovery for the local address-resolution role that ARP provides in IPv4.
Network functions virtualization
Network functions virtualization (NFV) implements functions such as NAT and firewalls as software on ordinary server hardware.
An operator can run a virtualized firewall on a server instead of deploying a separate hardware appliance.
Next header
IPv6 Next header identifies the type of header immediately following the current header, either an extension or an upper layer.
A fixed header can point to a Fragment header, whose own Next header then identifies TCP.
Non-preemptive priority scheduling
Non-preemptive priority scheduling finishes the current packet, then selects from the highest-priority nonempty queue.
An urgent arrival waits for the low-priority packet already transmitting, then takes the next turn.
Northbound interface
A northbound interface connects network applications to an SDN controller so applications can request network behavior.
A traffic-management application uses a northbound API to express a policy for the controller.

O

Ossification
Ossification occurs when deployed devices depend on familiar protocol behavior in ways that obstruct new formats or functions.
A middlebox can stop a new transport from working even after both communicating hosts implement it.
Output port
An output port is a router component that buffers packets for an outgoing link, adds link framing and transmits them.
Three arrivals for one output port can leave two packets waiting while the first is transmitted.

P

Path MTU discovery
Path MTU discovery uses feedback about oversized packets to determine a size that can cross the path without IP fragmentation.
A sender reduces its packet size after an ICMP message reports a smaller outgoing-link MTU.
Payload length
IPv6 Payload length counts the bytes after the fixed 40-byte header, including extensions and the upper-layer payload.
A packet with 800 transport bytes and an 8-byte extension has Payload length 808, not 848.
Port forwarding
Port forwarding is a configured NAT mapping that directs incoming traffic at a chosen external endpoint to an internal service.
A static mapping can make an inside server reachable even before it initiates outbound traffic.
Private IPv4 address
A private IPv4 address belongs to a reusable internal-network range that is not globally routed across the public internet.
Two independent offices can both use 10.2.0.5 internally without assigning that address globally.
Protocol field
The IPv4 Protocol field identifies the type of payload carried after the IP header, such as TCP, UDP or encapsulated IPv6.
A Protocol value of 17 tells the destination to interpret the IP payload as UDP traffic.

R

Rebinding
DHCP rebinding is a broadcast attempt to extend a lease with any suitable server after renewal with the original server fails.
At the default 87.5% lease point, an unanswered client broadens its request beyond the original server.
Renewal
DHCP renewal is an attempt to extend an existing lease with the original server, normally beginning halfway through its duration.
A client first sends a unicast Request to the server that granted its current address lease.
Round robin
Round robin is a scheduler that visits class queues in turn, sending one packet from each nonempty queue per round.
If class B empties, round robin skips B and continues sending packets from the other busy classes.
Routing
Routing is the network-wide process that determines paths and supplies the route information used to build forwarding tables.
A link failure can cause routing software to compute a new path before later packets use it.
Routing processor
A routing processor is the router component that runs control and management software and supplies forwarding information.
The routing processor can distribute updated table information to the router's line cards.

S

SLAAC
Stateless address autoconfiguration (SLAAC) lets an IPv6 host form an address using a prefix learned from router advertisements.
A host can configure an IPv6 address from advertised prefix information without a DHCPv6 address lease.
Software-defined networking
Software-defined networking (SDN) separates programmable packet forwarding from external control software and network applications.
An SDN controller installs compatible rules so several switches implement one traffic policy.
Southbound interface
A southbound interface connects an SDN controller to forwarding devices for programming and control communication.
OpenFlow carries southbound instructions from the controller to the switches holding the flow tables.
STUN
STUN is a protocol that helps a host discover its NAT-assigned public endpoint for attempts at communication across translation.
A calling application can contact a STUN server to learn the public address and port seen outside.
Switching fabric
A switching fabric is the internal connection system that transfers packets from router input ports to selected output ports.
A busy switching fabric can make an input packet wait even after its output has been selected.

T

Table miss
A table miss occurs when no flow entry matches a packet; OpenFlow 1.0 sends such traffic to the controller.
A packet matching an explicit drop entry is not a table miss, because a rule did select its action.
Tail drop
Tail drop is a buffer-management policy that discards an arriving packet when the queue has no remaining storage space.
A full tail-drop queue rejects the new packet instead of making room by removing an older one.
TCAM
A ternary content-addressable memory (TCAM) is lookup hardware that compares values against entries containing fixed and wildcard bits.
A router can use TCAM to search many forwarding entries in parallel for a destination match.
Time to live
Time to live (TTL) is the IPv4 lifetime field reduced during forwarding to prevent datagrams from circulating indefinitely.
A router receiving a datagram with insufficient remaining TTL discards it and normally reports expiry.
Total length
Total length is the IPv4 header field that counts the entire IP datagram, including its header, in bytes.
A Total length of 100 with a 20-byte IP header leaves 80 bytes for the transport segment.
Translation table
A NAT translation table records the correspondence between internal and external endpoints needed to rewrite matching traffic.
A reply to the public address and port is delivered to the private endpoint recorded in the table.
Tunneling
Tunneling carries one complete packet inside another protocol's payload so it can cross a section using the outer protocol.
IPv4-only transit routers can forward a wrapped IPv6 datagram by reading the outer IPv4 destination.
TURN
TURN is a relay protocol that carries traffic through a server when direct communication across the network cannot be established.
An application can relay a call through TURN when discovering its mapping is not enough for a direct path.

V

Virtual output queue
A virtual output queue is an input-side queue dedicated to one output, separating packets that would otherwise share one FIFO.
The input can offer a packet from output B's queue while its queue for output A is blocked.

W

Weighted fair queueing
Weighted fair queueing (WFQ) accounts for packet lengths to approximate bandwidth sharing in proportion to active class weights.
Two backlogged classes weighted 3:1 receive approximately 75% and 25% of the output capacity.
Wildcard
A wildcard accepts any value for a specified match field or bit position, allowing one entry to match a group of packets.
Wildcarding the transport source port lets a rule accept clients using different ephemeral ports.

#

5-tuple
A connection's 5-tuple is its source and destination addresses, source and destination transport ports, and protocol number.
A load balancer can hash the 5-tuple to make a repeatable backend choice for each connection.

About this lesson

By StudeliReport a mistake

Make your own Study Materials

Turn your notes, slides and documents into Study Guides, Practice Questions, Flashcards and 6 more tools.

Get Started