]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph: Set up valgrind as a flavor, and create a dir for logging.
authorGreg Farnum <gregory.farnum@dreamhost.com>
Mon, 15 Aug 2011 22:32:23 +0000 (15:32 -0700)
committerGreg Farnum <gregory.farnum@dreamhost.com>
Mon, 15 Aug 2011 22:32:23 +0000 (15:32 -0700)
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
teuthology/task/ceph.py

index 3fa590fe48dff7eeca4222d98337e4d693afa964..aa06814a2ad43ef18167644d02a86dfc2195becc 100644 (file)
@@ -753,6 +753,10 @@ def task(ctx, config):
         if config.get('coverage'):
             log.info('Recording coverage for this run.')
             flavor = 'gcov'
+        else:
+            if config.get('valgrind'):
+                log.info('Using notcmalloc flavor and running some daemons under valgrind')
+                flavor = 'notcmalloc'
     ctx.summary['flavor'] = flavor or 'default'
 
     coverage_dir = '/tmp/cephtest/archive/coverage'
@@ -767,6 +771,18 @@ def task(ctx, config):
             )
         )
 
+    if config.get('valgrind'):
+        val_path = '/tmp/cephtest/archive/{val_dir}'.format(val_dir=config.get('valgrind').get('logs', "valgrind"))
+        run.wait(
+            ctx.cluster.run(
+                args=[
+                    'mkdir', '-p', val_path
+                    ],
+                wait=False,
+                )
+            )
+
+
     with contextutil.nested(
         lambda: ceph_log(ctx=ctx, config=None),
         lambda: ship_utilities(ctx=ctx, config=None),