Bug #8814 ยป ceph-disk.patch
src/ceph-disk | ||
---|---|---|
Check whether a given device path is a partition or a full disk.
|
||
"""
|
||
dev = os.path.realpath(dev)
|
||
if not os.path.exists(dev):
|
||
return False
|
||
if not stat.S_ISBLK(os.lstat(dev).st_mode):
|
||
raise Error('not a block device', dev)
|
||