-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
Disable WAL write error injection when reopen with WAL #12820
Conversation
@hx235 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
tools/db_crashtest.py
Outdated
@@ -891,6 +893,16 @@ def finalize_and_sanitize(src_params): | |||
dest_params["prefixpercent"] = 0 | |||
dest_params["check_multiget_consistency"] = 0 | |||
dest_params["check_multiget_entity_consistency"] = 0 | |||
if dest_params.get("disable_wal") == 1 and dest_params.get("reopen") > 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
disable_wal == 0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
70d6476
to
0b53de0
Compare
@hx235 has updated the pull request. You must reimport the pull request before landing. |
@hx235 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one quick comment. Approving to unblock. Thanks!
Context/Summary:
Right now we need to persist WAL data before closing for reopen when
reopen > 0
anddisable_wal = false
https://github.com/facebook/rocksdb/blame/71f9e6b5b36e3223e8dba29df75e4e5008818d16/db_stress_tool/db_stress_test_base.cc#L3479. Previous injected WAL write errors may not be cleared by the time of closing and ready or persisting WAL. To simplify, we disable any WAL write error injection whenreopen > 0
anddisable_wal = false
Test:
Below command failed
Error persisting WAL data which is needed before reopening the DB: IO error: Writer has previous injected error.
with but passes after we disable WAL write error injection (exclude_wal_from_write_fault_injection=1, metadata_write_fault_one_in=0)