virt-designer man page

virt-designer — Generate domain XML

Synopsis

virt-designer [OPTION]...

Description

virt-designer is a command line tool for generating XML documents for libvirt domains. However, it cooperates with libosinfo database to guess the correct combination of attributes (e.g. disk driver, NIC model).

virt-designer does not feed libvirt with generated XML though. For now, it's a proof of concept.

Options

The basic structure of arguments passed to virt-designer is:

virt-designer [-c URI] [OPTION] [OPTION] ...

However, arguments have no pre-defined order so users can type them in any order they like.

General Options

-c URI, --connect=URI
The libvirt connection URI which is used for querying capabilities of the host.
--list-os
List IDs of operating systems known to libosinfo
--list-platform
List IDs of platforms known to libosinfo
-o OS, --os=OS
Specify operating system that will be run on the domain. OS is an ID which can be obtained via --list-os.
-p PLATFORM, --platform=PLATFORM
Specify platform (hypervisor) under which the domain will run. PLATFORM is and ID which can be obtained via --list-platform.
-a ARCH, --architecture=ARCH
Set domain's architecture
-C PATH[,FORMAT] --cdrom=PATH[,FORMAT]
Add PATH as a CDROM to the domain. To specify its format (e.g. raw, qcow2, phy) use FORMAT.
-d PATH[,FORMAT] --disk=PATH[,FORMAT]
Add PATH as a disk to the domain. To specify its format (e.g. raw, qcow2, phy) use FORMAT.
-i NETWORK[,ARG=VAL]
Add an interface of type network with NETWORK source. Moreover, some other configuration knobs can be set (possible ARGs): mac, link={up|down}
-g GRAPHICS
Add a graphics device of type GRAPHICS. Valid values are spice or vnc.
-s
Add smartcard reader to the VM conifguration
-u
Add USB controllers and setup USB redirection in the VM configuration.
-r RESOURCE, --resources=RESOURCES
Set minimal or recommended resources on the domain XML. By default, the recommended is used.

Usually, both --os and --platform are required as they are needed to make the right decision on driver, model, ... when adding a new device. However, when adding a disk which is an installation medium (e.g. a CD-ROM or DVD), virt-designer tries to guess the OS. Something similar is done with platform. Usually, the platform is guessed from the connection URI.

Examples

Domain with Fedora 17 from locally stored ISO and one NIC with mac 00:11:22:33:44:55 and link set down:

# virt-designer -C Fedora-17-x86_64-Live-KDE.iso \
                -i default,mac=00:11:22:33:44:55,link=down

To add multiple devices just use appropriate argument multiple times:

# virt-designer -d /tmp/home.img,qcow2 \
                -d /var/lib/libvirt/images/f17.img,qcow2 \
                -i default,mac=00:11:22:33:44:55,link=down \
                -i blue_network \
                -r minimal

Authors

Written by Michal Privoznik, Daniel P. Berrange and team of other contributors. See the Authors file in the source distribution for the complete list of credits.

Bugs

Report any bugs discovered to the libvirt community via the mailing list "http://libvirt.org/contact.html" or bug tracker "http://libvirt.org/bugs.html". Alternatively report bugs to your software distributor / vendor.

See Also

virsh(1), "virt-clone(1)", "virt-manager(1)", the project website "http://virt-manager.org"

Info

2015-03-06 libvirt-designer-0.0.2 Virtualization Support