Writing Fine-grained Measurements App with P4 Programmable Switches

 

       

 

 

Writing Fine-grained Measurements Apps with P4 Programmable Data Plane Switches

 

Monday, September 18 - 8:00 AM - 11:30 AM

Minneapolis, MN.

Organizers
  • University of South Carolina
  • Energy Sciences Network (ESnet)
  • The Engagement and Performance Operations Center (EPOC)

 

 

Overview

Data plane programmability with P4 has recently attracted significant attention from both the research community and the industry, permitting network engineers to run customized packet processing functions in the data plane. One of the main features of P4 switches is the real-time visibility in the data plane. This feature enables users to develop new applications that use precise measurements (up to nanosecond resolution) for performance improvements, cybersecurity, troubleshooting, per-packet analysis, and more. his tutorial will provide Information Technology (IT) professionals and practitioners (network engineers, students, instructors) with an introduction to P4 programmable switches, followed by applications that produce and use precise network measurements. The tutorial will cover first the fundamentals of programmable switches: P4 building blocks, parser implementation, and match-action tables. Then, the tutorial will continue with network measurements and applications: monitoring the switch’s queue using standard metadata; measuring flow statistics using direct and indirect counters; measuring flow RTT, packet loss, and throughput; identifying TCP congestion control type using packet inter-arrival time; and other applications.

 

Audience

IT educators, practitioners, and professionals in general (network engineers, system administrators, etc.) with basic background in networking.

 

Required Equipment

No specialized equipment is required. All material will be accessible via web browsing. Presentations will be conducted via Zoom. For hands-on sessions, attendees will access a virtual platform deployed for the workshop.

 

Outcomes

By the end of this workshop, attendees will:

  • Describe the elements of the Protocol Independent Switch Architecture (PISA)
  • Define protocol headers and header fields in P4
  • Write simple parsers using P4
  • Define match-action tables
  • Populate and manage match-action tables at runtime
  • Leverage stateful elements (registers) to store arbitrary data in the data plane
  • Monitor queue occupancy and packets interarrival times with high granularity
  • Computing and extracting fine-grained measurements using P4

 

Agenda

 
Monday, September 18
Time Topic Presenter
8:00-8:25

Overview of P4 and programmable data plane switches [PDF, PPT]

Introduction to packet parsing [PDF, PPT]

Jorge Crichigno [Bio]
08:25 - 09:00 Hands-on Session 1: Intro to P4 and BMv2, writing a parser, and compiling P4 code [PDF, PPT] Elie Kfoury [Bio]
09:00 - 09:15 Break  
09:15 - 09:30 Buffers and queues [PDF, PPT] Jorge Crichigno
09:30 - 10:15 Hands-on session 2: monitoring queue occupancy on a per-packet basis [PDF, PPT] Elie Kfoury
10:15 - 10:30 Break  
10:30 - 11:00 Hands-on session 2 (continuation): monitoring queue occupancy on a per-packet basis [PDF, PPT] Elie Kfoury
11:00 - 11:30 Discussions, applications with P4 switches, Tofino pods [PDFPPT, Video]  
[Survey]

 

Award Information

This activity is supported by NSF award 2118311. Link to official webpage: NSF-2118311

 

Resources

 

Item Note
VM for P4 Labs: Link VM containing lab exercises
Cybertraining Material: Link List of virtual labs on P4, SDN, network tools and protocols, ...
P4 Campus: Link P4 applications for campus networks
FABRIC: Link A programmable research infrastructure
Behavioral Model version 2 (BMv2): Link Reference P4 software switch used as a tool for developing, testing and debugging P4 data planes
Software-Defined Networks: A Systems Approach: Link A book that explores the key principles of Software-Defined Networking (SDN)
Mininet: Link Virtual testbed enabling the development and testing of network tools and protocols
Containernet: Link Mininet fork that allows to use Docker containers as hosts in emulated networks
Mininet Installation: Link A guide that describes the steps to install Mininet on Linux
Wireshark: Link Packet analyzer used for network troubleshooting, analysis, protocol development, and education