test_volume_boot_pattern failing with stacktrace and 500 error from cinder

Bug #1435574 reported by Joe Gordon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
High
Walt Boring

Bug Description

when enabling test_volume_boot_pattern with https://review.openstack.org/#/c/165616/2/tempest/scenario/test_volume_boot_pattern.py,cm

Cinder throws the following error:

http://logs.openstack.org/16/165616/2/check/check-tempest-dsvm-postgres-full/5cd3197/logs/screen-c-api.txt.gz?level=TRACE#_2015-03-19_02_28_04_252

2015-03-19 02:28:04.252 5396 ERROR cinder.api.middleware.fault [-] Caught error: list index out of range
Traceback (most recent call last):

  File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply
    executor_callback))

  File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch
    executor_callback)

  File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 130, in _do_dispatch
    result = func(ctxt, **new_args)

  File "/usr/local/lib/python2.7/dist-packages/osprofiler/profiler.py", line 105, in wrapper
    return f(*args, **kwargs)

  File "/opt/stack/new/cinder/cinder/volume/manager.py", line 155, in ldo_inner1
    return ldo_inner2(inst, context, volume_id, attachment_id, **kwargs)

  File "/usr/local/lib/python2.7/dist-packages/oslo_concurrency/lockutils.py", line 445, in inner
    return f(*args, **kwargs)

  File "/opt/stack/new/cinder/cinder/volume/manager.py", line 154, in ldo_inner2
    return f(*_args, **_kwargs)

  File "/opt/stack/new/cinder/cinder/volume/manager.py", line 824, in detach_volume
    attachment = attachments[0]

IndexError: list index out of range

Changed in cinder:
assignee: nobody → Walt Boring (walter-boring)
importance: Undecided → High
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/167045

Changed in cinder:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

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

commit bc7a284bd2fd27d0f29a8facd5a67abc90667f26
Author: Walter A. Boring IV <email address hidden>
Date: Mon Mar 23 16:39:37 2015 -0700

    Be safe with getting attachment

    The volume manager wasn't being safe with trying to pull an
    attachment out of the attachments list. It's possible someone
    is calling the manager to detach a volume that has no attachments.

    This patch raises an InvalidVolume exception if we detect that
    there are no attachments left to detach.

    Change-Id: I684ed870d13a4efc6f64b0144c987e355428bc54
    Closes-Bug: #1435574

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