-
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
downsample/compact: Compactor is not able to compact downsampled blocks. #281
Comments
I think it is as "easy" as just TSDB compaction having no idea how to read those blocks, because we have no control over blockReader for func (c *LeveledCompactor) Compact(dest string, dirs ...string) (uid ulid.ULID, err error) {
var (
blocks []BlockReader
bs []*Block
metas []*BlockMeta
uids []string
)
for _, d := range dirs {
b, err := OpenBlock(d, c.chunkPool)
if err != nil {
return uid, err
}
defer b.Close()
meta, err := readMetaFile(d)
if err != nil {
return uid, err
}
metas = append(metas, meta)
blocks = append(blocks, b)
bs = append(bs, b)
uids = append(uids, meta.ULID.String())
}
entropy := rand.New(rand.NewSource(time.Now().UnixNano()))
uid = ulid.MustNew(ulid.Now(), entropy)
meta := compactBlockMetas(uid, metas...)
err = c.write(dest, meta, blocks...)
if err == nil {
level.Info(c.logger).Log(
"msg", "compact blocks",
"count", len(blocks),
"mint", meta.MinTime,
"maxt", meta.MaxTime,
"ulid", meta.ULID,
"sources", fmt.Sprintf("%v", uids),
)
return uid, nil
} I feel like it is just a matter of adding an API for TSDB to allow opening special block readers and pass our Any thoughts @fabxc? |
Compactor gets chunks by ref and requires encoding which is for TSDB unknown:
|
#285 Fixes it. |
Hi,
|
I'm also seeing this on 0.7.0. @bwplotka any ideas why it might still be happening? |
Seeing what exactly? What are the all components versions? |
All thanos components are on 0.7.0.
|
@cassandracomar can you provide the step and I will try to replicate. |
We just used prometheus-operator 0.31.1 to deploy prometheus 2.10.0 with the thanos sidecar at v0.6.0, then deployed the other thanos components with this chart (https://github.com/kiwigrid/helm-charts/tree/master/charts/prometheus-thanos) at v0.6.0 on a brand new cluster and hit the same errors. I can send the block it's complaining about or I can send a script to replicate our setup on a fresh cluster, whatever is easier. |
'v0.6.0' - did you mean |
I can try again with 0.7.0. Just got a report this morning that it happened with a fresh deploy of 0.6.0. |
I see, yeah lets try to replicate with the I think for me it would be easier to replicate with just the blocks so once you get this error just ping me on slack |
All my downsampled blocks errors with
The text was updated successfully, but these errors were encountered: