简体   繁体   中英

TimeShift in Graphite

When running the function timeShift on graphite, I notice that if I change the 'from' to be large from (something also with -30days) the data is changing. It seems to come back from graphite as aggregation data that some of the points have combined into 1

Someone know what happen? And why?

Edit

this is our retentions on storage-aggregation.conf

[t]
pattern = ^t\.
retentions = 5min:30d,1h:180d,1d:1y


[z]
pattern = ^z.*
retentions = 10s:14d,1min:30d,10min:1y

what should I do to fix the timeShift problem, that jump when I'm in t.* and I use from = -30days and ask for timeshift of 7days I'm getting aggregate numbers

What are your aggregation settings in storage-schemas.conf ?

If you're requesting data from 30 days ago it's quite likely that the only data available for that period is aggregated.

You'll need to make sure that you have your retention settings configured so that the data you want to graph is available at the resolution you need.

Update: OP posted their storage aggregation config, so now we can see the problem.

You'll want to increase the 5min retention from 30 to 60 or 90 days, since if you want to look at the last 7 days with a 30 day time-shift you need at least 37 (7 + 30) days of retention at the 5 minute resolution. You currently only have 30 days total of 5-minute data so your shifted series is always going to have to use the aggregated 1-hour data.

60 days of retention would let you look at up to 4 weeks worth of 5-minute data with a 30-day time-shift overlaid. Do note that changing your storage-schemas.conf won't change any existing whisper database files (it only applies to new series), so you'll need to use the whisper-resize.py utility to update the retention settings on your existing whisper databases.

The command would be something like:

whisper-resize.py foo.wsp 5min:60d 1h:180d 1d:1y

Where foo.wsp is the name of the whisper file for the series you want to update (they're usually stored under /opt/graphite/storage ).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM