Andrew Bogott has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/360869 )

Change subject: Graphite labs archiver:  Only save metrics for a year.
......................................................................

Graphite labs archiver:  Only save metrics for a year.

Bug: T168344
Change-Id: I3c5763bb0a7f801e0e5f2f6c2e689a323389e741
---
M modules/graphite/manifests/labs/archiver.pp
1 file changed, 9 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/69/360869/1

diff --git a/modules/graphite/manifests/labs/archiver.pp 
b/modules/graphite/manifests/labs/archiver.pp
index 770eb56..84eb251 100644
--- a/modules/graphite/manifests/labs/archiver.pp
+++ b/modules/graphite/manifests/labs/archiver.pp
@@ -21,4 +21,13 @@
         hour    => 13,
         require => File['/usr/local/bin/archive-instances'],
     }
+
+    # Clean up archives more than a year old
+    cron { 'delete-old-instance-archives':
+        ensure  => present,
+        command => "find /srv/carbon/whisper/archived_metrics -mtime +366 
-type f -delete"
+        user    => '_graphite',
+        minute  => 0,
+        hour    => 12,
+    }
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/360869
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3c5763bb0a7f801e0e5f2f6c2e689a323389e741
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to