-
Notifications
You must be signed in to change notification settings - Fork 169
Maintenance jobs unable to compress all chunks #1741
Comments
The number of uncompressed chunks depends on the number of unique metric names. Each metric name uses a hypertable and at any point in time there shouldn't be more than 2 chunks uncompressed per hypertable (the current one where current data is being written, the previous one which is kept open for one hour after the current chunk was created for data arriving late). How many unique metric names do you have? |
tsdb=# select count(*) from information_schema.tables where table_schema='prom_metric';
count
-------
2617 (or 2015 label values for Thanks, this was very informative. Do I understand correctly if I take from this that I shouldn't really expect the uncompressed chunks count to fall much below 2*(number_of_unique_metric_names)? In that case, the default alert value of 10 sounds very low? |
Yes, that's correct. Let me check with the team why the alert is defined like that. |
I agree, this should be changed to
Also, pinging @sumerman in case he knows the reason behind |
Thank you. As I have answered elsewhere my intention defining this metric was for it to go down to 0. 10 was a safety margin. |
@sumerman did we fix this? |
on a function used by the maintenance jobs. It should also fix for #1741
I expect #1794 to fix this when it lands |
on a function used by the maintenance jobs. It should also fix for #1741
on a function used by the maintenance jobs. It should also fix for #1741
Describe the bug
My Promscale instance is nearly constantly alerting
PromscaleMaintenanceJobNotKeepingup
, which seems to be becausepromscale_sql_database_chunks_metrics_uncompressed_count
never quite reachesthe set minimum of
10.
Instead, it seems to vary in the interval between 600 and ~1100, depending on maintenance job settings.
I have tried running
call prom_api.execute_maintenance();
manually, repeatedly (in a loop) and tried an aggressive schedule for maintenance jobs, running 4x every 5 minutes. They still seem to hit a "floor" around 600 uncompressed chunks.Unfortunately, I haven't been able to run the full debugging query from the runbook, as the database goes into recovery mode whenever I try.
To Reproduce
Not sure.
Expected behavior
promscale_sql_database_chunks_metrics_uncompressed_count
hitting values< 10
after maintenace jobs are done.Screenshots
Configuration (as applicable)
Version
Additional context
The text was updated successfully, but these errors were encountered: