[CRIU] [PATCH 2/2] test: don't clean up submounts (v2)
Andrey Vagin
avagin at openvz.org
Tue Aug 26 04:12:59 PDT 2014
From: Andrew Vagin <avagin at openvz.org>
I'm scared, when I see smth like that:
rm: cannot remove ‘/var/lib/jenkins/jobs/CRIU/workspace/test/dump/static/cgroup00/31195/1/.criu.cgyard.6qctPl/systemd/tasks’: Operation not permitted
v2: do that only in the "test" directory
Reported-by: Mr Jenkins
Signed-off-by: Andrew Vagin <avagin at openvz.org>
Signed-off-by: Andrey Vagin <avagin at openvz.org>
---
test/Makefile | 1 +
test/zdtm.sh | 4 ++--
test/zdtm/Makefile.inc | 4 +++-
3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/test/Makefile b/test/Makefile
index 05ad77a..2812e33 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -1,4 +1,5 @@
TST = $(shell ./zdtm.sh -l)
+RM := rm -f --one-file-system
ZDTM_ARGS ?= -C
diff --git a/test/zdtm.sh b/test/zdtm.sh
index cfbdce2..64ca6f2 100755
--- a/test/zdtm.sh
+++ b/test/zdtm.sh
@@ -685,7 +685,7 @@ EOF
cat $test.out
cat $test.out | grep -q PASS || return 2
- [ "$CLEANUP" -ne 0 ] && rm -rf `dirname $ddump`
+ [ "$CLEANUP" -ne 0 ] && rm -rf --one-file-system `dirname $ddump`
echo "Test: $test, Result: PASS"
return 0
}
@@ -950,5 +950,5 @@ else
fi
fi
-[ -n "$TMP_TREE" ] && rm -rf $TMP_TREE
+[ -n "$TMP_TREE" ] && rm -rf --one-file-system $TMP_TREE
[ -n "$ZDTM_FAILED" ] && exit 1 || exit 0
diff --git a/test/zdtm/Makefile.inc b/test/zdtm/Makefile.inc
index 215609b..510dc52 100644
--- a/test/zdtm/Makefile.inc
+++ b/test/zdtm/Makefile.inc
@@ -29,4 +29,6 @@ else
Q =
endif
-export E Q
+RM := rm -f --one-file-system
+
+export E Q RM
--
1.9.3
More information about the CRIU
mailing list