Re: virsh snapshot-create --print-xml seems to ignore most arguments

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/20/19 11:14 AM, Timo Schneider wrote:
Hi,

I am wondering if the --print-xml option is working correctly. The
output for two snapshot-create commands are the same, even though the
first one includes additional options (no-metadata and atomic).

--no-metadata and --atomic merely pass additional flags to the API call; they do not affect the XML. Remember, it is the combination of both the XML and the API flags that control what the API will do.


I want to use the generated XML to create a snapshot via a perl script,
and Sys::Virt only seems to support snapshots using a XML description
of the arguments.

Yes, the perl bindings don't have the convenience wrappers like virsh, so you'll need the XML; but the perl bindings DO let you also pass in flags for the case where virsh has bool options for setting a flag.

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

_______________________________________________
libvirt-users mailing list
libvirt-users@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvirt-users





[Index of Archives]     [Virt Tools]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]

  Powered by Linux