Skewed Network Latencies on GCP — an Explainer

The folks at Azure are using FPGAs to accelerate network performance (and decrease host-CPU utilization) in their public cloud. There’s a nifty paper about this that was presented at NSDI ’18 (•). It’s worth reading (as is the writeup by Adrian Colyer), but the following graphs, showing the network performance of Azure vs GCP vs AWS, really caught my eye.
/via https://bit.ly/2HGZtBT
 Ignore the Azure bars (ok, don’t ignore them, they’re pretty nifty, but they’re not the focus here). Notice how GCP’s VM-VM latencies are better than AWS’, but the tail latencies are much worse?
Turns out there is a reason for this, and it’s embedded in the way GCP does networking, and specifically in the way their Andromeda network virtualization stack works.
/via https://bit.ly/2HGZtBT
You can ignore most of the stuff in the stack (shown above), except for the “Hoverboard”, which is, in effect a sidecar that is used to process any traffic flows that a VM doesn’t know anything about. The Hoverboard then proceeds to deal with these flows, up to a certain threshold, after which it basically offloads the flow back to the VM, and sets up a direct VM to VM connection for the traffic in that flow.
To put this differently, it goes something as follows
  1. 1. VM sees packet for a target it doesn’t know anything about
  2. 2. VM forwards packet to Hoverboard, and sez. “you deal with this”
  3. 3. Hoverboard processes the packet, and subsequent packets, until the traffic gets to a point where it could do with optimization
  4. 4. Hoverboard tells the VM to set up a direct connection to the target, and all subsequent packets go directly VM-VM
/via https://bit.ly/2HGZtBT
As a result, the hoverboard only deals with setup packets, and any traffic that is below thresholds. Everything else goes directly between the VMs, as shown above
In short, most traffic has low latency (VM-VM), while setup/infrequent packets have high latency (VM-Hoverboard-VM)
It’s a pretty nifty solution! If you’d like to know more about this, check out the NSDI ’18 paper on Andromeda (••), and/or this summary by (who else) Adrian Colyer.

Comments

Popular posts from this blog

Erlang, Binaries, and Garbage Collection (Sigh)

Spot The Difference — Deep Learning Edition