← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1302796] Re: nova-compute (icehouse) exits with a misleading error when libvirt_vif_driver = nova.virt.libvirt.vif.LibvirtHybridOVSBridgeDriver

 

Reviewed:  https://review.openstack.org/85707
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=fdffaab6171562487a404963dbf6b7f1f9469a65
Submitter: Jenkins
Branch:    milestone-proposed

commit fdffaab6171562487a404963dbf6b7f1f9469a65
Author: Lars Kellogg-Stedman <lars@xxxxxxxxxx>
Date:   Fri Apr 4 14:58:12 2014 -0400

    mark vif_driver as deprecated and log warning
    
    Several classes were dropped from nova.virt.libvirt.vif from havana ->
    icehouse, leading to invalid configurations if one of these classes was
    used in the libvirt_vif_driver setting in nova.conf.  The error message
    produced by nova-compute in this situation is misleading.
    
    This patch introduces stubs for all of the classes that were removed.
    These stubs inherit from LibvirtGenericVIFDriver and log a deprecation
    warning in __init__.
    
    This patch also marks the vif_driver option as deprecated.
    
    Change-Id: I6d6cb9315ce6f3b33d17756bcdc77dccda26fefe
    Closed-bug: 1302796
    (cherry picked from commit 9f6070e194504cc2ca2b7f2a2aabbf91c6b81897)


** Changed in: nova
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1302796

Title:
  nova-compute (icehouse) exits with a misleading error when
  libvirt_vif_driver =
  nova.virt.libvirt.vif.LibvirtHybridOVSBridgeDriver

Status in OpenStack Compute (Nova):
  Fix Released

Bug description:
  In Havana, this was a valid setting:

  libvirt_vif_driver=nova.virt.libvirt.vif.LibvirtHybridOVSBridgeDriver

  The nova.virt.libvirt.vif.LibvirtHybridOVSBridgeDriver class has been
  removed in Icehouse; if nova-compute is run with this setting in
  nova.conf, the resulting error is...

     2014-04-04 19:33:55.783 17413 TRACE nova.virt.driver ImportError:
  Class LibvirtDriver cannot be found (['Traceback (most recent call
  last):\n', '  File "/usr/lib/python2.6/site-
  packages/nova/openstack/common/importutils.py", line 29, in
  import_class\n    return getattr(sys.modules[mod_str], class_str)\n',
  "AttributeError: 'module' object has no attribute 'LibvirtDriver'\n"])

  ...which is misleading, and will cause people to start looking at the
  setting of compute_driver.  The error is caused by the libvirt driver
  attempting to import the vif class:

            vif_class =
  importutils.import_class(CONF.libvirt.vif_driver)

  If this configuration option was valid in Havana, then:

  (a) there should probably be a deprecation warning prior to it going away, and 
  (b) the error message in icehouse should point at the actual problem rather than throwing a misleading exception.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1302796/+subscriptions


References