summaryrefslogtreecommitdiffstats
path: root/src/test/objectstore/store_test.cc
diff options
context:
space:
mode:
authorAdam Kupczyk <akupczyk@ibm.com>2024-07-01 15:44:41 +0200
committerAdam Kupczyk <akupczyk@ibm.com>2024-07-22 14:36:29 +0200
commit721482adc0de1371cf92cd4e73255ba170a2a5ac (patch)
tree3395ee6cde4a9ea150dd04cd4bbd091612bdaeb6 /src/test/objectstore/store_test.cc
parentos/bluestore: Review fixes (diff)
downloadceph-721482adc0de1371cf92cd4e73255ba170a2a5ac.tar.xz
ceph-721482adc0de1371cf92cd4e73255ba170a2a5ac.zip
os/bluestore: fix fsck fixing multiple bdev label (superblock)
The problem was that after fixing label location, location was not marked as "good label". In result the region was not excluded when saving allocator state. After reading allocator state, label was treated as corrupted. Fixed fixing bdev label when freelist is bitmap (HDD). Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Diffstat (limited to 'src/test/objectstore/store_test.cc')
-rw-r--r--src/test/objectstore/store_test.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/test/objectstore/store_test.cc b/src/test/objectstore/store_test.cc
index 5e010200625..dc277c3c5a6 100644
--- a/src/test/objectstore/store_test.cc
+++ b/src/test/objectstore/store_test.cc
@@ -11215,6 +11215,10 @@ TEST_P(MultiLabelTest, UpgradeToMultiLabelCollisionWithObjects) {
}
}
umount();
+ // Need to do 2 passes of repair:
+ // - the first one moves offending objects away
+ // - the second can then fix bdev labels
+ store->repair(false);
ASSERT_EQ(store->repair(false), 0);
ASSERT_EQ(store->fsck(false), 0);
bluestore_bdev_label_t label;