XenAPI: XenVIF implementation breaks the interface

Bug #1521977 reported by Bob Ball
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
huan

Bug Description

Other virt drivers (libvirt: https://git.openstack.org/cgit/openstack/nova/tree/nova/virt/libvirt/vif.py#n448, hyperv: https://git.openstack.org/cgit/openstack/nova/tree/nova/virt/hyperv/vif.py#n66) plug the VIFs when the vif_driver.plug() method is called.

 XenAPI's vif plug does not plug a device, but returns a dictionary - see https://git.openstack.org/cgit/openstack/nova/tree/nova/virt/xenapi/vif.py#n133 - and then "plugs" it during VM creation - see https://git.openstack.org/cgit/openstack/nova/tree/nova/virt/xenapi/vmops.py#n1881, called from https://git.openstack.org/cgit/openstack/nova/tree/nova/virt/xenapi/vmops.py#n547.

This is broken with respect to the names in the interface and what other virt drivers are doing.

It has further led to functionality being implemented that does nothing, for example driver.plug_vifs and driver.unplug_vifs make calls to vif_driver.plug and vif_driver.unplug - but these do nothing.

We need to fix the code so that:

vif_driver.plug will create a new VIF for the VM record
vif_driver.unplug will destroy the VIF record from the VM, if it still exists.

Tags: xenserver
Bob Ball (bob-ball)
Changed in nova:
importance: Undecided → Medium
tags: added: xenserver
Changed in nova:
status: New → Confirmed
description: updated
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/254022

Changed in nova:
assignee: nobody → huan (huan-xie)
status: Confirmed → In Progress
Changed in nova:
assignee: huan (huan-xie) → Jianghua Wang (wjh-fresh)
Changed in nova:
assignee: Jianghua Wang (wjh-fresh) → huan (huan-xie)
Changed in nova:
assignee: huan (huan-xie) → Jianghua Wang (wjh-fresh)
Changed in nova:
assignee: Jianghua Wang (wjh-fresh) → huan (huan-xie)
Changed in nova:
assignee: huan (huan-xie) → Bob Ball (bob-ball)
Changed in nova:
assignee: Bob Ball (bob-ball) → huan (huan-xie)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/254022
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=0e3372ac2e9444e69fde6df14a445ff1b963988a
Submitter: Jenkins
Branch: master

commit 0e3372ac2e9444e69fde6df14a445ff1b963988a
Author: Huan Xie <email address hidden>
Date: Mon Dec 7 06:12:31 2015 +0000

    XenAPI: Fix VIF plug and unplug problem

    When vif.plug is called, XenAPI's vif plug does not plug a device,
    but returns a dictionary of the vif record. This is not vif.plug is
    expected to do. This fix will create a new VIF when vif_driver.plug
    is called and destroy this VIF when vif_driver.unplug is called

    Change-Id: I1eb4cc3b1c44662fb3063a854880ebf79fcf6942
    Closes-Bug: #1521977

Changed in nova:
status: In Progress → Fix Released
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/nova 13.0.0.0b3

This issue was fixed in the openstack/nova 13.0.0.0b3 development milestone.

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.