mirror of
https://github.com/deepseek-ai/3FS.git
synced 2026-11-05 00:47:47 +00:00
[GH-ISSUE #418] [RFC] IPv6 / dual-stack support (TCP control plane + RDMA data plane) #241
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
deepseek-ai/3FS#241
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ShenHuijun on GitHub (Jul 27, 2026).
Original GitHub issue: https://github.com/deepseek-ai/3FS/issues/418
Motivation
Some RDMA fabrics are IPv6-only: high-bandwidth NICs get ULA + SLAAC IPv6
addresses and no IPv4 at all. 3FS currently cannot run on such fabrics —
Addressis IPv4-only by design, so neither the TCP control plane nor theRDMA data plane can bind or dial IPv6 endpoints.
Root cause
src/common/utils/Address.h:uint32_t ip+static_assert(sizeof(Address) == sizeof(uint64_t));operator uint64_t()is used as the hash/equality/serialization primitive;is_serde_copyablemakes RPC serialization a raw 8-byte memcpy.Fitting a 16-byte IPv6 address requires reworking this whole chain, not a
one-line patch.
What we have implemented and validated
We have a working dual-stack implementation (~19 files, +292/−87 against
current main), running for several weeks on a 2-node test deployment:
Address: 8B → 20B (16-byte address + family), IPv6 literal parsing(
TCP://[fd00::1]:8000), FNV hash + explicitoperator==, factory helpers.IfAddrs: collectAF_INET6addresses (skipping link-local).Listener: newipv6_onlyoption (default false, IPv4 deploymentsunaffected);
ConnectionPool/TcpSocketgeneralized viasockaddr_storagewith per-family branches.rdma_resolve_addrwithsockaddr_in6, dual-stack peer info in QPmetadata exchange, RoCE v2 IPv6 GID selection.
TestAddressIPv6 cases,TestEcho,TestIBSocket).Validation: full cluster (mgmtd / meta / storage / FUSE) over IPv6 for both
TCP control plane and RDMA data plane; real LLM checkpoint loads through FUSE
at multi-GB/s per NIC; unit tests pass.
The design question we want maintainer input on
We kept
is_serde_copyableand simply memcpy 20 bytes. This is the smallestchange, but it makes the wire format incompatible with existing v4 binaries:
old and new nodes cannot coexist, so no rolling upgrade. Options we see:
Addressto field-based serde for cross-version compatibility —cleaner long-term, touches RPC schema.
Which direction would you prefer? We are happy to adapt the implementation.
Proposed contribution plan
If there is interest, we would split the work into reviewable PRs:
Addressdual-stack core + unit tests;Happy to share more benchmark details or rebase onto any preferred design.