]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume: exceptions: add error for multiple volume groups
authorAlfredo Deza <adeza@redhat.com>
Mon, 3 Jul 2017 17:37:53 +0000 (13:37 -0400)
committerAlfredo Deza <adeza@redhat.com>
Fri, 4 Aug 2017 14:25:57 +0000 (10:25 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
src/ceph-volume/ceph_volume/exceptions.py

index 44739264fb4dab40195db9c7bc313404caf57744..da6fd11efb86651bc14886db571a2b0f39152870 100644 (file)
@@ -25,3 +25,13 @@ class MultipleLVsError(Exception):
     def __str__(self):
         msg = "Got more than 1 result looking for %s with path: %s" % (self.lv_name, self.lv_path)
         return msg
+
+
+class MultipleVGsError(Exception):
+
+    def __init__(self, vg_name):
+        self.vg_name = vg_name
+
+    def __str__(self):
+        msg = "Got more than 1 result looking for volume group: %s" % self.vg_name
+        return msg