Repository navigation
Description
Is there an existing issue for the same bug?
- I searched existing issues. Related flaky-test reports include [Bug]: UT TestSpeedupAbortAllTxn times out after logtail reconnect #26008, [Bug]: TestDataBranchDiffAsFile panics in RunBaseClusterTests cleanup #25929, and cnservice bootstrap panics on context.Canceled instead of returning error #24064, but none tracks the common cross-filesystem LocalFS failure in this run.
Branch Name
4.2-dev (observed in PR #26252)
Commit ID
PR head: f7d6d015b206db38039d4a7b334a066f36e3d868
Base: 46dfc97cf284c51ce12095aa75618b1ef0410453
Other Environment Information
- GitHub Actions runner:
amd64-mo-shanghai-8c16g-92mgx-runner-r2wr2 - Workflow/job: https://github.com/matrixorigin/matrixone/actions/runs/30263178108/job/89967635780
- The CI setup redirects
/tmp/runner-ut-workspaceto/mnt/runner-ut-workspace.
Actual Behavior
The Ubuntu/x86 UT job failed five unrelated embedded-cluster tests:
TestSpeedupAbortAllTxnTestPreparedParamsTestInsertAndDeleteHashBasedWithAccountTestDataBranchDiffAsFileTest_UpgradeEntry
Before the timeouts and CN bootstrap panics, transfer-page persistence repeatedly failed with:
rename /tmp/.tmp.<id> transfer/<page>: invalid cross-device link
[TransferPage] write transfer page failed after 3 retries
The failures then surfaced as context deadline exceeded, txn commit status is unknown, and CN bootstrap panics across five independent packages.
This is not introduced by PR #26252:
- The PR does not change
pkg/fileservice,pkg/vm/engine/tae/model/pages.go, or any of the five failed test packages. - On the base commit,
pkg/fileservice/local_fs.goalready creates the temporary file underLocalFS.rootPathand finishes with a directos.Rename(f.Name(), nativePath). - If the temporary file and destination resolve to different filesystems, Linux returns
EXDEV; retrying the same rename cannot succeed.
Expected Behavior
LocalFS atomic writes used by transfer pages should keep the temporary file on the destination filesystem, or handle EXDEV safely, so CI workspace placement cannot make unrelated UT packages fail.
Steps to Reproduce
- Arrange the LocalFS temporary root and destination directory on different filesystems (matching the CI
/tmp//mntlayout). - Run an embedded-cluster test that persists transfer pages.
- Observe
os.Renamereturninvalid cross-device link. - Observe transfer-page retries exhaust and dependent cluster tests time out.
Additional information
The failed job's summary was:
FAIL_UT_CASES=TestSpeedupAbortAllTxn,TestPreparedParams,TestInsertAndDeleteHashBasedWithAccount,TestDataBranchDiffAsFile,Test_UpgradeEntry,
Potential fix direction: create the temporary file in the final destination directory before fsync + rename, preserving same-filesystem atomic rename semantics.
Activity
jiangxinmeng1 commentedon Jul 28, 2026
Fix pushed in PR #26252, commit
8f585a4539. LocalFS now creates temporary files on the destination filesystem whenrootPathis empty, covering bothWriteandNewWriter. A regression test uses/tmpand/dev/shmto verify cross-filesystem layouts.fix: bound memory during parallel vector load (#26252)
VioletQwQ-0 commentedon Aug 5, 2026
This issue is reproducible on the current repository branches and should be reopened.
PR #26658, while based on
main, emitted the same LocalFS cross-filesystemrename failure in both Ubuntu UT modes:
5a32e6bf3bf6df21ff4074af52cdcc756aad1646Observed repeatedly in the raw job logs:
During #26658 triage, a separate auto-increment clone-epoch regression was also
identified and fixed. That separate PR bug does not explain or remove these
LocalFS
EXDEVrecords: the filesystem failure is the same portability defecttracked here and occurs in code unrelated to #26658's feature changes.
The previous fix commit is:
It was submitted as part of #26252, whose target branch was
4.2-dev.However, as of August 5, 2026, neither current branch tip contains that commit
or its behavior:
main:4dbb502e0efc3fdcf48869938c0acc53eff5f8904.2-dev:fa6c57cbfaba17d705ebc673bd49c06bf156e4d5Both current versions of
pkg/fileservice/local_fs.gostill create temporaryfiles with
os.CreateTemp(l.rootPath, ".tmp.*")and then rename them to thetarget path. When
rootPathis empty and the relative destination is on adifferent filesystem, the final rename can still fail with
EXDEV.Expected resolution:
mainin a focused PR linked to [Bug]: LocalFS transfer-page writes fail with EXDEV in Ubuntu UT workspace #26272.8f585a45.including the current
4.2-devtip.Existing-issue search found no separate issue that should supersede this one.
#26008 contains an occurrence of the same transfer-page error, but its primary
tracker was a logtail reconnect timeout and its comments already route the
LocalFS common cause to #26272.
test: stabilize morpc filter and logservice retry cases (#27302)
test: stabilize morpc filter and logservice retry cases (matrixorigin…
test: stabilize morpc filter and logservice retry cases (matrixorigin…
test: stabilize morpc filter and logservice retry cases (matrixorigin…