[CRIU] [PATCH 6/6] zdtm.py: run tests with ASAN_OPTIONS
Andrey Ryabinin
aryabinin at virtuozzo.com
Mon Feb 6 02:14:17 PST 2017
To run CRIU with ASan we have to use some non-default options:
- detect_leaks=0 - We have to many leaks for know. Let's disable until fixed.
- disable_coredump=0 - without this ASan library changes RLIMIT_CORE which
break rlmimits00 tests.
- log_path=asan.log - For some reason default output to stderr sometimes
doesn't work in CRIU. So error log will be stored
in asan.log.<pid> file instead.
Signed-off-by: Andrey Ryabinin <aryabinin at virtuozzo.com>
---
test/zdtm.py | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/test/zdtm.py b/test/zdtm.py
index b07a06b..0c960b3 100755
--- a/test/zdtm.py
+++ b/test/zdtm.py
@@ -676,10 +676,12 @@ join_ns_file = '/run/netns/zdtm_netns'
class criu_cli:
@staticmethod
def run(action, args, fault = None, strace = [], preexec = None, nowait = False):
- env = None
+ env = dict(os.environ, ASAN_OPTIONS = "log_path=asan.log:disable_coredump=0:detect_leaks=0")
+
if fault:
print "Forcing %s fault" % fault
- env = dict(os.environ, CRIU_FAULT = fault)
+ env['CRIU_FAULT'] = fault
+
cr = subprocess.Popen(strace + [criu_bin, action] + args, env = env, preexec_fn = preexec)
if nowait:
return cr
--
2.10.2
More information about the CRIU
mailing list