Description of problem: Failed to create node device from .xml file, got out of memory error Version-Release number of selected component (if applicable): libvirt-0.6.3-14.el5 RHEL5.4-Server-x86_64-xen 2.6.18-156.el5xen How reproducible: 100% Steps to Reproduce: 1.# virsh nodedev-list --tree ............ +-pci_8086_29b2 +-pci_8086_29b3 +-pci_8086_29b4 +-pci_8086_29b6 +-pci_8086_29b7 2.# virsh nodedev-dumpxml pci_8086_29b7 <device> <name>pci_8086_29b7</name> <parent>computer</parent> <capability type='pci'> <domain>0</domain> <bus>0</bus> <slot>3</slot> <function>3</function> <product id='0x29b7'>82Q35 Express Serial KT Controller</product> <vendor id='0x8086'>Intel Corporation</vendor> </capability> </device> 3. Create node.xml file as below, modify <name> <product id>: <device> <name>pci_8086_29b8</name> <parent>computer</parent> <capability type='pci'> <domain>0</domain> <bus>0</bus> <slot>3</slot> <function>3</function> <product id='0x29b8'>82Q35 Express Serial KT Controller</product> <vendor id='0x8086'>Intel Corporation</vendor> </capability> </device> 4. # virsh nodedev-create node.xml Actual results: Output: error: Failed to create node device from node.xml error: out of memory Expected results: pci_8086_29b8 is created successfully Additional info: After # virsh nodedev-dumpxml pci_8086_29b7, have to # service libvirtd restart This has a Bug 509261 - nodedev-dumpxml can hang libvirtd
Pretty sure this is fixed by the following upstream commit: http://libvirt.org/git/?p=libvirt.git;a=commit;h=4ed2c3773e0c462ba3af628f62357cc6d9b61718
Created attachment 377259 [details] Backport of upstream changeset Applies cleanly and builds fine.
libvirt-0.6.3-25.el5 has been built in dist-5E-qu-candidate with the fix, Daniel
This bug has been verified with libvirt 0.6.3-25.el5 on RHEL-5.5. Already fixed, but a another error is raised: "error: Failed to create node device from node.xml error: this function is not supported by the hypervisor: Device is not a fibre channel HBA" it seems only can create a fibre channel HBA device from xml,Is it a correct behavior? Version-Release number of selected component (if applicable): [root@dhcp-66-70-62 bug]# uname -a Linux dhcp-66-70-62.nay.redhat.com 2.6.18-183.el5xen #1 SMP Mon Dec 21 18:46:14 EST 2009 x86_64 x86_64 x86_64 GNU/Linux [root@dhcp-66-70-62 bug]# rpm -qa|grep libvirt libvirt-0.6.3-25.el5 libvirt-python-0.6.3-25.el5 libvirt-debuginfo-0.6.3-25.el5 [root@dhcp-66-70-62 bug]# rpm -qa|grep xen xen-libs-3.0.3-102.el5 xen-devel-3.0.3-102.el5 kmod-gnbd-xen-0.1.5-2.el5 kmod-gfs-xen-0.1.34-9.el5 xen-3.0.3-102.el5 xen-libs-3.0.3-102.el5 kernel-xen-2.6.18-183.el5 kmod-cmirror-xen-0.1.22-3.el5 Steps to Reproduce: [root@dhcp-66-70-62 ~]# cat node.xml <device> <name>pci_8086_29b8</name> <parent>computer</parent> <capability type='pci'> <domain>0</domain> <bus>0</bus> <slot>3</slot> <function>3</function> <product id='0x29b8'>82Q35 Express Serial KT Controller</product> <vendor id='0x8086'>Intel Corporation</vendor> </capability> </device> [root@dhcp-66-70-62 ~]# virsh nodedev-create node.xml error: Failed to create node device from node.xml error: this function is not supported by the hypervisor: Device is not a fibre channel HBA
The error in comment #5 is expected. nodedev-create and nodedev-destroy only work on fibre channel devices, as the error indicates. The improper 'out of memory' error is no longer seen, so it appears this bug is fixed.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2010-0205.html