Roz Fx
2015-Apr-11 23:43 UTC
[libvirt-users] XML Parser failing due to cryptic Serial Number.
I set virt-manager in qemu:///system space and tried to add new VM but it didn't proceed. Found out serial in crypic form. # cat /sys/devices/virtual/dmi/id/product_serial ÿÿÿÿÿÿÿ #virt-manager --debugTraceback (most recent call last): File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 225, in _reparse_xml self._xmlobj = self._build_xmlobj(self._get_raw_xml()) File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 228, in _build_xmlobj return self._parseclass(self.conn.get_backend(), parsexml=xml) File "/usr/share/virt-manager/virtManager/nodedev.py", line 27, in _parse_convert return NodeDevice.parse(conn, parsexml) File "/usr/share/virt-manager/virtinst/nodedev.py", line 95, in parse tmpdev = NodeDevice(conn, parsexml=xml, allow_node_instantiate=True) File "/usr/share/virt-manager/virtinst/nodedev.py", line 106, in __init__ XMLBuilder.__init__(self, *args, **kwargs) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 777, in __init__ parent_xpath, relative_object_xpath) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 679, in __init__ self._parse(parsexml, parsexmlnode) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 692, in _parse doc = libxml2.parseDoc(xml) File "/usr/lib/python2.7/site-packages/libxml2.py", line 1327, in parseDoc if ret is None:raise parserError('xmlParseDoc() failed') libxml2.parserError: xmlParseDoc() failed [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (create:165) Showing new vm wizard [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (create:892) Guest type set to os_type=hvm, arch=x86_64, dom_type=kvm [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (xmlbuilder:694) Error parsing xml<device> <name>computer</name> <capability type='system'> <product>Vostro</product> <hardware> <vendor>Dell Inc.</vendor> <version>A10</version> <serial>ÿÿÿÿÿÿÿ</serial> <uuid>REMOVED</uuid> </hardware> <firmware> <vendor>Dell Inc.</vendor> <version>A10</version> <release_date>05/18/2013</release_date> </firmware> </capability> </device> [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] ERROR (create:346) Error setting create wizard conn state. Traceback (most recent call last): File "/usr/share/virt-manager/virtManager/create.py", line 344, in reset_state self.set_conn(activeconn, force_validate=True) File "/usr/share/virt-manager/virtManager/create.py", line 225, in set_conn self.set_conn_state() File "/usr/share/virt-manager/virtManager/create.py", line 626, in set_conn_state self.netlist.reset_state() File "/usr/share/virt-manager/virtManager/netlist.py", line 405, in reset_state self._populate_network_list() File "/usr/share/virt-manager/virtManager/netlist.py", line 253, in _populate_network_list vnet_bridges) File "/usr/share/virt-manager/virtManager/netlist.py", line 185, in _find_physical_devices for nodedev in self.conn.get_nodedevs("net"): File "/usr/share/virt-manager/virtManager/connection.py", line 648, in get_nodedevs xmlobj = dev.get_xmlobj() File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 160, in get_xmlobj self._reparse_xml() File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 225, in _reparse_xml self._xmlobj = self._build_xmlobj(self._get_raw_xml()) File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 228, in _build_xmlobj return self._parseclass(self.conn.get_backend(), parsexml=xml) File "/usr/share/virt-manager/virtManager/nodedev.py", line 27, in _parse_convert return NodeDevice.parse(conn, parsexml) File "/usr/share/virt-manager/virtinst/nodedev.py", line 95, in parse tmpdev = NodeDevice(conn, parsexml=xml, allow_node_instantiate=True) File "/usr/share/virt-manager/virtinst/nodedev.py", line 106, in __init__ XMLBuilder.__init__(self, *args, **kwargs) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 777, in __init__ parent_xpath, relative_object_xpath) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 679, in __init__ self._parse(parsexml, parsexmlnode) File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 692, in _parse doc = libxml2.parseDoc(xml) File "/usr/lib/python2.7/site-packages/libxml2.py", line 1327, in parseDoc if ret is None:raise parserError('xmlParseDoc() failed') parserError: xmlParseDoc() failed Any help will appreciate. RegardsRox
Ján Tomko
2015-Apr-14 11:33 UTC
Re: [libvirt-users] XML Parser failing due to cryptic Serial Number.
On Sat, Apr 11, 2015 at 11:43:40PM +0000, Roz Fx wrote:> I set virt-manager in qemu:///system space and tried to add new VM but it didn't proceed. Found out serial in crypic form. > # cat /sys/devices/virtual/dmi/id/product_serial > ÿÿÿÿÿÿÿ > > > #virt-manager --debugTraceback (most recent call last):...> File "/usr/share/virt-manager/virtinst/xmlbuilder.py", line 692, in _parse > doc = libxml2.parseDoc(xml) > File "/usr/lib/python2.7/site-packages/libxml2.py", line 1327, in parseDoc > if ret is None:raise parserError('xmlParseDoc() failed') > libxml2.parserError: xmlParseDoc() failed > [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (create:165) Showing new vm wizard > [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (create:892) Guest type set to os_type=hvm, arch=x86_64, dom_type=kvm > [Sun, 12 Apr 2015 06:06:16 virt-manager 4241] DEBUG (xmlbuilder:694) Error parsing xml> <device> > <name>computer</name> > <capability type='system'> > <product>Vostro</product> > <hardware> > <vendor>Dell Inc.</vendor> > <version>A10</version> > <serial>ÿÿÿÿÿÿÿ</serial> > <uuid>REMOVED</uuid> > </hardware> > <firmware> > <vendor>Dell Inc.</vendor> > <version>A10</version> > <release_date>05/18/2013</release_date> > </firmware> > </capability> > </device> > > Any help will appreciate.Hello, this is tracked by the following bug: https://bugzilla.redhat.com/show_bug.cgi?id=1184131 I have just sent another version of the patches fixing it in libvirt. Jan> RegardsRox >