Skip to content

Commit 7af1fe6

Browse files
committed
Fix zone-to-zone (XDE test, kbench local) runner
During setup, we are not doing any work to ensure that Helios has a valid NDP cache entry ready to use over the simnet link we install for testing. As a result, XDE selects the right output port, but installs source and destination MAC addrs of zero. This worked before; the devices were in promiscuous mode, so the packets made into `xde_rx`. In other cases, the underlay traffic in e.g. a SoftNPU deployment was priming all the necessary NCEs, so we always knew the target MAC address. Obviously this is an easy fix here, but we also need to ensure that all sleds have valid NDP entries for one another at all times.
1 parent 42c1506 commit 7af1fe6

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

xde-tests/src/lib.rs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
// Copyright 2024 Oxide Computer Company
66

7+
use anyhow::Context;
78
use anyhow::Result;
89
use opteadm::OpteAdm;
910
use oxide_vpc::api::AddRouterEntryReq;
@@ -349,6 +350,27 @@ pub fn two_node_topology() -> Result<Topology> {
349350
println!("setup zone b");
350351
b.setup(&vopte1.name, opte1.ip())?;
351352

353+
// We now need to establish an NDP cache entry both ways, otherwise
354+
// we'll write zero for both MAC addrs and the packet *will* be dropped --
355+
// we're not in promisc anymore :). One ping from the global zone will suffice.
356+
let ping_res = Command::new("ping")
357+
.args([
358+
"-A",
359+
"inet6",
360+
"-i",
361+
&sim.end_b,
362+
&format!("{}%{}", ll0.ip, sim.end_a),
363+
])
364+
.output()
365+
.with_context(|| "calling 'ping' over simnet")?;
366+
367+
if !ping_res.status.success() {
368+
anyhow::bail!(
369+
"Failed to ping over simnet links!\nstderr:{:?}",
370+
std::str::from_utf8(&ping_res.stderr)
371+
);
372+
}
373+
352374
Ok(Topology {
353375
xde,
354376
lls: vec![ll0, ll1],

0 commit comments

Comments
 (0)