AttributeError: 'Volume' object has no attribute 'instance_uuid' in manager.py retype

Bug #1436604 reported by Kurt Martin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
Critical
Walt Boring

Bug Description

I recieved the following error when attempting to retype a volume.

instance_uuid is no longer on the volume object after multi-attach patch landed

2015-03-25 16:01:47.495 DEBUG cinder.scheduler.filter_scheduler [req-d70cf053-c38d-4b7d-91cf-b204ecc173c2 0e3a4314bdd24fb6824355904bb2b95e 947c270f1cac45fcb99facff43a8438a] Filtered [host 'kurt-devstack2@3
pariscsi3#CPG3': free_capacity_gb: 4420, pools: None] from (pid=38334) _get_weighted_candidates /opt/stack/cinder/cinder/scheduler/filter_scheduler.py:309
2015-03-25 16:01:47.515 ERROR oslo_messaging.rpc.dispatcher [req-d70cf053-c38d-4b7d-91cf-b204ecc173c2 0e3a4314bdd24fb6824355904bb2b95e 947c270f1cac45fcb99facff43a8438a] Exception during message handling: '
Volume' object has no attribute 'instance_uuid'
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher Traceback (most recent call last):
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher executor_callback))
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher executor_callback)
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 130, in _do_dispatch
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher result = func(ctxt, **new_args)
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/osprofiler/profiler.py", line 105, in wrapper
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher return f(*args, **kwargs)
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/opt/stack/cinder/cinder/scheduler/manager.py", line 231, in retype
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher volume_ref, msg, reservations)
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/opt/stack/cinder/cinder/scheduler/manager.py", line 199, in _retype_volume_set_error
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher if (volume_ref['instance_uuid'] is None and
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_db/sqlalchemy/models.py", line 54, in __getitem__
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher return getattr(self, key)
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher AttributeError: 'Volume' object has no attribute 'instance_uuid'
2015-03-25 16:01:47.515 TRACE oslo_messaging.rpc.dispatcher

Changed in cinder:
status: New → Confirmed
importance: Undecided → Critical
assignee: nobody → Walt Boring (walter-boring)
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/167840

Changed in cinder:
status: Confirmed → In Progress
Mike Perez (thingee)
Changed in cinder:
milestone: none → kilo-rc1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

Reviewed: https://review.openstack.org/167840
Committed: https://git.openstack.org/cgit/openstack/cinder/commit/?id=8cd9e49a90f8ce7ee59420e4585c824e6dff889e
Submitter: Jenkins
Branch: master

commit 8cd9e49a90f8ce7ee59420e4585c824e6dff889e
Author: Walter A. Boring IV <email address hidden>
Date: Wed Mar 25 16:33:16 2015 -0700

    Fixed access to instance_uuid in retype

    We missed an access to volume['instance_uuid']
    in the multiattach patch. The instance_uuid and attached_host
    were moved into the volume_attachment table.

    This patch changes how we test to see if a volume is available
    or not, but checking the new location.

    Change-Id: I8844cd8c2947845f9efb11a2a1371efee2d28bbe
    Closes-Bug: 1436604

Changed in cinder:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in cinder:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in cinder:
milestone: kilo-rc1 → 2015.1.0
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.