Bug 1067064 - [oVirt QoS] It's impossible to run VM with Network QOS configured on VNIC profile
Summary: [oVirt QoS] It's impossible to run VM with Network QOS configured on VNIC pro...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: vdsm
Version: 3.4
Hardware: x86_64
OS: Linux
high
urgent
Target Milestone: ---
: 3.4.1
Assignee: Antoni Segura Puimedon
QA Contact: GenadiC
URL:
Whiteboard: network
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-02-19 15:30 UTC by GenadiC
Modified: 2014-04-03 11:46 UTC (History)
10 users (show)

Fixed In Version: 3.4.1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-04-02 13:15:17 UTC
oVirt Team: ---
Embargoed:


Attachments (Terms of Use)
engine and vdsm log (828.18 KB, application/zip)
2014-02-19 15:30 UTC, GenadiC
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 25788 0 None MERGED vnic QoS: Fix specParams to XML definition conversion Never
oVirt gerrit 26253 0 None ABANDONED vnic QoS: Fix specParams to XML definition conversion Never
oVirt gerrit 26254 0 None MERGED vnic QoS: Fix specParams to XML definition conversion Never

Description GenadiC 2014-02-19 15:30:26 UTC
Created attachment 865117 [details]
engine and vdsm log

Description of problem:
Start VM fails when on VM resides VNIC profile of the Network imported from Neutron (or created from Ovirt as external network) when for that VNIC profile is configured network QOS.
AttributeError: 'int' object has no attribute 'replace' is received on VDSM log

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Create external Network with Ovirt (or import one from Neutron)
2. Create Network QOS on DC
3. Create VNIC profile for Neutron network and configure on it QOS from previous step
4. Add that VNIC profile to VM
5. Start VM

Actual results:
Start VM fails

Expected results:
VM should be started

Comment 1 Sandro Bonazzola 2014-03-04 09:22:45 UTC
This is an automated message.
Re-targeting all non-blocker bugs still open on 3.4.0 to 3.4.1.

Comment 2 Mike Kolesnik 2014-03-09 12:49:44 UTC
From what I checked this happens also for a regular vNIC attached to a profile on the management network that has QoS.
The stacktrace suggests that QoS fields should be treated as string type in VDSM

Thread-8522::DEBUG::2014-03-09 13:56:34,054::vm::2138::vm.Vm::(_startUnderlyingVm) vmId=`eec15418-8492-4f22-a2f0-dc2d8067c58a`::_ongoingCreati
ons released
Thread-8522::ERROR::2014-03-09 13:56:34,054::vm::2164::vm.Vm::(_startUnderlyingVm) vmId=`eec15418-8492-4f22-a2f0-dc2d8067c58a`::The vm start p
rocess failed
Traceback (most recent call last):
  File "/usr/share/vdsm/vm.py", line 2124, in _startUnderlyingVm
    self._run()
  File "/usr/share/vdsm/vm.py", line 3008, in _run
    domxml = hooks.before_vm_start(self._buildCmdLine(), self.conf)
  File "/usr/share/vdsm/vm.py", line 2841, in _buildCmdLine
    self._appendDevices(domxml)
  File "/usr/share/vdsm/vm.py", line 2808, in _appendDevices
    deviceXML = dev.getXML().toxml(encoding='utf-8')
  File "/usr/lib64/python2.7/xml/dom/minidom.py", line 46, in toxml
    return self.toprettyxml("", "", encoding)
  File "/usr/lib64/python2.7/xml/dom/minidom.py", line 60, in toprettyxml
    self.writexml(writer, "", indent, newl)
  File "/usr/share/vdsm/vm.py", line 5056, in __hacked_writexml
    node.writexml(writer, indent + addindent, addindent, newl)
  File "/usr/share/vdsm/vm.py", line 5056, in __hacked_writexml
    node.writexml(writer, indent + addindent, addindent, newl)
  File "/usr/share/vdsm/vm.py", line 5044, in __hacked_writexml
    xml.dom.minidom._write_data(writer, attrs[a_name].value)
  File "/usr/lib64/python2.7/xml/dom/minidom.py", line 296, in _write_data
    data = data.replace("&", "&amp;").replace("<", "&lt;"). \
AttributeError: 'int' object has no attribute 'replace'
Thread-8522::DEBUG::2014-03-09 13:56:34,057::vm::2617::vm.Vm::(setDownStatus) vmId=`eec15418-8492-4f22-a2f0-dc2d8067c58a`::Changed state to Down: 'int' object has no attribute 'replace'

Comment 3 Dan Kenigsberg 2014-03-16 23:07:15 UTC
Vm.getXMLBandwidth() is a horrible mess (e.g oldBandwidth.getElementsByTagName) besides that issue.


Note You need to log in before you can comment on or make changes to this bug.