HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

virt-xml-validate — Validate `libvirt` XML files against a schema. If a schema is not specified, the schema is determine

Submitted by: @import:tldr-pages··
0
Viewed 0 times
commandfilesvirt-xml-validateclilibvirtvalidateagainstxml
linux

Problem

How to use the virt-xml-validate command: Validate libvirt XML files against a schema. If a schema is not specified, the schema is determined by the root element in the XML file. More information: <https://libvirt.org/manpages/virt-xml-validate.html>.

Solution

virt-xml-validate — Validate libvirt XML files against a schema. If a schema is not specified, the schema is determined by the root element in the XML file. More information: <https://libvirt.org/manpages/virt-xml-validate.html>.

Validate an XML file against a specific schema:
virt-xml-validate {{path/to/file.xml}} {{schema}}


Validate the domain XML against the domain schema:
virt-xml-validate {{path/to/domain.xml}} domain

Code Snippets

Validate an XML file against a specific schema

virt-xml-validate {{path/to/file.xml}} {{schema}}

Validate the domain XML against the domain schema

virt-xml-validate {{path/to/domain.xml}} domain

Context

tldr-pages: linux/virt-xml-validate

Revisions (0)

No revisions yet.