[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] reproducible & everything: warn on files >8G in /var/log and fail maintenance…

Holger Levsen gitlab at salsa.debian.org
Sun Oct 7 16:32:26 BST 2018


Holger Levsen pushed to branch master at Debian QA / jenkins.debian.net


Commits:
ec09e960 by Holger Levsen at 2018-10-07T15:32:09Z
reproducible & everything: warn on files >8G in /var/log and fail maintenance job if files >32G are found

Signed-off-by: Holger Levsen <holger at layer-acht.org>

- - - - -


1 changed file:

- bin/reproducible_maintenance.sh


Changes:

=====================================
bin/reproducible_maintenance.sh
=====================================
@@ -57,6 +57,23 @@ fi
 #
 set -e
 
+#
+# find too large files in /var/log
+#
+echo "$(date -u) - Looking for too large files in /var/log/"
+TOOBIG=$(find /var/log -size +8G -exec ls -lah {} \; 2>/dev/null || true)
+if [ ! -z "$TOOBIG" ] ; then
+	echo
+	echo "$(date -u) - Warning: too large files found in /var/log:"
+	echo "$TOOBIG"
+	echo
+	DIRTY=true
+	if $(find /var/log -size +32G /dev/null 2>&1) ; then
+		echo "$(date -u) - Error, more than 32gb is just wrong..."
+		exit 1
+	fi
+fi
+
 #
 # delete old temp directories
 #



View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/commit/ec09e96090d2bafe85e758fa22b1d1a0f1d8506a

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/commit/ec09e96090d2bafe85e758fa22b1d1a0f1d8506a
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20181007/5771eb58/attachment-0001.html>


More information about the Qa-jenkins-scm mailing list