[Bugfix] Align NoF allocation offsets to the namespace block size - #4024
Open
cage-goat wants to merge 2 commits into
Open
[Bugfix] Align NoF allocation offsets to the namespace block size#4024cage-goat wants to merge 2 commits into
cage-goat wants to merge 2 commits into
Conversation
Pass block_size through the Python/C++ registration APIs and NoFSegment RPC serialization. Reject block sizes below 512 bytes or not powers of two, and update NoF fixtures and validation tests. Signed-off-by: Cage Chen <cage@arcfra.com>
NoF allocations could start at offsets that were not aligned to the namespace block size, causing I/O submission to fail. Use the namespace block size as the minimum allocation unit. Reject segment bases and sizes that are not block-aligned. Signed-off-by: Cage Chen <cage@arcfra.com>
cage-goat
requested review from
00fish0,
Aionw,
Icedcoco,
Libotry,
ShangmingCai,
XucSh,
YiXR,
stmatengss,
ykwd and
zxpdemonio
as code owners
September 11, 2026 04:02
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #4021
NoF allocations could return offsets that were not aligned to the namespace block size, causing the client to reject I/O during alignment checks.
This PR addresses the problem in two commits:
block_sizefrom the existing bdev query, or accept an explicit value through the C++/Python registration APIsNoF block sizes must be powers of two and at least 512 bytes. The registration APIs now require
block_size, and theNoFSegmentRPC schema changes. Masters and clients exchanging this type must be upgraded together.Module
mooncake-transfer-engine)mooncake-store)mooncake-reshard)mooncake-ep)mooncake-pg)mooncake-integration)mooncake-p2p-store)mooncake-wheel)mooncake-common)mooncake-rl)Type of Change
Test results:
Checklist
./scripts/code_format.shAI Assistance Disclosure
Codex assisted with analysis, implementation, tests, and build verification.