Project

General

Profile

Bug #38472

ceph-volume lvm batch raises KeyError when wal-devices is defined

Added by Joshua Schmid 6 months ago. Updated 4 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Target version:
Start date:
02/25/2019
Due date:
% Done:

0%

Source:
Community (dev)
Tags:
lvm ceph-volume osd
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:

Description

data1:~ # CEPH_VOLUME_DEBUG=true ceph-volume lvm batch /dev/vdb /dev/vdc /dev/vdd /dev/vde /dev/vdf --wal-devices /dev/
vdg /dev/vdh
Traceback (most recent call last):
File "/usr/sbin/ceph-volume", line 11, in <module>
load_entry_point('ceph-volume==1.0.0', 'console_scripts', 'ceph-volume')()
File "/usr/lib/python3.6/site-packages/ceph_volume/main.py", line 38, in init
self.main(self.argv)
File "/usr/lib/python3.6/site-packages/ceph_volume/decorators.py", line 59, in newfunc
return f(*a, **kw)
File "/usr/lib/python3.6/site-packages/ceph_volume/main.py", line 148, in main
terminal.dispatch(self.mapper, subcommand_args)
File "/usr/lib/python3.6/site-packages/ceph_volume/terminal.py", line 182, in dispatch
instance.main()
File "/usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/main.py", line 40, in main
terminal.dispatch(self.mapper, self.argv)
File "/usr/lib/python3.6/site-packages/ceph_volume/terminal.py", line 182, in dispatch
instance.main()
File "/usr/lib/python3.6/site-packages/ceph_volume/decorators.py", line 16, in is_root
return func(*a, **kw)
File "/usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/batch.py", line 325, in main
self.execute()
File "/usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/batch.py", line 281, in execute
self.strategy.report_pretty(self.filtered_devices)
File "/usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/strategies/bluestore.py", line 215, in report_pretty
path=osd['block.db']['path'],
KeyError: 'path'
data1:~ # vi /usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/strategies/bluestore.py
data1:~ # CEPH_VOLUME_DEBUG=true ceph-volume lvm batch /dev/vdb /dev/vdc /dev/vdd /dev/vde /dev/vdf --wal-devices /dev/vdg /dev/vdh

/usr/lib/python3.6/site-packages/ceph_volume/devices/lvm/strategies/bluestore.py(214)report_pretty()

-> string += templates.osd_component.format(
(Pdb) l
209 size=osd['data']['human_readable_size'],
210 percent=osd['data']['percentage'])
211
212 if 'block.db' in osd:
213 import pdb;pdb.set_trace()
214 -> string += templates.osd_component.format(
215 _type='[block.db]',
216 path=osd['block.db']['path'],
217 size=osd['block.db']['human_readable_size'],
218 percent=osd['block.db']['percentage'])
219
(Pdb) osd {'data': {'path': '/dev/vdb', 'size': 20401094656.0, 'percentage': 100.0, 'human_readable_size': '19.00 GB'}, 'block.db': {}, 'block.wal': {'path': 'vg: vg/lv', 'size': 3865470566, 'human_readable_size': '3.60 GB', 'percentage': 20}}
(Pdb) osd['block.db']

{}
(Pdb)

History

#1 Updated by Jan Fajerski 6 months ago

  • Assignee set to Jan Fajerski

#3 Updated by Jan Fajerski 4 months ago

  • Status changed from New to Resolved

Also available in: Atom PDF