﻿# Compare InfiniBand routes using current endpoint identities

Resolve current GUID-to-LID mappings before comparing switch forwarding snapshots with a collective regression after fabric changes.

Author: Retrivium team
Updated: 2026-11-06
Canonical URL: https://retrivium.ai/journal/ib-lid-route-change-correlation/
Language: en

## The same address can make a false comparison

A collective slows after a fabric change. An operator compares a saved forwarding entry with a current entry for the same LID and reports that the application's path moved. That conclusion assumes the destination mapping remained unchanged. InfiniBand local addresses must be interpreted with the topology generation in which they were observed. First identify the actual endpoint ports, then establish which current and historical addresses referred to them.

## Preserve identity before route entries

Record stable port GUIDs, host placement and the contemporaneous GUID-to-LID mapping for every relevant endpoint. The [OpenSM manual](https://raw.githubusercontent.com/linux-rdma/opensm/master/man/opensm.8.in) describes optional handling of a stored GUID-to-LID mapping when leaving standby, rather than a universal promise that an address remains unchanged forever. It also scopes a manager to its attached subnet. A saved LID without subnet and observation context is therefore an insufficient primary key for a route-history database.

## Understand what the forwarding query returns

The [ibroute reference](https://man7.org/linux/man-pages/man8/ibroute.8.html) describes querying a specified switch's unicast linear forwarding table or multicast forwarding table for a destination range. The result is a configuration observation at that switch, not a trace of the exact packets used by a collective. Preserve the switch identity, query range, destination resolution and local query adapter. Automatic local-port selection can otherwise inspect a different fabric from the one assigned to the affected ranks.

## Reconstruct the affected communication graph

Use the actual rank placement and communication phase to identify relevant endpoint pairs. [Port queries](https://man7.org/linux/man-pages/man3/ibv_query_port.3.html) expose local address and manager context that can support this mapping. Compare forwarding snapshots after resolving addresses to the same logical endpoint identities. Record the active routing policy and any fallback: OpenSM documents trying configured engines in sequence and potentially falling back to another engine. Requested policy is not proof of the policy that produced the observed tables.

## Establish evidence beyond correlation

Align route changes with workload timing, port-level observations, completed operation metrics and concurrent traffic. A changed table supports a topology hypothesis; it does not prove congestion or quantify application slowdown by itself. Where an authorized isolated comparison is possible, hold rank placement, operation sizes and host configuration constant. Acceptance can establish that the intended endpoints have the expected forwarding configuration and the workload meets its stated criterion. It cannot infer physical link utilization from the number of table entries.

## Keep the diagnosis reversible

Store both raw snapshots and the identity resolution used to compare them. Do not rewrite historical observations using only today's address table, or claim a rollback restored the old path because a familiar LID reappeared. The [routing study interpretation](/journal/ibm-roce-path-pinning-ecmp-collective-metric-tradeoffs/) explains why collective metrics need their own denominator, while [counter accounting](/journal/guide-net-link-counters/) avoids treating one aggregate as a route trace. The useful finding links a specific route generation to a bounded application observation and explicitly retains alternative explanations.
