]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
pybind/mgr/rbd_support: ignore missing OSD support for RBD namespaces 29433/head
authorJason Dillaman <dillaman@redhat.com>
Wed, 31 Jul 2019 18:19:28 +0000 (14:19 -0400)
committerJason Dillaman <dillaman@redhat.com>
Thu, 1 Aug 2019 12:07:24 +0000 (08:07 -0400)
During upgrades, the OSDs might not yet have been upgraded yet and
therefore might be missing namespace support.

Fixes: https://tracker.ceph.com/issues/41029
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/pybind/mgr/rbd_support/module.py

index bf6523de1acf3a1ed76f315c3ef2b525d015ce38..c08bc90469cc3bd8ec632a16c6ce316d76feb0e0 100644 (file)
@@ -673,9 +673,16 @@ class TaskHandler:
                 with self.module.rados.open_ioctx2(int(pool_id)) as ioctx:
                     self.load_task_queue(ioctx, pool_name)
 
-                    for namespace in rbd.RBD().namespace_list(ioctx):
+                    try:
+                        namespaces = rbd.RBD().namespace_list(ioctx)
+                    except rbd.OperationNotSupported:
+                        self.log.debug("Namespaces not supported")
+                        continue
+
+                    for namespace in namespaces:
                         ioctx.set_namespace(namespace)
                         self.load_task_queue(ioctx, pool_name)
+
             except rados.ObjectNotFound:
                 # pool DNE
                 pass