Harp: Improving VPC Network Availability via Efficient Failure Detection and Rerouting in Tencent Cloud

Jiayu Hu (Tencent), Feng Jin (Tencent), Xianping Zhou (Tencent), Kai Zhang (Fudan University), Zhen Shen (Tencent), Yongkang Luo (Tencent)

23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26) · Day 2 · When Systems Run Themselves

Overview

This detailed technical article examines Harp, a production-grade system deployed across Tencent Cloud to dramatically improve Virtual Private Cloud (VPC) network availability. Authored by a joint team from Tencent and Fudan University, the talk details how Harp addresses the critical challenge of datacenter network failures—which routinely cause packet drops, violate strict Service Level Agreements (SLAs), and disrupt enterprise-tier cloud applications. By implementing an efficient in-band failure detection mechanism combined with an Equal-Cost Multi-Path (ECMP) based path control scheme, Harp achieves sub-second failure recovery without requiring specialized hardware or modifications to tenant software.

Watch on YouTube · Slides

Visual summary for Harp: Improving VPC Network Availability via Efficient Failure Detection and Rerouting in Tencent Cloud by Jiayu Hu, Feng Jin, Xianping Zhou, Kai Zhang, Zhen Shen, Yongkang Luo
Visual summary for Harp: Improving VPC Network Availability via Efficient Failure Detection and Rerouting in Tencent Cloud by Jiayu Hu, Feng Jin, Xianping Zhou, Kai Zhang, Zhen Shen, Yongkang Luo

Key moments

  1. 0:00 Introduction and background on VPC networks and failures
  2. 2:11 Key requirements for an ideal failure recovery mechanism
  3. 4:28 System overview of Hop and its modules
  4. 7:12 ECMP-based path control and routing architecture
  5. 12:15 Inband failure detection mechanism and message workflow
  6. 15:52 Handling false positives and negatives with extended examination periods
  7. 20:23 Production performance evaluation and outage reduction results

Harp: Improving VPC Network Availability via Efficient Failure Detection and Rerouting in Tencent Cloud

Speakers: Jiayu Hu (Tencent); Feng Jin (Tencent); Xianping Zhou (Tencent); Kai Zhang (Fudan University); Zhen Shen (Tencent); Yongkang Luo (Tencent)

Conference: USENIX NSDI

YouTube: https://www.youtube.com/watch?v=vpLa_uEHa3k

Overview

This detailed technical article examines Harp, a production-grade system deployed across Tencent Cloud to dramatically improve Virtual Private Cloud (VPC) network availability. Authored by a joint team from Tencent and Fudan University, the talk details how Harp addresses the critical challenge of datacenter network failures—which routinely cause packet drops, violate strict Service Level Agreements (SLAs), and disrupt enterprise-tier cloud applications. By implementing an efficient in-band failure detection mechanism combined with an Equal-Cost Multi-Path (ECMP) based path control scheme, Harp achieves sub-second failure recovery without requiring specialized hardware or modifications to tenant software.

The system addresses a major operational bottleneck in hyperscale cloud environments: traditional physical network diagnosis tools, such as ping meshes, rely on slow localization followed by mitigation, introducing detection latencies of tens of seconds or even minutes. In contrast, Harp operates entirely within the VPC network infrastructure layer, remaining completely transparent to Virtual Machines (VMs) while executing failure detection and rerouting at millisecond intervals. Having run in production across almost all regions of Tencent Cloud for over two years, Harp has demonstrated a reduction in network outage duration by 98.71% to 99.97% compared to traditional diagnostic architectures.

Background

▶ Watch: Introduction and background on VPC networks and failures (0:00)

In public cloud environments, VPCs allow tenants to customize and isolate their network topologies. Within Tencent Cloud’s infrastructure layer, each host maintains two primary modules: the VPC agent (a control-plane module managing routing rules and configurations) and the virtual switch, which handles data-plane packet forwarding. For every packet originating from a VM, the virtual switch encapsulates an underlay header based on Virtual Extensible LAN (VXLAN), embedding a unique VPC ID. Ingress packets are processed by stripping the underlay header and routing the payload to the appropriate destination VM.

Despite this robust architecture, hardware and software failures are inevitable in large-scale datacenters. One-year telemetry data collected across Tencent Cloud reveals that roughly 94% of network failures stem from hardware switch anomalies, while the remaining 6% are caused by configuration errors such as black holes. These faults lead to severe packet drops and broken SLAs.

Designing an ideal recovery mechanism for a hyperscale cloud provider presents three strict constraints:

  1. Low failure recovery time: Real-time workloads (such as Tencent's audio/video services) classify an operation as failed if replies are delayed beyond 200 milliseconds. Traditional localization-then-mitigation approaches fail to meet this window.
  2. Legacy device compatibility: A significant portion of Tencent Cloud's infrastructure consists of legacy hardware supporting only IPv4, disqualifying IPv6-based segment routing approaches like Google's Propane.
  3. Software transparency: Cloud applications depend on diverse transport protocols, and cloud providers cannot modify tenant software, ruling out transport-layer solutions like Multipath TCP (MPTCP).

Key Findings

▶ Watch: System overview of Hop and its modules (4:28)

Harp resolves these constraints through two core innovations: an in-band failure detection engine and an ECMP-based path control framework. Deployed across Tencent Cloud for more than two years, Harp delivers several standout production results:

  • Sub-Second Recovery Latency: Across eight major real-world failure classes (including spine switch outages and core switch failures), Harp achieves a P25 recovery latency under 66 milliseconds, a P50 latency under 98 milliseconds, and a P75 latency under 207 milliseconds. Because typical TCP Retransmission Timeouts (RTO) are set to 200 milliseconds, approximately 75% of path failures are repaired within a single RTO.
  • Outage Reduction: Compared to Tencent Cloud's legacy ping mesh diagnostic approach, Harp reduces VPC network outage time by 98.71% to 99.97%.
  • Transport Reliability: Production telemetry confirms that Harp significantly reduces the equipment of TCP RTOs and drops the total number of failed TCP connection attempts across tenant workloads.

Technical Deep Dive

▶ Watch: ECMP-based path control and routing architecture (7:12)

The architecture of Harp is divided into two primary subsystems operating inside the VPC infrastructure layer: Path Control and Failure Detection.

ECMP-Based Path Control

Tencent Cloud's datacenter fabric connects each host to two leaf switches, which in turn connect to spine switches in a full-mesh topology running ECMP routing. To control end-to-end paths without specialized hardware, Harp constructs a physical path pool for each communicating host pair.

When a packet traverses the network, its five-tuple hash determines the ECMP routing choices at each hop. Harp observes that by dividing Ethernet source ports (sport) into specific port groups—where ECMP hashing yields identical next-hop choices—and calculating the set intersections of port groups across sequential hops, it can define discrete collections of paths called R-paths.

By combining the host Network Interface Card (NIC) selection for the initial link with the specific source port mapping for intermediate switches, Harp establishes an explicit, controllable end-to-end path pool (e.g., 16 distinct physical paths per host pair). When a path failure occurs, Harp updates the UDP source port in the underlay header; this modification alters the ECMP hash calculation on upstream switches, seamlessly steering affected VM traffic away from the failed link.

In-Band Failure Detection

To detect path failures without generating extraneous background traffic, Harp embeds lightweight inspection metadata directly into existing tenant VM packets. The detection workflow proceeds in three steps:

  1. Inspection Insertion: At the source host, Harp's flow mapping module assigns VM flows to physical paths. For every packet traversing a path, Harp injects an inspection message containing a Path ID and an Inspection Period (the time window pending confirmation).
  2. Destination Recording: The destination host records received Path IDs. When sending return traffic, the destination host's Harp module embeds a Reply Message that summarizes all active paths received during the evaluation window alongside a processing delay metric.
  3. Health Examination: The source host evaluates the reply message. A path is marked as faulty if it was actively utilized by outgoing flows but received no corresponding acknowledgment from the destination host within the timeout window.

To prevent false positives (misjudging a healthy path as faulty due to network congestion or delayed packets) and false negatives (failing to flag a broken path due to out-of-order packet arrival), Harp enforces an Examination Period spanning multiple detection cycles. Specifically, with a detection cycle set to 8 milliseconds, the minimum examination period is fixed at 24 milliseconds, ensuring robust path aggregation and accurate state validation.

Experimental Setup & Results

▶ Watch: Handling false positives and negatives with extended examination periods (15:52)

Harp has been validated through large-scale production deployment across almost all regions of Tencent Cloud over a two-year observation window.

  • Baselines: The primary baseline is Tencent Cloud's legacy out-of-band ping mesh diagnostic system, which relies on active probing and centralized localization. Additional comparisons evaluate standard TCP RTO behavior and connection failure rates.
  • Hardware & Scale: Deployed on standard production cloud infrastructure comprising legacy IPv4-capable network devices, top-of-rack leaf switches, spine switches, and virtualized host nodes running hypervisors with VXLAN offloading.
  • Headline Metrics:
  • Network outage duration reduced by 98.71% to 99.97%.
  • P25, P50, and P75 recovery latencies measured at <66 ms, <98 ms, and <207 ms respectively.
  • Tail latency (P95) constrained between 140 ms and 1,280 ms across severe failure scenarios such as full spine switch disconnects.

Ablation-style evaluations during development demonstrated that single-cycle detection windows yielded unacceptable false-positive rates under bursty background congestion. Expanding the examination period to span three baseline cycles (24 ms total) successfully eliminated transient jitter misclassifications while preserving sub-second recovery bounds.

Practical Implications

▶ Watch: Production performance evaluation and outage reduction results (20:23)

Harp offers vital lessons for cloud infrastructure architects, network engineers, and large-scale system deployers:

  • In-Band Telemetry Over Probing: Dedicating separate control packets for network health monitoring wastes bandwidth and introduces scalability limits. Piggybacking metadata onto existing data-plane payloads provides massive path coverage at zero extra network overhead.
  • Leveraging Existing Hardware Primitives: Complex SDN transformations or protocol upgrades (like IPv6/Segment Routing or MPTCP) are often impractical in brownfield datacenters. By strategically manipulating standard transport headers (such as UDP source ports) to steer ECMP hashes, operators can gain fine-grained path control on legacy hardware.
  • Transparency is Paramount: Systems that require modifications to guest operating systems or tenant application stacks face immense deployment friction. Infrastructure-layer solutions operating at the virtual switch boundary avoid tenant-facing disruptions entirely.

Tradeoffs and Limitations: While Harp is highly effective for datacenter VPC environments, its path-control mechanism relies heavily on predictable ECMP hashing behavior. Highly asymmetric routing topologies or non-standard hash algorithms that obscure source port variations could degrade the precision of R-path construction.

Key Takeaways

  • Production-Proven at Scale: Harp has operated reliably across Tencent Cloud regions for over two years, handling complex hardware and configuration failures transparently.
  • Zero-Overhead In-Band Detection: By embedding inspection messages directly into tenant VXLAN packets, Harp eliminates extra network overhead and enables continuous millisecond-level health checks.
  • Sub-Second Recovery: Harp achieves P25, P50, and P75 recovery times under 66 ms, 98 ms, and 207 ms respectively—outperforming traditional TCP RTO thresholds and cutting outage durations by up to 99.97%.
  • Legacy Compatibility: The system requires no specialized programmable hardware or IPv6 support, operating seamlessly on existing IPv4 infrastructure.
  • Complete Application Transparency: Operating entirely within the VPC network infrastructure layer, Harp requires no modifications to virtual machines, guest operating systems, or tenant software.

About the Speaker(s)

The research and engineering work was presented by representatives from Tencent Cloud and Fudan University, highlighting a successful industry-academia collaboration. Jiayu Hu delivered the conference talk on behalf of the engineering team, which includes researchers and systems architects specializing in cloud networking, hyperscale VPC infrastructure, and data-plane reliability at Tencent, alongside academic partners from Fudan University.

Reviews

  • Simon Wisk (Open Source Developer & AI Tooling Expert) — MUST SEE ★★★★★

→ Top-rated talks at 23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26)

All talks from 23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26)