cinder backup difference in --container option

Bug #1881934 reported by Shatadru Bandyopadhyay
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
In Progress
Undecided
Shatadru Bandyopadhyay

Bug Description

There are differences in how '--container' parameter is interpreted by different cinder backup drivers.

- swift creates a bucket, nfs creates a directory, and ceph uses it as a pool name to override backup_ceph_pool.

- For ceph if the pool does not exists the backup creation eventually fails with
~~~
2020-05-27 00:22:20.902 1 DEBUG os_brick.initiator.connectors.rbd [req-f8a7f99b-2986-4893-a6aa-a2a778f9d179 ed47f67e4b9b494dae754c0938b1845d 0b6b14498ca740779af8258b452cc9d5 - default default] <== disconnect_volume: return (4ms) None trace_logging_wrapper /usr/lib/python2.7/site-packages/os_brick/utils.py:170
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server [req-f8a7f99b-2986-4893-a6aa-a2a778f9d179 ed47f67e4b9b494dae754c0938b1845d 0b6b14498ca740779af8258b452cc9d5 - default default] Exception during message handling: ObjectNotFound: [errno 2] error opening pool 'new_ceph_pool'
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server Traceback (most recent call last):
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/server.py", line 163, in _process_incoming
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server res = self.dispatcher.dispatch(message)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 220, in dispatch
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server return self._do_dispatch(endpoint, method, ctxt, args)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 190, in _do_dispatch
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server result = func(ctxt, **new_args)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/manager.py", line 413, in create_backup
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server self._update_backup_error(backup, six.text_type(err))
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server self.force_reraise()
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server six.reraise(self.type_, self.value, self.tb)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/manager.py", line 402, in create_backup
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server updates = self._run_backup(context, backup, volume)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/manager.py", line 489, in _run_backup
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server tpool.Proxy(device_path))
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/drivers/ceph.py", line 933, in backup
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server volume.name, length)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/drivers/ceph.py", line 657, in _backup_rbd
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server backup.container)) as client:
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/rbd.py", line 183, in __init__
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server self.cluster, self.ioctx = driver._connect_to_rados(pool)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/cinder/backup/drivers/ceph.py", line 300, in _connect_to_rados
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server ioctx = client.open_ioctx(pool_to_open)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 186, in doit
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server result = proxy_call(self._autowrap, f, *args, **kwargs)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 144, in proxy_call
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server rv = execute(f, *args, **kwargs)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 125, in execute
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server six.reraise(c, e, tb)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 83, in tworker
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server rv = meth(*args, **kwargs)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "rados.pyx", line 508, in rados.requires.wrapper.validate_func (/builddir/build/BUILD/ceph-12.2.12/build/src/pybind/rados/pyrex/rados.c:4672)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server File "rados.pyx", line 1203, in rados.Rados.open_ioctx (/builddir/build/BUILD/ceph-12.2.12/build/src/pybind/rados/pyrex/rados.c:12623)
2020-05-27 00:22:21.025 1 ERROR oslo_messaging.rpc.server ObjectNotFound: [errno 2] error opening pool 'new_ceph_pool'
~~~

- This is behaviour difference is not documented.
- User can potentially use this to find which pools are present in ceph.

tags: added: backup-service
Changed in cinder:
assignee: nobody → Shatadru Bandyopadhyay (shatadru)
status: New → In Progress
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.