Bug 1018548 - cinder backup fails with local tgt
Summary: cinder backup fails with local tgt
Keywords:
Status: CLOSED DUPLICATE of bug 1021627
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-packstack
Version: 4.0
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: async
: 4.0
Assignee: Ivan Chavero
QA Contact: Yogev Rabl
URL:
Whiteboard: storage
Depends On: 1021627
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-13 07:25 UTC by Yogev Rabl
Modified: 2016-04-26 16:57 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-12-11 18:35:19 UTC
Target Upstream Version:
aortega: needinfo+


Attachments (Terms of Use)
Add swift backup options to config file (1.91 KB, patch)
2013-11-23 01:21 UTC, Ivan Chavero
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1239285 0 None None None Never

Description Yogev Rabl 2013-10-13 07:25:15 UTC
Description of problem:
The Cinder backup fail to backup a volume. The configuration is the default local TGT.
The size of the volume is 1 GB, the size of the storage is 20 GB. 
The setup doesn't have Swift in it.
The error from the backup log is: 

2013-10-13 10:08:58.481 27251 ERROR cinder.openstack.common.rpc.amqp [req-52c5fd2f-3a6d-4321-ae62-5e7c0aa308cb ab622325036c40d6b2f8d4ba830f37b4 7ba6991d8f804b4a876f43335a876872] Exception during message handling
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp Traceback (most recent call last):
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/openstack/common/rpc/amqp.py", line 441, in _process_data
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     **args)
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/openstack/common/rpc/dispatcher.py", line 148, in dispatch
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     return getattr(proxyobj, method)(ctxt, **kwargs)
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/backup/manager.py", line 180, in create_backup
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     'fail_reason': unicode(err)})
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib64/python2.6/contextlib.py", line 23, in __exit__
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     self.gen.next()
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/backup/manager.py", line 173, in create_backup
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     self.driver.backup_volume(context, backup, backup_service)
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/volume/drivers/lvm.py", line 309, in backup_volume
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     backup_service.backup(backup, volume_file)
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/backup/drivers/swift.py", line 331, in backup
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     object_meta, container = self._prepare_backup(backup)
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp   File "/usr/lib/python2.6/site-packages/cinder/backup/drivers/swift.py", line 239, in _prepare_backup
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp     raise exception.SwiftConnectionFailed(reason=str(err))
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp SwiftConnectionFailed: Connection to swift failed: [Errno 111] ECONNREFUSED
2013-10-13 10:08:58.481 27251 TRACE cinder.openstack.common.rpc.amqp

Version-Release number of selected component (if applicable):
openstack-cinder-2013.2-0.9.b3.el6ost.noarch

How reproducible:
everytime

Steps to Reproduce:
1. Create a volume.
2. Backup the volume
3.

Actual results:
The backup status is error

Expected results:
The backup status is available.

Additional info:

Comment 2 Eric Harney 2013-10-14 15:54:18 UTC
Please link upstream LP bug if filing upstream too.

Comment 3 Eric Harney 2013-10-14 16:25:47 UTC
You need to configure at least these settings in /etc/cinder/cinder.conf:

backup_swift_user=admin
backup_swift_password=asdfasdf
backup_swift_url=http://192.168.122.xxx:8080/v1/AUTH_

Comment 4 Eric Harney 2013-10-14 16:26:53 UTC
CCing mmagr since this is probably something we could have packstack do.

Comment 5 Alvaro Lopez Ortega 2013-11-23 01:12:18 UTC
Looks like this bug should be fixed within the Cinder puppet module. ichavero is currently working on a fix for it.

Comment 6 Ivan Chavero 2013-11-23 01:21:50 UTC
Created attachment 828049 [details]
Add swift backup options to config file

Added swift backup options to cinder module.

Comment 7 Ivan Chavero 2013-11-23 01:24:49 UTC
The cinder puppet module lacks the backup options for swift i added the options to the module.

Martin, could you check it out and give me some advice.

Thanks!

Comment 8 Martin Magr 2013-12-02 10:13:56 UTC
The best thing to is to submit your patch to upstream in case you need to modify puppet module. Patch looks OK to me, but it's better to have more eyes to check it.

Comment 9 Ivan Chavero 2013-12-02 22:34:18 UTC
Martin, is it ok to submit the patch to our repos while is approved upstream so we can close this bug?

Comment 12 Ivan Chavero 2013-12-08 23:37:34 UTC
The code on 1021627 is already merged and the cinder plugin uses cinder::backup::swift in it's manifests.

Doing some tests, Martin, Francesco can you helo me confirm that it works??

Comment 13 Ivan Chavero 2013-12-11 18:35:19 UTC

*** This bug has been marked as a duplicate of bug 1021627 ***


Note You need to log in before you can comment on or make changes to this bug.