[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] reproducible: be less picky about too many installed kernels on hosts which have large enough /boot

Holger Levsen gitlab at salsa.debian.org
Fri Apr 30 09:47:00 BST 2021



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


Commits:
39f85590 by Holger Levsen at 2021-04-30T10:42:42+02:00
reproducible: be less picky about too many installed kernels on hosts which have large enough /boot

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

- - - - -


3 changed files:

- bin/reproducible_node_health_check.sh
- bin/reproducible_system_health.sh
- logparse/reproducible.rules


Changes:

=====================================
bin/reproducible_node_health_check.sh
=====================================
@@ -120,9 +120,15 @@ fi
 #
 # check for cleaned up kernels
 #
-echo "$(date -u) - testing whether only one kernel is installed..."
-if [ "$(ls /boot/vmlinuz-*|wc -l)" != "1" ] ; then
-	echo "Warning: more than one kernel in /boot:"
+echo "$(date -u) - testing whether too many kernels are installed..."
+KERNEL="$(ls /boot/vmlinuz-*|wc -l)"
+case $HOSTNAME in
+	jenkins|ionos*)		MAX_KERNEL=5	;;
+	osuosl*)		MAX_KERNEL=3	;;
+	*)			MAX_KERNEL=1	;;
+esac
+if [ $KERNEL -gt $MAX_KERNEL ] ; then
+	echo "Warning: more than $MAX_KERNEL kernel(s) in /boot:"
 	ls -lart /boot/vmlinuz-*
 	df -h /boot
 	echo "Running kernel: $(uname -r)"


=====================================
bin/reproducible_system_health.sh
=====================================
@@ -151,8 +151,12 @@ for JOB_NAME in $(ls -1d reproducible_* | sort ) ; do
 			small_note "reboot needed for kernel upgrade"
 		elif $(grep -q "^WARNING: Running kernel does not match on-disk kernel image:" $LOG) ; then
 			small_note "reboot needed for kernel upgrade"
-		elif $(grep -q "Warning: more than one kernel in /boot" $LOG) ; then
+		elif $(grep -q "Warning: more than 1 kernel(s) in /boot" $LOG) ; then
 			small_note "more than one kernel installed"
+		elif $(grep -q "Warning: more than 3 kernel(s) in /boot" $LOG) ; then
+			small_note "more than three kernel(s) installed"
+		elif $(grep -q "Warning: more than 5 kernel(s) in /boot" $LOG) ; then
+			small_note "more than five kernels installed"
 		elif $(grep -q "failed failed /etc/rc.local Compatibility" $LOG) ; then
 			small_note "rc-local.service failed"
 		elif $(grep -E -q "failed Session [0-9]+ of user jenkins" $LOG) ; then


=====================================
logparse/reproducible.rules
=====================================
@@ -24,7 +24,7 @@ warning /Warning: /.../shm.+please tell the jenkins admins to fix this./
 warning /^Warning: today .+ came back to the present:/
 warning /^Warning: today is the wrong (present|future):/
 warning /Warning: curl http:..www.debian.org failed, probably the proxy is down for.+/
-warning /Warning: more than one kernel in.+/
+warning /Warning: more than . kernel\(s\) in.+/
 warning /Warning: rise of the jenkins job zombies.+/
 warning /Warning: jenkins.log is larger than.+/
 warning /^Warning: running kernel needs attention/



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

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/39f8559078f0646b9709cbc759db73bfe956c88e
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/20210430/a6507257/attachment-0001.htm>


More information about the Qa-jenkins-scm mailing list