Calculating Packets Interarrival Times with P4 Switches

Calculating Packets Interarrival Times with P4 Switches
Slide Note
Embed
Share

Packets' interarrival times are crucial for network analysis. Explore how P4 programmable switches enable precise computation of interarrival times using hashing techniques and custom packet processing. Dive into lab activities to understand the process and implications within network flows.

  • P4 Switches
  • Interarrival Times
  • Hashing Techniques
  • Custom Packet Processing
  • Network Analysis

Uploaded on Feb 25, 2025 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.

E N D

Presentation Transcript


  1. Workshop on P4 Programmable Switches Hands-on Session 4: Calculating Packets Interarrival Times with P4 Switches Ali AlSabeh, Jorge Crichigno College of Engineering and Computing, University of South Carolina http://ce.sc.edu/cyberinfra University of South Carolina (USC) August 29, 2023 1

  2. Calculating Packets Interarrival Times using Hashes and Registers Lab activities are described in Lab 10, P4 Programmable Data Planes: Applications, Stateful Elements, and Custom Packet Processing lab series 2

  3. Interarrival Times The interarrival time (IAT) is the time between two consecutive packets belonging to the same flow Calculating IAT is not possible on a general-purpose CPU, especially when the traffic rate is high Programmable switches offer a granular timestamp that can be leveraged to compute the IAT of packets IAT1 IAT2 IAT3 t1 t2 t3 t4 tn 3

  4. Hashing in P4 The interarrival time (IAT) is the time between two consecutive packets belonging to the same flow A flow can be identified by its 5-tuple fields: Source IP address Destination IP address Source port Destination port Protocol It is possible to hash multiple fields in P4 and get a single digest value Cyclic Redundancy Check (CRC) is an example of a hash algorithm provided by the v1model 4

  5. IAT Calculation in P4 Hash (5-tuple) Packet 5

  6. IAT Calculation in P4 Flow ID Last pkt timestamp Hash (5-tuple) Packet Index 0x1234 t1 6

  7. IAT Calculation in P4 Flow ID Last pkt timestamp Hash (5-tuple) Packet Index IAT = t2 - t1 0x1234 t1 t2 7

  8. Lab Topology and Objectives The topology consists of four hosts: h1, h2, h3 and h4; one P4 switch: s1; one legacy switch The hosts h1 and h3 send packets with a custom header (interarrival) A flow is identified by the source IP and the destination IP of the packet The P4 switch s1 computes the IAT and inserts its value into the custom header Hosts h2 and h4 receive packets from hosts h1 and h3, respectively The IATs are shown on hosts h2 and h4 interarrival Headers: IPv4 Ethernet 8

Related


More Related Content