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

Re: [libvirt] inability to open local read-only connection



On Fri, Aug 20, 2010 at 08:49:50AM -0500, Tavares, John wrote:
> It is available via xm, so my point was if it can, why can't libvirt??

No particular reason why not, other than nobody has requested
it before. 

NB, 'xm uptime' is giving the uptime of the virtual domain,
not the guest OS running inside it.  ie if you reboot the guest
OS, the 'uptime' doesn't get reset because the virtual domain
itself (usually[1]) never stops.

> In the end, I had to switch to calling virsh until I can get
> all of problem resolved.
> 
> Ideally, virsh to would be able to provide most of the same 
> data as going thru libvirt directly.  It might also be nice 
> if it provided that data in a more machine parseable format.

We do plan to make it available in machine readable formats
in the future, but in most cases you'd be better off using
one of the APIs directly instead of virsh. There's a choice
of C, python, perl, java, ocaml, ruby. It would be significantly
more efficient to use the API becasue you would be avoiding the
overhead of opening & closing a connection for every single
data item collected.

Daniel

[1] For paravirt guests IIRC Xen may actually destroy & recreate
the virtual domain during a reboot, but fullvirt should be
transparent.
-- 
|: Red Hat, Engineering, London    -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :|
|: http://autobuild.org        -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|


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