-
Notifications
You must be signed in to change notification settings - Fork 167
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
Tikv crash in compaction filter casued by IoError: No Such file or directory: While open a file for random read: /data/xxx/yyy/zzz/115748.blob #328
Comments
Status BlobStorage::Get(const ReadOptions& options, const BlobIndex& index,
BlobRecord* record, PinnableSlice* buffer) {
auto sfile = FindFile(index.file_number).lock();
if (!sfile)
return Status::Corruption("Missing blob file: " +
std::to_string(index.file_number));
// NOTE-1: the purge obselete file thread can delete the file in this time, and the next line will report the error
return file_cache_->Get(options, sfile->file_number(), sfile->file_size(),
index.blob_handle, record, buffer);
} |
I have checked the code here and there is indeed a race condition present |
@v01dstar Hello, can you help confirm |
At first glance, seems possible, allow me dig more. |
I think this is indeed a problem, unless we set |
I guess that in the TIDB environment, Tikv only uses Compaction Filter in WriteCF, while WriteCF only saves some transaction commit information and small values less than 256 bytes. Moreover, by default, WriteCF does not enable Titan, so it will not occur. |
Yes, I totally missed that. I guess, you can leverate |
i try |
This error is different with the existing older Missing blob.
The text was updated successfully, but these errors were encountered: