Bug 1004627 - virt-xml-validate should succeed xml dumpxml from net-dumpxml
virt-xml-validate should succeed xml dumpxml from net-dumpxml
Status: CLOSED DUPLICATE of bug 1004364
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt (Show other bugs)
x86_64 Linux
medium Severity medium
: rc
: ---
Assigned To: Libvirt Maintainers
Virtualization Bugs
Depends On:
  Show dependency treegraph
Reported: 2013-09-05 01:24 EDT by EricLee
Modified: 2013-09-05 03:51 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-09-05 03:51:29 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description EricLee 2013-09-05 01:24:21 EDT
Description of problem:
virt-xml-validate should succeed xml dumpxml from net-dumpxml

Version-Release number of selected component (if applicable):
# rpm -qa libvirt qemu-kvm ; uname -r

How reproducible:

Steps to Reproduce:
# virsh net-list --all
 Name                 State      Autostart     Persistent
 default              active     yes           yes

# virsh net-dumpxml default > default.xml

# vim default.xml
<network connections='1'>
  <forward mode='nat'>
      <port start='1024' end='65535'/>
  <bridge name='virbr0' stp='on' delay='0' />
  <mac address='52:54:00:1c:4f:78'/>
  <ip address='' netmask=''>
      <range start='' end='' />

# virt-xml-validate default.xml network
default.xml:5: element nat: Relax-NG validity error : Element forward has extra content: nat
Relax-NG validity error : Extra element forward in interleave
default.xml:1: element network: Relax-NG validity error : Element network failed to validate content
default.xml fails to validate

Actual results:
see description

Expected results:
should succeed

Additional info:
However, do net-dumpxml then virt-xml-validate in RHEL6.5 will succeed, and net-dumpxml gets no 'connections' and
      <port start='1024' end='65535'/>
in default.xml:
# vim default.xml
  <forward mode='nat'/>
  <bridge name='virbr0' stp='on' delay='0' />
  <mac address='52:54:00:CA:89:0F'/>
  <ip address='' netmask=''>
      <range start='' end='' />

It is a new feature added in 1.0.3 according to:
http://libvirt.org/formatnetwork.html, but not modify virt-xml-validate correspondingly.
Comment 2 Jiri Denemark 2013-09-05 03:51:29 EDT

*** This bug has been marked as a duplicate of bug 1004364 ***

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