Skip to content

Commit c5faa93

Browse files
authored
Merge pull request ceph#59782 from aclamk/wip-aclamk-fix-67596-allocmap
os/bluestore: Fix ceph-bluestore-tool allocmap command
2 parents 93cbc92 + 358f33a commit c5faa93

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/os/bluestore/BlueStore.cc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20572,6 +20572,14 @@ int BlueStore::read_allocation_from_drive_for_bluestore_tool()
2057220572
if (ret < 0) {
2057320573
return ret;
2057420574
}
20575+
if (bdev_label_multi) {
20576+
uint64_t lsize = std::max(BDEV_LABEL_BLOCK_SIZE, min_alloc_size);
20577+
for (uint64_t p : bdev_label_valid_locations) {
20578+
if (p != BDEV_FIRST_LABEL_POSITION) {
20579+
allocator->init_rm_free(p, lsize);
20580+
}
20581+
}
20582+
}
2057520583

2057620584
duration = ceph_clock_now() - start;
2057720585
stats.insert_count = 0;

0 commit comments

Comments
 (0)