Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] SegmentReplicationIT.testSendCorruptBytesToReplica fails with specific seed #10542

Closed
andrross opened this issue Oct 10, 2023 · 1 comment · Fixed by #10897
Closed

[BUG] SegmentReplicationIT.testSendCorruptBytesToReplica fails with specific seed #10542

andrross opened this issue Oct 10, 2023 · 1 comment · Fixed by #10897
Assignees
Labels
bug Something isn't working flaky-test Random test failure that succeeds on second run Indexing:Replication Issues and PRs related to core replication framework eg segrep >test-failure Test failure from CI, local build, etc.

Comments

@andrross
Copy link
Member

Deterministic failure in my testing:

./gradlew ':server:internalClusterTest' --tests "org.opensearch.indices.replication.SegmentReplicationIT.testSendCorruptBytesToReplica" -Dtests.seed=FAEFCA804F148BCB

#10519 (comment)

@mch2
Copy link
Member

mch2 commented Oct 16, 2023

In the trace I can see this is happening with WindowsFS - sending corrupt bytes must cause a lingering file handle before renaming the tmp file. I think we can safely move this to a separate class and skip on windowsfs?

Caused by: java.io.IOException: access denied: /private/var/folders/c0/63hvxjzj32j_zjnrs_b5kqg80000gs/T/org.opensearch.indices.replication.SegmentReplicationIT_FAEFCA804F148BCB-003/tempDir-002/node_t2/nodes/0/indices/u9yNYNnKTiWwFfdeyzTENg/0/index/replication.pOict48kT-qrZjYHz9H2GQ._0.si
	at org.apache.lucene.tests.mockfile.WindowsFS.checkDeleteAccess(WindowsFS.java:116) ~[lucene-test-framework-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at org.apache.lucene.tests.mockfile.WindowsFS.move(WindowsFS.java:133) ~[lucene-test-framework-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at java.nio.file.Files.move(Files.java:1430) ~[?:?]
	at org.apache.lucene.store.FSDirectory.rename(FSDirectory.java:272) ~[lucene-core-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at org.apache.lucene.tests.store.MockDirectoryWrapper.rename(MockDirectoryWrapper.java:246) ~[lucene-test-framework-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at org.apache.lucene.store.FilterDirectory.rename(FilterDirectory.java:91) ~[lucene-core-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at org.apache.lucene.store.FilterDirectory.rename(FilterDirectory.java:91) ~[lucene-core-9.8.0.jar:9.8.0 d914b3722bd5b8ef31ccf7e8ddc638a87fd648db - 2023-09-21 21:57:47]
	at org.opensearch.index.store.Store.renameTempFilesSafe(Store.java:470) ~[classes/:?]
	at org.opensearch.indices.recovery.MultiFileWriter.renameAllTempFiles(MultiFileWriter.java:206) ~[classes/:?]
	at org.opensearch.indices.replication.SegmentReplicationTarget.finalizeReplication(SegmentReplicationTarget.java:254) ~[classes/:?]
	at org.opensearch.indices.replication.SegmentReplicationTarget.lambda$startReplication$3(SegmentReplicationTarget.java:177) ~[classes/:?]
	at org.opensearch.core.action.ActionListener$1.onResponse(ActionListener.java:82) ~[classes/:?]
	... 23 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working flaky-test Random test failure that succeeds on second run Indexing:Replication Issues and PRs related to core replication framework eg segrep >test-failure Test failure from CI, local build, etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants