[Piuparts-commits] rev 482 - in piatti/home/piupartsm: . bin

Holger Levsen holger at alioth.debian.org
Tue Aug 11 09:07:19 UTC 2009


Author: holger
Date: 2009-08-11 09:07:19 +0000 (Tue, 11 Aug 2009)
New Revision: 482

Added:
   piatti/home/piupartsm/bin/detect_piuparts_issues
Modified:
   piatti/home/piupartsm/crontab
Log:
detect failed builds due to missing chroot tarballs

Added: piatti/home/piupartsm/bin/detect_piuparts_issues
===================================================================
--- piatti/home/piupartsm/bin/detect_piuparts_issues	                        (rev 0)
+++ piatti/home/piupartsm/bin/detect_piuparts_issues	2009-08-11 09:07:19 UTC (rev 482)
@@ -0,0 +1,59 @@
+#!/bin/sh
+
+# Copyright 2009 Holger Levsen (holger at layer-acht.org)
+# 
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation; either version 2 of the License, or (at your
+# option) any later version.
+# 
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+# 
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+#
+# parse config file
+#
+
+TEMPFILE=`mktemp`
+egrep "(^sections|^master-directory)" /etc/piuparts/piuparts.conf| sed -e "s# =#=#g" -e "s#= #=#g" -e 's#=#="#' -e 's#$#"#' -e "s#sections#SECTIONS#" -e "s#master-directory#MASTER#" > $TEMPFILE
+source $TEMPFILE
+rm $TEMPFILE
+if [ -z "$MASTER" ] || [ -z "$SECTIONS" ] ; then
+	echo "sections and/or master-directory not set in /etc/piuparts/piuparts.conf, exiting."
+	exit 1
+fi
+
+#
+# detect piuparts problems
+#
+
+FILE=`mktemp`
+for SECTION in $SECTIONS ; do 
+	rgrep -l -e "tar: .*.tar.gz: Cannot open: No such file or directory" $MASTER/$SECTION/fail >> $FILE
+done
+if [ -s $FILE ] ; then 
+	echo "piuparts problem detected!"
+	echo "(By grep'ing for 'tar: .*.tar.gz: Cannot open: No such file or directory'"
+	echo "in failed logs.)"
+	echo 
+	echo "Please review the following logfiles and most likely remove them." 
+        echo
+	echo "If it is always the same package failing, it's likely to be an issue in the"
+	echo "package."
+	echo
+	sort -u $FILE | sed -e "s#$MASTER#http://piuparts.debian.org/#g"
+	echo
+	sort -u $FILE | sed -e "s#$MASTER#less $MASTER#"
+	echo
+	echo "----------------------------------------------------------------------"
+	echo
+	sort -u $FILE | sed -e "s#$MASTER#rm $MASTER#"
+	echo
+fi
+rm $FILE


Property changes on: piatti/home/piupartsm/bin/detect_piuparts_issues
___________________________________________________________________
Added: svn:executable
   + *

Modified: piatti/home/piupartsm/crontab
===================================================================
--- piatti/home/piupartsm/crontab	2009-08-11 09:04:39 UTC (rev 481)
+++ piatti/home/piupartsm/crontab	2009-08-11 09:07:19 UTC (rev 482)
@@ -27,7 +27,8 @@
 50 22 * * * /home/piupartsm/bin/detect_tmp_cruft
 55 22 * * * /home/piupartsm/bin/detect_network_issues
 0  23 * * * /home/piupartsm/bin/detect_archive_issues
-05 23 * * * /home/piupartsm/bin/report_untestable_packages
+5  23 * * * /home/piupartsm/bin/detect_piuparts_issues
+10 23 * * * /home/piupartsm/bin/report_untestable_packages
 
 #
 # misc




More information about the Piuparts-commits mailing list