Skip to content

Commit 7e93b03

Browse files
authored
Merge pull request ceph#51067 from guits/fix-backward-compatible-issue-cv
ceph-volume: fix batch refactor issue
2 parents 300e3ee + 98c68f2 commit 7e93b03

File tree

1 file changed

+4
-1
lines changed
  • src/ceph-volume/ceph_volume/devices/lvm

1 file changed

+4
-1
lines changed

src/ceph-volume/ceph_volume/devices/lvm/batch.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,10 @@ def get_physical_fast_allocs(devices, type_, fast_slots_per_device, new_osds, ar
126126
if vg_name == 'unused_devices':
127127
slots_for_vg = requested_slots
128128
else:
129-
slots_for_vg = len(vg_devices) * requested_slots
129+
if len(vg_devices) > 1:
130+
slots_for_vg = len(args.devices)
131+
else:
132+
slots_for_vg = len(vg_devices) * requested_slots
130133
dev_size = dev.vg_size[0]
131134
# this only looks at the first vg on device, unsure if there is a better
132135
# way

0 commit comments

Comments
 (0)