Skip to content

Commit

Permalink
mimic: test/store_test: workaround for failing BlobReuseOnOverwrite UT
Browse files Browse the repository at this point in the history
Workarounds: https://tracker.ceph.com/issues/38795

Nautilus+ releases doesn't have the issue which is probably related to
modifications of BlueStore::MempoolThread::_trim_shards which introduces
different calculation for meta|data_alloc parameters

Signed-off-by: Igor Fedotov <ifedotov@suse.com>
  • Loading branch information
ifed01 committed Apr 25, 2019
1 parent 6583c77 commit 4999f38
Showing 1 changed file with 32 additions and 3 deletions.
35 changes: 32 additions & 3 deletions src/test/objectstore/store_test.cc
Expand Up @@ -5947,10 +5947,20 @@ TEST_P(StoreTestSpecificAUSize, BlobReuseOnOverwrite) {
return;

size_t block_size = 4096;
StartDeferred(block_size);

SetVal(g_conf, "bluestore_max_blob_size", "65536");
// need to tune cache autotune interval as lack of cache balancing
// triggers excessive cache trimming after fsck
// See https://tracker.ceph.com/issues/38795
SetVal(g_conf, "bluestore_cache_autotune_interval", "1");
g_conf->apply_changes(NULL);

StartDeferred(block_size);

// wait 2xbluestore_cache_autotune_interval to make sure cache has been
// rebalanced
sleep(2);

int r;
coll_t cid;
ghobject_t hoid(hobject_t("test_hint", "", CEPH_NOSNAP, 0, -1, ""));
Expand Down Expand Up @@ -6120,10 +6130,20 @@ TEST_P(StoreTestSpecificAUSize, BlobReuseOnOverwriteReverse) {
return;

size_t block_size = 4096;
StartDeferred(block_size);

SetVal(g_conf, "bluestore_max_blob_size", "65536");
// need to tune cache autotune interval as lack of cache balancing
// triggers excessive cache trimming after fsck
// See https://tracker.ceph.com/issues/38795
SetVal(g_conf, "bluestore_cache_autotune_interval", "1");
g_conf->apply_changes(NULL);

StartDeferred(block_size);

// wait 2xbluestore_cache_autotune_interval to make sure cache has been
// rebalanced
sleep(2);

int r;
coll_t cid;
ghobject_t hoid(hobject_t("test_hint", "", CEPH_NOSNAP, 0, -1, ""));
Expand Down Expand Up @@ -6301,10 +6321,19 @@ TEST_P(StoreTestSpecificAUSize, BlobReuseOnSmallOverwrite) {
return;

size_t block_size = 4096;
StartDeferred(block_size);
SetVal(g_conf, "bluestore_max_blob_size", "65536");
// need to tune cache autotune interval as lack of cache balancing
// triggers excessive cache trimming after fsck
// See https://tracker.ceph.com/issues/38795
SetVal(g_conf, "bluestore_cache_autotune_interval", "1");
g_conf->apply_changes(NULL);

StartDeferred(block_size);

// wait 2xbluestore_cache_autotune_interval to make sure cache has been
// rebalanced
sleep(2);

int r;
coll_t cid;
ghobject_t hoid(hobject_t("test_hint", "", CEPH_NOSNAP, 0, -1, ""));
Expand Down

0 comments on commit 4999f38

Please sign in to comment.