Comments (14)
@fabxc @Bplotka do you think that now with thanos this issue is addressed?
Not sure if there is an actual cli in thanos for this, but it seems that it solves that particular problem described here.
from tsdb.
Not really.
If I understand this right, we are talking here about multiple readers and single (or multiple even!) writer problem on TSDB blocks in filesystem.
This is related to this: thanos-io/thanos#206
Because this issue is still open, we cannot use local compaction because we have no idea when Prometheus TSDB starts compaction and removes some blocks while we are potentially in process of uploading those to object store.
This can be mitigated by Snapshot API, but I think it requires some change for Prometheus flag (Admin API?). This is not the best, but at least we have an workaround.
Without this workaround we could add some endpoints to turn of local compaction for short time.. not sure. It might be a smart move to just stick to workaround unless it causes more problems.
Any thoughts @fabxc @gouthamve ?
from tsdb.
I am fine with closing this for now, we can reopen when we will have clear indication that this is serious problem (workaround being not sufficient)
from tsdb.
No let's keep it open as there are obviously some blockers here.
from tsdb.
@bwplotka tsdb already has an api to disable/enable compactions
https://github.com/prometheus/tsdb/blob/407e12d051f7907e1bde47ccd59258eedbd10715/db.go#L743
so how about
- disable compaction
- upload the blocks needed
- enable compaction
from tsdb.
🎉 Now is the question... when Prometheus will expose it as API endpoint? (or is it done already?)
from tsdb.
if you think will work for you I can open a PR
from tsdb.
That will definitely fix this issue!
from tsdb.
I’m not sure it’s that easy, we typically don’t have endpoints mutating the configuration of the running process. I’m just wary of new use cases that could be argued for if we added this. Don’t get me wrong I have use cases for this as well, just trying to make sure we’re not making a mistake here.
from tsdb.
adding it will be very simple so why not open the PR and build a docker image so you can test it and will take it from there.
from tsdb.
I didn’t mean code wise, I meant accepting such functionality maintenance wise :)
from tsdb.
Yup, why can you not do this via the Snapshot API?
from tsdb.
I didn’t mean code wise, I meant accepting such functionality maintenance wise :)
Yup, hard to justify it.
As I said in very beggining, yup - we can use Snapshot API for it, as well as compaction disable API (if there would be any), so it's not blocking. (:
from tsdb.
I think we can close this one as this overlaps quite a lot with what we are discussing in #346
from tsdb.
Related Issues (20)
- Memory issues on short block sizes HOT 23
- Flaky test with the new live reader HOT 3
- TSDB CLI tool doesn't work on live Prometheus HOT 1
- Snapshots with head block are unsafe HOT 7
- Support selectors for LabelNames and LabelValues HOT 2
- double metric HOT 4
- selectOverlappingDirs bug that misses some directories HOT 1
- Why do Max and Minn have opposite definitions? HOT 1
- Improve renameFile function HOT 5
- Cleanup temp file if rename/replace failed HOT 1
- "unknown series references" after clean shutdown HOT 47
- Log storage filesystem type at startup HOT 4
- Investigate WAL compression HOT 1
- Prometheus restart very slowly when the size of data folder is huge HOT 18
- prometheus_tsdb_compactions_failed_total metric not incremented when compaction fails HOT 1
- Unstable: Not all data returned after write HOT 2
- How best to write blocks when bulk importing? HOT 6
- Cannot run more than one wal.LiveReader with metrics
- Proposal to compute actual size of files on filesystems with compression HOT 4
- docs outdated on Label offset Table? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tsdb.