-
Notifications
You must be signed in to change notification settings - Fork 6.2k
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
Assertion failure in GetFilter() when opening db #2717
Comments
@maysamyabandeh any quick thoughts? |
Tell me if you need any other information that might help here. |
The sst file is genuinely empty. The bug must be about dumping an empty sst file after a sudden crash. |
@maysamyabandeh This error keeps popping up from time to time even in newer RocksDB version (currently we're using 5.8.6) though I haven't found a reliable way to reproduce it. Under which condition can the SST be dumped as empty? Is there anything that can be done to simply ignore an empty SST left after a crash? |
@maysamyabandeh if the problem is coming from an empty sst file, is it possible to get around this issue, for example: skip the empty sst files? |
If having an empty SST file is a legit scenario (and not itself a symptom of another issue), yes we should skip it on restart. |
@maysamyabandeh any updates of fixing this issue? |
@sijie Do you use DeleteRange? That is one case where we may legitimately output an SST file without any data blocks and an empty filter block. |
#3614 prevents us from creating SST files with empty filters. But it'd still fail to read files with empty filters, for example, if you try to read an old DB where such files already exist. We should really fix that... |
Yes, we keep indexes for BookKeeper entries in RocksDB as individual records and then delete them with deleteRange().
Nice! Was that change already released? |
Looks like it just missed the cutoff for 5.13 so not released yet. But it's a bugfix so we should be able to backport the patch. Is backporting to 5.13 enough? |
That would be great. We can pickup any release of rocksdbjni that's available in Maven central. |
thanks @ajkr |
@ajkr Do know what's the ETA for having 5.13.1 available in Maven? The last available version is still 5.11 at this point. |
Upgrade RocksDB version to include a fix for empty SSTs written by flushing with deleteRange() operations that cause assertion failures on DB open. Description can be found at : facebook/rocksdb#2717 Author: Matteo Merli <mmerli@apache.org> Reviewers: Jia Zhai <None>, Sijie Guo <sijie@apache.org> This closes #1466 from merlimat/upgrade-rocksdb
Upgrade RocksDB version to include a fix for empty SSTs written by flushing with deleteRange() operations that cause assertion failures on DB open. Description can be found at : facebook/rocksdb#2717 Author: Matteo Merli <mmerli@apache.org> Reviewers: Jia Zhai <None>, Sijie Guo <sijie@apache.org> This closes #1466 from merlimat/upgrade-rocksdb (cherry picked from commit 7bbd3de) Signed-off-by: Sijie Guo <sijie@apache.org>
Looks like I didn't backport to 5.13. It's done now: https://github.com/facebook/rocksdb/commits/5.13.fb. Unfortunately the fix will be in 5.13.3 though. |
cc @adamretter who does our Java releases. Actually I'm a bit confused as I thought those release builds wouldn't have assertions enabled? |
@ajkr when 5.13.3 is ready let me know and I can release it. When you say "assertions enabled", I assume you mean the C++ |
@adamretter The current head of 5.13.fb should be fine to release as 5.13.3. Yes I mean failing on C++ assertion. @merlimat How is your application using RocksDB when it hits the assertion failure? Is it using the maven central version or something else? |
@ajkr Yes, we have a dependency on rocksdbjni that's coming from Maven central. |
@adamretter To disable assertions we usually set |
Thanks @ajkr! |
### Motivation Fixes #1049 . The actual fix was included in RocksDB-5.13.3 facebook/rocksdb#2717 and it's now available in Maven central. The commit that fixed the assertion for empty SSTs was at facebook/rocksdb@8d73964
@ajkr so the target we use for release builds of RocksJava is This uses the However for the Mac build the |
Summary: Closes facebook#2717 Closes facebook#4040 Differential Revision: D8592058 Pulled By: sagar0 fbshipit-source-id: d01099a1067aa32659abb0b4bed641d919a3927e
I am seeing assertion failures when opening a db that was not gracefully closed.
Db Logs prior to assert failure:
Stack trace:
Db archive where the problem reproduces: https://www.dropbox.com/sh/kyfotpyqgvbrsce/AADxlJo8OX0ZPWIiqCVfaL_Ia?dl=0&preview=locations.tar.gz
Tried with RocksDB: 5.5.5 and 5.6.1 with RocksDB-JNI from MacOS.
The text was updated successfully, but these errors were encountered: