1.) Update /etc/carbon/storage-aggregation.conf to use the new xFilesFactor setting for new stats, if you haven't yet already
2.) Get the retention ranges as defined in storage-schemas.conf
fgrep retentions /etc/carbon/storage-schemas.conf | tr ',' ' '
retentions = 10s:5m 5m:1d 1h:30d 1d:2y
3.) Switch to the user who owns existing whisper data. (You don't want to create whiser files owned by root)
4.) Invoke whisper-resize with the supplied retention values, replacing commas with spaces:
whisper-resize --xFilesFactor=0 /var/lib/carbon/whisper/stats/timers/foo/upper.wsp 10s:5m 5m:1d 1h:30d 1d:2y
Retrieving all data from the archives Creating new whisper database: /var/lib/carbon/whisper/stats/timers/foo/upper.wsp.tmp Created: /var/lib/carbon/whisper/stats/timers/foo/upper.wsp.tmp (21280 bytes) Migrating data without aggregation... Renaming old database to: /var/lib/carbon/whisper/stats/timers/foo/upper.wsp.bak Renaming new database to: /var/lib/carbon/whisper/stats/timers/foo/upper.wsp
5.) Ensure that the newly-created files have owner:group association consistent with other files (double-checking step #3)
6.) Compare the output of whisper-info upper.wsp
and whisper-info upper.wsp.bak
to ensure results are as expected
7.) Delete the .bak backup
find /var/lib/carbon/whisper/stats \( -name 'upper.wsp' -o -name 'upper_90.wsp' -o -name 'lower.wsp' \) -exec whisper-resize --xFilesFactor=0 '{}' 10s:5m 5m:1d 1h:30d 1d:2y \; -exec chown carbon:carbon '{}' \; -exec chown carbon:carbon '{}.bak' \; -print