From af57459f8ab1ddfcce730ab54262b3c0cdc58c16 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Sun, 18 Oct 2015 01:46:14 +0200 Subject: reproducible: throw away temporary directories older than 2 days (instead of 3) --- bin/reproducible_maintenance.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bin/reproducible_maintenance.sh b/bin/reproducible_maintenance.sh index fd34d527..dfa6ea4a 100755 --- a/bin/reproducible_maintenance.sh +++ b/bin/reproducible_maintenance.sh @@ -114,13 +114,13 @@ if [ ! -z "$OLDSTUFF" ] ; then fi # delete old pbuilder build directories -echo "$(date -u) - Deleting pbuilder build directories, older than 3 days." -OLDSTUFF=$(find /srv/workspace/pbuilder/ -maxdepth 1 -regex '.*/[0-9]+' -type d -mtime +3 -exec ls -lad {} \; || true) +echo "$(date -u) - Deleting pbuilder build directories, older than 2 days." +OLDSTUFF=$(find /srv/workspace/pbuilder/ -maxdepth 1 -regex '.*/[0-9]+' -type d -mtime +2 -exec ls -lad {} \; || true) if [ ! -z "$OLDSTUFF" ] ; then echo echo "Old temp directories found in $REP_RESULTS" echo -n "$OLDSTUFF" - find /srv/workspace/pbuilder/ -maxdepth 1 -regex '.*/[0-9]+' -type d -mtime +3 -exec sudo rm -rf --one-file-system {} \; || true + find /srv/workspace/pbuilder/ -maxdepth 1 -regex '.*/[0-9]+' -type d -mtime +2 -exec sudo rm -rf --one-file-system {} \; || true echo DIRTY=true fi @@ -130,11 +130,11 @@ echo "$(date -u) - Removing unused schroot sessions." cleanup_schroot_sessions # find old schroots -echo "$(date -u) - Removing old schroots." +echo "$(date -u) - Removing schroots older than 2 days." OLDSTUFF=$(find /schroots/ -maxdepth 1 -type d -regextype posix-extended -regex "/schroots/reproducible-.*-[0-9]{1,5}" -mtime +2 -exec ls -lad {} \; || true) if [ ! -z "$OLDSTUFF" ] ; then echo - echo "Old schroots found in /schroots, which will be deleted:" + echo "schroots older than 2 days found in /schroots, which will be deleted:" find /schroots/ -maxdepth 1 -type d -regextype posix-extended -regex "/schroots/reproducible-.*-[0-9]{1,5}" -mtime +2 -exec sudo rm -rf --one-file-system {} \; || true echo "$OLDSTUFF" OLDSTUFF=$(find /schroots/ -maxdepth 1 -type d -regextype posix-extended -regex "/schroots/reproducible-.*-[0-9]{1,5}" -mtime +2 -exec ls -lad {} \; || true) -- cgit v1.2.3-70-g09d2