[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] reproducible node health: make more robust and drop debugging output

Holger Levsen gitlab at salsa.debian.org
Sun Jul 26 01:14:55 BST 2020



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


Commits:
33b1de94 by Holger Levsen at 2020-07-26T02:14:43+02:00
reproducible node health: make more robust and drop debugging output

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

- - - - -


1 changed file:

- bin/reproducible_node_health_check.sh


Changes:

=====================================
bin/reproducible_node_health_check.sh
=====================================
@@ -147,7 +147,7 @@ fi
 echo "$(date -u) - checking whether all services are running fine..."
 if ! systemctl is-system-running > /dev/null; then
 	SERVICES=$(mktemp --tmpdir=$TEMPDIR node-health-XXXXXXX)
-	systemctl list-units --state=error,failed > $SERVICES 2>&1
+	systemctl list-units --state=error,failed | grep " failed " > $SERVICES
 	echo "$(date -u) - problematic services found:"
 	cat $SERVICES
 	echo "$(date -u) - trying to fix problematic services."
@@ -155,8 +155,6 @@ if ! systemctl is-system-running > /dev/null; then
 		if [ -n "$(grep $UNIT $SERVICES)" ] ; then
 			echo "$(date -u) - resetting failed unit $UNIT..."
 		        sudo systemctl reset-failed $UNIT
-		else
-			echo "$(date -u) - $UNIT fine..."
 		fi
 	done
 	for UNIT in pbuilder_build session- ; do
@@ -164,8 +162,6 @@ if ! systemctl is-system-running > /dev/null; then
 			SCOPE=$(grep $UNIT $SERVICES | cut -d ' ' -f2)
 			echo "$(date -u) - resetting failed scope $SCOPE for $UNIT..."
 		        sudo systemctl reset-failed $SCOPE
-		else
-			echo "$(date -u) - $UNIT fine..."
 		fi
 	done
 	rm $SERVICES



View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/33b1de94ad7c280556c9dbbe1b30687a95743bd6

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/33b1de94ad7c280556c9dbbe1b30687a95743bd6
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/20200726/f195fa5b/attachment-0001.html>


More information about the Qa-jenkins-scm mailing list