/usr/share/doc/libsys-virt-perl/examples/dump-xml.pl is in libsys-virt-perl 1.2.1-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | # -*- perl -*-
use strict;
use warnings;
use Sys::Virt;
my $addr = "";
if (@ARGV == 2) {
$addr = shift @ARGV;
}
if (@ARGV != 1) {
print STDERR "syntax: $0 [URI] DOMAIN-NAME\n";
exit 1;
}
my $con = Sys::Virt->new(address => $addr, readonly => 1);
my $name = shift @ARGV;
my $dom = $con->get_domain_by_name($name);
print $dom->get_xml_description(), "\n";
|