Consolidation of brick exceptions into a single
brick exception.py file neglected to updated files
that were using it:
(see change I577d403f02c2fd0d727d2694776008e1e9791453)
The result is the lvm driver was doing an except on lvm.VolumeGroupNotFound
which didn't exist anymore as it's in brick/exception now.
We still need to clean up exceptions all through here, and this still
isn't handled by service init anyway, but at least with this we are
raising a valid exception.
Change-Id: I588e9ac6548823b291d284f68f6133879bf3dfbf
Fixes: bug 1216122
from oslo.config import cfg
+from cinder.brick import exception as brick_exception
from cinder.brick.iscsi import iscsi
from cinder.brick.iser import iser
from cinder.brick.local_dev import lvm as lvm
root_helper,
lvm_type=self.configuration.lvm_type,
executor=self._execute)
- except lvm.VolumeGroupNotFound:
+ except brick_exception.VolumeGroupNotFound:
message = ("Volume Group %s does not exist" %
self.configuration.volume_group)
raise exception.VolumeBackendAPIException(data=message)