1 of 24

RDMA over Commodity Ethernet at Scale

Chuanxiong Guo, Haitao Wu, Zhong Deng, Gaurav Soni, Jianxi Ye, Jitendra Padhye, Marina Lipshteyn

Presented by Matthew Sickler

2 of 24

The Problem

TCP/IP, the prevalent transport/network stack in data center networks, was increasingly unable to keep up with DC workload demands:

  • Despite HW and SW optimizations, the CPU overhead of handling packets in the kernel was becoming unreasonably high.
  • TCP could not provide the low latency required by many modern DC applications, even under moderate workload:
    • Kernel software could introduce up to tens of milliseconds of latency.
    • Moreover, bursty DC workloads occasionally cause packet drops due to congestion, and TCP’s recovery from packet drops, either with timeouts or fast retransmissions, leads to latency.

�To address these shortcomings… RDMA over Commodity Ethernet (RoCEv2)

3 of 24

Background: RDMA (Remote Direct Memory Access)

RDMA is “a method of accessing memory on a remote system without interrupting the processing of the CPU(s) on that system.”

​

RDMA-accessible virtual memory must first be registered with the NIC, which involves pinning the corresponding physical pages in memory and providing the NIC with the virtual address translations.

  • The NIC may cache these mappings in its on-chip memory, but on a cache miss, it must retrieve the required translations from server memory.

​

RoCEv2 was designed with a lossless network requirement, meaning switches would not overflow and drop packets.

4 of 24

Background: PFC

RoCEv2 uses PFC (Priority-based Flow Control) to provide this lossless network.��PFC works hop-by-hop between Ethernet nodes:

  • When a receiver’s ingress queue reaches the XOFF threshold, it sends a pause frame to the upstream sender’s corresponding egress queue.
  • Transmission is stopped until the ingress queue drops beneath the XON threshold.

​

Because these pauses must propagate hop-by-hop to the source of the congestion, other flows may be unfairly blocked.

  • Queues are divided by priority classes to help avoid head-of-line blocking.
    • Only two lossless priority classes were supported due to the distance of some hops.

5 of 24

Background: DCQCN

PFC pauses can lead to unfairness.

​

To reduce their frequency, RoCEv2 also uses per-flow DCQCN (Data Center Quantized Congestion Notification).

  • A congested switch marks packets with a congestion notification.
  • Upon seeing this, the receiving NIC notifies the sending NIC to adjust appropriately.

​

DCQCN does not guarantee a lossless network.

6 of 24

Discussion Questions

Does application-side logic stay the same, or do newer issues arise with using RDMA?

  • Kshitij Kapoor

​

Would small requests and large transfers benefit equally from PFC, or could the delays from pausing traffic sometimes be worse than retransmitting lost packets?

  • Diego Wearden

7 of 24

VLAN-based PFC

Traditional VLAN-based PFC carries the packet priority in the VLAN tag, but:

  • Server-facing switch ports would have to be placed in trunk mode to support VLAN tagged packets
    • This was incompatible with their OS provisioning system, as systems in PXE boot cannot send or receive packets with VLAN tags.
  • There is also no standard way to preserve VLAN information at the Layer-3 level, which started at their ToR switches.

8 of 24

DSCP-based PFC

…so they moved the packet priority to the IP header DSCP field.

9 of 24

Challenge: RDMA Transport Livelock

RDMA transport protocol assumes packets are not dropped due to congestion, but occasional drops can still occur, for instance due to bugs in switch SW and HW.

�Initially, the NICs used a retransmission scheme of go-back-0, restarting at the first packet, because it was stateless and easy to implement.

  • However, with a high enough loss rate, a connection might never make progress.

​

Their solution was to use a go-back-N retransmission scheme, which instead restarts at the first dropped packet, as this was still simple enough to implement in the NICs.

10 of 24

Challenge: PFC Deadlock

Deadlock was initially assumed impossible in a Clos network topology with up-down routing. Packets first travel up to a common ancestor then go down the path to the destination, so there should be no cyclic buffer dependency.

  • Nonetheless, PFC deadlock was found during a test cluster stress test.�

Recall that for a ToR switch to send an IP packet to a server, it must check two tables:

  • ARP table: for destination MAC address
  • MAC table: for associated physical port

�ARP table timeouts are more expensive, as they are handled by the switch CPU, so the timeout value for ARP table entries is much greater than MAC table entries. This can lead to “incomplete” ARP entries, which lack an associated MAC table entry.

11 of 24

Challenge: PFC Deadlock

Upon an “incomplete” ARP entry (without an associated MAC table entry), the standard behavior is to flood the packet to all ports, but this can create a cyclic buffer dependency…

​

Possible solutions for handling “incomplete” ARP entry packets, instead of flooding:

  • Sending to switch CPU
    • Increases CPU overhead
  • Converging ARP and MAC table timeout values:
    • Adds CPU overhead (ARP lowered to MAC)
    • Increases the time to detect when a server is disconnected from the switch (MAC increased to ARP)
  • Drop “incomplete” ARP entry packets

12 of 24

Challenge: NIC PFC Pause Frame Storms

PFC can cause collateral damage to innocent flows due to head-of-line blocking.

​

In the worst-case scenario, a single malfunctioning NIC continually sends pause frames to its ToR switch.

  • This could be caused by a bug in the NIC’s receiving pipeline stopping it from being able to handle the packets it receives.

This sets off a chain reaction, blocking the whole network.

  • This phenomenon is called a NIC PFC pause frame storm.

13 of 24

Challenge: NIC PFC Pause Frame Storms

Their solution was two complementary and individually sufficient watchdogs:

  • NIC watchdog:
    • If the receiving pipeline has been stopped for a period of time and pauses are actively being generated, disable pause frame generation.
  • ToR watchdog:
    • If a server-facing port is queuing packets that cannot be drained and that port is receiving continuous pauses, disable the lossless mode for the port.
    • Once the pause frames disappear for a period of time, the port is made lossless again.

14 of 24

Challenge: Slow Receiver Symptom

The authors thought the server NIC would not generate pause frames because the PCIe bandwidth to memory was greater than the NIC throughput. However, they still found receiving bottlenecks forming at the NIC.

  • The NIC has limited memory resources, so it stores most of the data structures in server memory. This included virtual address translations for RDMA operations. On a cache miss, it would have to access main memory for the translation first, slowing down the processing pipeline.

​

Their solution in the NIC was to increase the page size, so the translation cache miss rate would lessen.��Moreover, they implemented dynamic buffer sharing in the switch, allow its queues to absorb more traffic before propagating the pause frames further in the network.

​

​

15 of 24

Discussion Question

Could a centralized, SDN-like architecture better solve these safety challenges? (For instance, could an SDN controller inspecting and managing PFC frames improve PFC storm handling? Could an SDN controller instead maintain ARP and MAC table entries to avoid packet drops?)

  • Shazer Ali

​

​

​

​

16 of 24

Management and Monitoring Capabilities

Configuration management and monitoring

  • Verifies configurations of switches and servers match desired configurations.
  • Handles complexities introduced by different vendors, versions, and customer requirements.

PFC pause frame and traffic monitoring

  • Collects pause frame counts and intervals to understand network congestion.
  • RDMA traffic counters reveal traffic patterns and trends, while drop counters detect if anything is going wrong with the lossless network.

RDMA Pingmesh

  • Active RDMA probes measure end-to-end RTT between servers to detect RDMA performance issues.

17 of 24

Latency Reduction

RoCEv2 shows a significant end-to-end tail latency reduction over TCP in production environments. In one highly-reliable, latency-sensitive service, RDMA’s 99th and 99.9th percentiles were 90us and 200us, while TCP’s 99th was 700us.

  • During this experiment, the network was not the bottleneck, but the traffic was bursty with the many-to-one incast traffic pattern.
  • TCP’s overhead was caused by kernel stack overhead and occasional incast packet drops.

18 of 24

High Throughput

RoCEv2 was also shown to utilize the available network bandwidth without becoming a bottleneck.

  • The experiment generated ToR-to-ToR traffic between two podsets, using 8 servers in each ToR.

Aggregate throughput reached 60% utilization of network capacity, a limitation consistent with ECMP routing hash collisions rather than one from RoCEv2.

19 of 24

High Throughput Degrades Latency

RoCEv2's low tail latency benefits worsen under high throughput. During another throughput experiment, RDMA tail latency jumped significantly, as queues became congested and pause frames were created.

20 of 24

Discussion Questions

How much of the latency benefit comes from kernel bypass, loss prevention, or congestion control?

  • Aananth Venkatesh

​

What do modern RDMA protocols use instead of ECMP in order to maximize throughput?

  • Aananth Venkatesh�

21 of 24

Deployment and Incidents

Deployment was completed incrementally, beginning with a small lab network followed by test clusters. It was then introduced to production networks in stages: first at ToR level, then at the Podset level, and finally throughout the Spine switches.

  • Lab network: RDMA transport livelock, various bugs
  • Test clusters: PFC deadlock, slow-receiver symptom

​

A few incidents did hit their production networks:

  • NIC PFC storms
  • Switch buffer misconfiguration
    • New type of ToR switch was accidentally configured to allow much less dynamic buffer sharing
    • 2 ToR switches became inundated with incast traffic and had to generate pauses

22 of 24

Prior Work

There had been attempts to improve TCP latency within its existing framework, for example by tuning the retransmission timer. RoCEv2 instead tries a different approach, bypassing the OS kernel and avoiding packet drops entirely.�

Two other RDMA technologies:

  • Infiniband: Developed a complete networking protocol suite, requiring the use of Infiniband routers and switches. There were no known Infiniband routers in production, and it wasn’t compatible with existing Ethernet infrastructure.
  • iWarp: Runs RDMA on top of the TCP/IP protocol suite, offloaded to the NIC. Unlike RoCEv2, it can be used for inter-DC communication and doesn’t require a lossless network. However, since it uses TCP for packet retransmission, it encounters many of the same performance issues.

​

23 of 24

Future Work: Lossless Network Assumption

The reliance on a lossless network (and the use of PFC) led to many safety challenges and several incidents on production networks. Future work that weakens this assumption, using programmable hardware for instance, will likely be able to avoid many of these issues.

​

PFC is limited by hop distance and the associated propagation delay, making it infeasible for inter-DC communications. Other solutions are needed for more generic use cases.

24 of 24

Discussion Questions

How could RoCEv2 be extended for inter-DCN communications? Has this been implemented in the past few years?

  • Allison Tseng

​

What other strategies could be used to ensure a lossless network besides PFC? What might their tradeoffs look like?

  • Nathan Tran

​

Given the complexity and risks of maintaining a lossless network with mechanisms like PFC, are the performance benefits of lossless RDMA worth it? Has recent progress in programmable hardware made it feasible to weaken or remove that requirement?

  • Jyotsna Arunkumar, Sanjana Vishwanath, Kshitij Kapoor, Ximena Salazar, Kipling Liu