Repository navigation
fix(data_plane): one RDMA rail finder, rails for a netdev-only UCX_NET_DEVICES - #5145
Conversation
dc44ee1 to
205c25c
Compare
|
/ok to test 205c25c |
205c25c to
1ec3425
Compare
…rror Review nit on #5145: configure_engine_env raises TransportPolicyError when UCX_NET_DEVICES names only netdevs and the host has no active RDMA rail, which is a launcher or host condition, not only the internal RDMA-only invariant the docstring described. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
…none Cleanup review of #5145. The rails list is built only when UCX_NET_DEVICES names no RDMA device, with the reason `all` is not used stated next to it; the management-port filter drops a guard that was a no-op when there is no default route; the docstring points to the design doc instead of repeating it; the test fixture no longer pretends each RDMA device owns a netdev of its own name. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
e178c54 to
ffe39c9
Compare
|
/ok to test ffe39c9 |
|
/ok to test ffe39c9 |
…VICES is only netdevs GB300 jobs get UCX_TLS=tcp UCX_NET_DEVICES=eth0 from the image. For the nixl backend, configure_engine_env dropped eth0 and deleted UCX_NET_DEVICES. init_ray() copies os.environ into the Ray runtime_env, and a deleted key is not in that copy, so every Ray worker kept eth0 and NixlStorageUnit raised TransportPolicyError at startup. Add transfer_queue_env.rdma_rails(), the one device finder for every backend: InfiniBand first, else RoCE, never mixed, minus the RDMA function of the default-route interface (eth0 -> mlx5_8 on GB300), kept only if it is the sole RDMA device. mooncake's rdma_devices() now calls it. The nixl path keeps the RDMA devices the job named, or, when it named only netdevs, sets the rails; it never deletes the variable and never falls back to "all". H100: 8 IB mlx5_* (unchanged). GB200 CI: 4 RoCE mlx5_* (unchanged). GB300: rdma_vf_rail0..3 for both mooncake_cpu and nixl. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
On images that ship HPC-X, NCCL's default net plugin
(/opt/hpcx/nccl_rdma_sharp_plugin/lib/libnccl-net.so) loads HPC-X's UCX
1.20 into every NCCL process, next to the UCX 1.21 that the nixl wheel
bundles. HPC-X's libucs loads its fuse module RTLD_GLOBAL, which makes
that libucs process-global; NIXL's bundled UCX then resolves its ucs_*
calls into it (LD_DEBUG: 983 bindings), never loads its own IB/CUDA
modules, and agent creation in the trainer workers fails with
NIXL_ERR_BACKEND ("rc, cuda_copy, cuda_ipc not available").
configure_engine_env's nixl branch now defaults UCX_MODULES=^fuse (a
launcher's value wins). It runs on the driver before init_ray and any
UCX load, and Ray hands it to every worker. NCCL keeps its plugin; only
UCX's monitoring filesystem is off. This replaces the documented
NCCL_NET_PLUGIN=none workaround, which swapped NCCL's network.
Verified on GB200, image nightly.2026-11-12, 2 nodes x 4 GPUs: NIXL
works after NCCL (0 bindings into HPC-X), NCCL still uses "NCCL RDMA
Plugin v11", processes exit cleanly (they segfaulted at exit before),
both single-controller functional tests pass with backend=nixl and no
launcher UCX/NCCL settings, and NCCL collectives at 32 MiB-1 GiB stay
within 1% with MNNVL on.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Zhiyu Li <[email protected]>
…rror Review nit on #5145: configure_engine_env raises TransportPolicyError when UCX_NET_DEVICES names only netdevs and the host has no active RDMA rail, which is a launcher or host condition, not only the internal RDMA-only invariant the docstring described. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
…none Cleanup review of #5145. The rails list is built only when UCX_NET_DEVICES names no RDMA device, with the reason `all` is not used stated next to it; the management-port filter drops a guard that was a no-op when there is no default route; the docstring points to the design doc instead of repeating it; the test fixture no longer pretends each RDMA device owns a netdev of its own name. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
ffe39c9 to
013620c
Compare
|
/ok to test 013620c |
@ZhiyuLi-Nvidia, there was an error processing your request: See the following link for more information: https://docs.gha-runners.nvidia.com/cpr/e/2/ |
|
/ok to test 013620c |
terrykong
left a comment
There was a problem hiding this comment.
Thanks for this fix. backend: nixl failed at startup on GB300, and this branch makes it start (main fails, this branch passes, in the 2-node runs in the description). Making rdma_rails() the one device finder for both backends is a good change, and splitting out the sysfs and procfs reads lets the tests run on CPU.
All five comments are about lines this PR adds or changes:
- (C1) The design doc still says the driver drops netdevs from
UCX_NET_DEVICES. Update it to say the driver now sets the rails, or stops with an error. - (C2) Tell users who set
UCX_MODULESthemselves to keep^fusein it. - (C3) Add a test that parses a real
/proc/net/routetext. - (C4) Test the "never
all" rule withUCX_NET_DEVICES=all,eth0. - (C5) Shorten two 3-line comments in
configure_engine_envto one line each.
CI: the only CI job that runs with UCX_MODULES=^fuse in place of the removed NCCL_NET_PLUGIN=none is the GB200 L1 run of L1_Functional_Tests_SingleController_3.sh. The PR already has the CI:L1 label.
The earlier approval from zyzhou5 was dismissed by a later push.
Generated by Claude Code
… doc the rail fallback Review follow-ups on the RDMA rail finder: - design doc: the driver no longer only drops netdevs from UCX_NET_DEVICES; when the job named only netdevs it sets the host's RDMA rails (without the management port) or stops with an error. - design doc: a launcher that sets UCX_MODULES itself must keep ^fuse. - test: parse a real /proc/net/route text (default route after a non-default row whose Gateway is 00000000) so a wrong-column read fails; also cover no default route and no procfs. - test: run the netdevs-only GB300 case for UCX_NET_DEVICES=all,eth0 too, so a filter that kept `all` fails. - configure_engine_env: shorten two 3-line comment blocks; the old-bug story lives in the commit history. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
|
/ok to test f2a7109 |
|
/ok to test 4070f91 |
…rror Review nit on #5145: configure_engine_env raises TransportPolicyError when UCX_NET_DEVICES names only netdevs and the host has no active RDMA rail, which is a launcher or host condition, not only the internal RDMA-only invariant the docstring described. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
…none Cleanup review of #5145. The rails list is built only when UCX_NET_DEVICES names no RDMA device, with the reason `all` is not used stated next to it; the management-port filter drops a guard that was a no-op when there is no default route; the docstring points to the design doc instead of repeating it; the test fixture no longer pretends each RDMA device owns a netdev of its own name. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Zhiyu Li <[email protected]>
What
On GB300 the image sets
UCX_TLS=tcp UCX_NET_DEVICES=eth0. Withdata_plane.backend=nixl, the real single-controller entry fails at startup:Root cause
configure_engine_env(nixl) fixesUCX_TLS, but whenUCX_NET_DEVICESnames only netdevs it deletes the variable.init_ray()copiesos.environinto the Rayruntime_env. A deleted key is not in that copy, so every Ray worker keeps the node'seth0andNixlStorageUnitrefuses to start. Earlier nixl runs passed only because their launchers exported the RDMA rails.Fix
One device finder for every backend,
transfer_queue_env.rdma_rails():rdma_devices()already had)./proc/net/route+/sys/class/infiniband/<dev>/device/net). On GB300 that ismlx5_8, the RoCE port ofeth0. Kept only if it is the sole RDMA device.rdma_devices()calls it (keeps theMC_MOONCAKE_DEVICEoverride and the uverbs gate).UCX_NET_DEVICESto the rails (<dev>:1). Never delete it, never fall back toall. No rail at all raisesTransportPolicyError.rdma_rails()mlx5_*+ 1 RoCE portmlx5_0..3mlx5_8(eth0) +rdma_vf_rail0..3rdma_vf_rail0..3(mlx5_8 dropped, for mooncake too)Tests
test_rdma_device_selection.py+nixl/test_transport_policy.py: 40 passed on thenightly-gym.2026-11-05image. New: GB300 inventory for mooncake and nixl, management port kept when it is the only device, host without rails raises.eth0,rdma_rails() == ['rdma_vf_rail0', 'rdma_vf_rail1', 'rdma_vf_rail2', 'rdma_vf_rail3'].run_grpo_single_controller.pyrecipe, 2 nodes, no UCX variables in the launcher:TransportPolicyErroratNixlStorageUnitstartUCX_TLS=rc,cuda_copy,cuda_ipc,self,sm UCX_NET_DEVICES=rdma_vf_rail0:1,rdma_vf_rail1:1,rdma_vf_rail2:1,rdma_vf_rail3:1device_name=rdma_vf_rail0,rdma_vf_rail1,rdma_vf_rail2,rdma_vf_rail3Also: HPC-X's UCX hijacks NIXL's UCX (
UCX_MODULES=^fuse)On GB200 with the
nightly.2026-11-12image,backend=nixlfailed in every trainer worker (MegatronPolicyWorker.setup_data_plane -> NIXL_ERR_BACKEND, "transports 'rc','cuda_copy','cuda_ipc' are not available"), with or without any UCX setting, on this PR and on its base.Root cause: NCCL's default net plugin (
/opt/hpcx/nccl_rdma_sharp_plugin/lib/libnccl-net.so) loads HPC-X's UCX 1.20 next to the UCX 1.21 the nixl wheel bundles. HPC-X'slibucsloads itsfusemoduleRTLD_GLOBAL(UCX debug log:loading module 'fuse' with mode 0x101), so it becomes process-global. NIXL's UCX then resolves itsucs_*calls into it (LD_DEBUG: 983 bindings), never loads its own IB/CUDA modules, and agent creation fails.Fix:
configure_engine_env(nixl branch) defaultsUCX_MODULES=^fusebefore anything loads UCX; a launcher's value wins. NCCL keeps its plugin. This replaces the doc'sNCCL_NET_PLUGIN=noneworkaround (dropped fromgrpo_dp_nixl_tq_recovery.sh).UCX_MODULES=^fuseNIXL_ERR_BACKENDucs_*bindings into HPC-X libucsgrpo_dp_single_controller+grpo_async_gym_single_controller, nixl, no launcher UCX/NCCL varsWith MNNVL off, a few small/mid-size points moved by more than 2x the run-to-run noise in a single ordered run (e.g. all_reduce 32 B-2 KiB +10 us); not yet re-measured interleaved.
🤖 Generated with Claude Code