]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/tasks/rados: set pct_update_delay if balance_reads is set
authorSamuel Just <sjust@redhat.com>
Wed, 8 May 2024 19:21:47 +0000 (19:21 +0000)
committerSamuel Just <sjust@redhat.com>
Mon, 21 Oct 2024 17:04:51 +0000 (17:04 +0000)
Signed-off-by: Samuel Just <sjust@redhat.com>
qa/tasks/rados.py

index d8eac5d886fe8e00b2d4ca10ce98e51bd6753afc..96bcc770511a1d51a15ee08089bfc64d2a8533b4 100644 (file)
@@ -36,6 +36,8 @@ def task(ctx, config):
          write_fadvise_dontneed: write behavior like with LIBRADOS_OP_FLAG_FADVISE_DONTNEED.
                                  This mean data don't access in the near future.
                                  Let osd backend don't keep data in cache.
+         pct_update_delay: delay before primary propogates pct on write pause,
+                            defaults to 5s if balance_reads is set
 
     For example::
 
@@ -139,6 +141,7 @@ def task(ctx, config):
     object_size = int(config.get('object_size', 4000000))
     op_weights = config.get('op_weights', {})
     testdir = teuthology.get_testdir(ctx)
+    pct_update_delay = None
     args = [
         'adjust-ulimits',
         'ceph-coverage',
@@ -166,6 +169,7 @@ def task(ctx, config):
         args.extend(['--pool-snaps'])
     if config.get('balance_reads', False):
         args.extend(['--balance-reads'])
+        pct_update_delay = config.get('pct_update_delay', 5);
     if config.get('localize_reads', False):
         args.extend(['--localize-reads'])
     if config.get('max_attr_len', None):
@@ -274,6 +278,10 @@ def task(ctx, config):
                     if config.get('fast_read', False):
                         manager.raw_cluster_cmd(
                             'osd', 'pool', 'set', pool, 'fast_read', 'true')
+                    if pct_update_delay:
+                        manager.raw_cluster_cmd(
+                            'osd', 'pool', 'set', pool,
+                            'pct_update_delay', str(pct_update_delay));
                     min_size = config.get('min_size', None);
                     if min_size is not None:
                         manager.raw_cluster_cmd(