XenAPI Volume Errors not showing up in Instance Faults

Bug #1122733 reported by Rick Harris
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Rick Harris

Bug Description

When an exception is raised in the low-level volume code for xenapi, e.g. down in volume_utils or volumeops, it is being caught and re-raised as a StorageError with a relatively generic error message.

This catching and re-raising is unnecessary and hampers debugging by masking the underlying exceptions from XenServer, which often are very helpful in troubleshooting the issue.

This proposed solution is to remove this unnecessary exception handling code and instead propagate that up to the instance faults.

Tags: xenserver
Changed in nova:
assignee: nobody → Rick Harris (rconradharris)
status: New → In Progress
importance: Undecided → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

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

Mate Lakat (mate-lakat)
tags: added: xenserver
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/21734
Committed: http://github.com/openstack/nova/commit/07cbf72301c5a3e588fc818abcab91f733b87738
Submitter: Jenkins
Branch: master

commit 07cbf72301c5a3e588fc818abcab91f733b87738
Author: Rick Harris <email address hidden>
Date: Tue Feb 12 05:29:23 2013 +0000

    xenapi: Remove unecessary exception handling

    The volume code was catching exceptions from the XenAPI only to re-raise
    more-generic StorageError exceptions. This practice makes it much more
    difficult to discover the root-cause of issues in production by making
    the message in the instance-faults table less useful.

    The solution is to have the original root-cause exception propogate all
    the way up to the instance-faults table where the developer will be able
    to make sense of it.

    Other cleanups:

    * Remove useless logging and stop logging opaque-refs in some places

    * Remove dead code (create_iscsi_storage)

    * Remove one-off functions (forget_sr_if_present,
      introduce_sr_unless_present); just use forget_sr and introduce_sr

    * Removed unused `exception` import

    * Added Openstack copyright lines

    Future Work:

    There are lots of other places where unecessary exception handling is
    occuring; this patch just addresses this in the attach/detach code-path.

    Fixes bug 1122733

    Change-Id: I8c382fb505303e604ff2e86afcf302efe3d6851d

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → grizzly-3
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: grizzly-3 → 2013.1
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.