From 7a1ca217b4e024a6ccc18b9cd9caebd484dcf916 Mon Sep 17 00:00:00 2001 From: Mykola Malkov Date: Tue, 12 Jun 2018 14:14:09 +0200 Subject: [PATCH] TT#37257 Collect the list of running processes Collect the list of running process before and after kills in the end of deployment to catch if we do not stop them properly. Change-Id: Ie01853723d053a1ef198e47b89566bd4b9a93bbc --- templates/scripts/includes/deployment.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/templates/scripts/includes/deployment.sh b/templates/scripts/includes/deployment.sh index 9113472..0e74365 100755 --- a/templates/scripts/includes/deployment.sh +++ b/templates/scripts/includes/deployment.sh @@ -2421,12 +2421,18 @@ EOF fi # if [ -n "$PUPPET" ] ; then +# check the processes which are not stopped in installer and running +logit "Before stopping all the services" +ps auxwww || true # make sure we don't leave any running processes for i in asterisk atd collectd collectdmon dbus-daemon exim4 \ glusterd glusterfs glusterfsd glusterfs-server haveged monit nscd \ redis-server snmpd voisniff-ng ; do killall -9 $i >/dev/null 2>&1 || true done +# check the processes which are not stopped in installer and running +logit "After stopping all the services" +ps auxwww || true # remove retrieved and generated files rm -f ${TARGET}/config_*yml @@ -2439,10 +2445,10 @@ fi # don't leave any mountpoints sync -umount ${TARGET}/proc 2>/dev/null || true -umount ${TARGET}/sys 2>/dev/null || true -umount ${TARGET}/dev/pts 2>/dev/null || true -umount ${TARGET}/dev 2>/dev/null || true +umount ${TARGET}/proc || true +umount ${TARGET}/sys || true +umount ${TARGET}/dev/pts || true +umount ${TARGET}/dev || true sync # unmount chroot - what else?