On cleanup racer terminates child scripts: file_create.sh,
dir_create.sh, etc. Children of those srcipts do not get terminated
that way. Long running commands, like dd, causes annoying warnings:
/mnt/lustre2 is still busy, wait one second
on attempt to umount $DIR2.
Add trap to all child scripts to have then to cleanup on exiting.
Seagate-bug-id: MRP-2106
Change-Id: Ie9453449ceea3657881ebc0ce1edeb9e259c848e
Signed-off-by: Lokesh Nagappa Jaliminche <lokesh.jaliminche@seagate.com>
Reviewed-on: http://review.whamcloud.com/18475
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
19 files changed:
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT
+trap 'kill $(jobs -p)' EXIT