Actions
Bug #56969
closedhas_bluestore_label() throws an error when the device_path is a path
% Done:
0%
Source:
Tags:
backport_processed
Backport:
quincy,pacific
Regression:
No
Severity:
3 - minor
Reviewed:
Description
When we instantiate the Device class with a path instead of a block device, it throws an error like following
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3.6/site-packages/ceph_volume/util/device.py", line 130, in __init__
self._parse()
File "/usr/lib/python3.6/site-packages/ceph_volume/util/device.py", line 233, in _parse
self.ceph_device = disk.has_bluestore_label(self.path)
File "/usr/lib/python3.6/site-packages/ceph_volume/util/disk.py", line 906, in has_bluestore_label
with open(device_path, "rb") as fd:
IsADirectoryError: [Errno 21] Is a directory: '/var/lib/ceph/osd/ceph-0/'
Passing a path instead of a block device is valid, `simple scan` needs it.
Updated by Adam King over 1 year ago
- Status changed from In Progress to Pending Backport
Updated by Backport Bot over 1 year ago
- Copied to Backport #56981: quincy: has_bluestore_label() throws an error when the device_path is a path added
Updated by Backport Bot over 1 year ago
- Copied to Backport #56982: pacific: has_bluestore_label() throws an error when the device_path is a path added
Updated by Guillaume Abrioux over 1 year ago
- Status changed from Pending Backport to Resolved
Actions