From 03179408158491c3fbb95faa7a17db2149b7479e Mon Sep 17 00:00:00 2001 From: Axel Beckert Date: Tue, 17 Jan 2017 20:41:54 +0100 Subject: [PATCH] release-testing: Further mitigate LVM race conditions by using xen-delete-image --- NEWS.markdown | 7 +++++-- examples/release-testing | 5 ++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/NEWS.markdown b/NEWS.markdown index 6fd8a81..93dc3bf 100644 --- a/NEWS.markdown +++ b/NEWS.markdown @@ -50,8 +50,11 @@ Test Suite ---------- * release-testing: - + Use per-test-unique host names. Avoids race conditions with - immediately re-used LVs. + + Mitigate race conditions with immediately re-used LVs: + - Use per-test-unique host names. + - Delete potential old images by testing xen-delete-image before + calling xen-create-image. Add sync and sleep calls inbetween + those two commands, too. + Use "set -e" instead of "|| break". + Declare testability in distributions.conf instead of hardcoding it. Mark buster and bullseye as not testable, too, for now. diff --git a/examples/release-testing b/examples/release-testing index 7a52edc..0fcecd4 100755 --- a/examples/release-testing +++ b/examples/release-testing @@ -5,5 +5,8 @@ set -e exec 2>&1 | tee xen-tools-release-testing.log for dist in $(awk '!/^#|^$|dont-test/ {print $1}' /etc/xen-tools/distributions.conf); do - xen-create-image --dist $dist --hostname "xen-tools-release-testing-$dist" --force --verbose "$@" + xen-delete-image --verbose --hostname "xen-tools-release-testing-$dist" + sync + sleep 5 + xen-create-image --verbose --hostname "xen-tools-release-testing-$dist" --dist $dist --force "$@" done