-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
compact: failure on empty block #869
Comments
I've looked up the blocks from the log in S3 and none of them have any chunks, just small (~400B) meta.json and (~150KB) index files. |
I purged all the empty blocks in my S3 bucket (after backing them up in case they would be useful) and now compact is happy again. |
Yeah we had to create a script to remove all empty blocks from the bucket, it worked after that, I mean another issue popped up |
Closing as this should be fixed by #904. Please shout if I am wrong :) |
Thanos, Prometheus and Golang version used
improbable/thanos:v0.3.1
quay.io/prometheus/prometheus:v2.7.1
What happened
Thanos compact is crash looping.
What you expected to happen
Compaction completes successfully.
How to reproduce it (as minimally and precisely as possible):
I'm not sure how the state of blocks in S3 was produced, but I think I understand what is happening.
Given a set of empty blocks to compact, tsdb's LeveledCompactor is resulting in an empty block: it marks all of the input blocks deletable, writes nothing to disk, and returns an empty ULID with a nil error.
Thanos is not handling this case and is exiting when the directory it expects to be named by the (empty) ULID doesn't exist.
Full logs to relevant components
The text was updated successfully, but these errors were encountered: