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

Re: [libvirt-users] ruby-libvirt equiv of virsh list --all



On Tue, 27 Apr 2010 10:02:15 -0400
Hi,

Chris Lalancette <clalance redhat com> wrote:

> The ruby-libvirt library is just a thin wrapper around the libvirt API's.
> In point of fact, if you look at the libvirt API's (and virsh), you'll see
> that all virsh does is to take the two lists it gets back from list_defined_domains
> and list_domains, and concatenate them.  So in ruby, you would do something similar
> to get the whole list, and then you'd have to iterate through each of them, dump
> the XML, and get the UUID out of it.
> 
> -- 
> Chris Lalancette

That's what I thought. Was just hoping for something a little more ellegant. 
Having to grab a list of stopped "names" and then running "id's" and convert to "uuid" just to grab a list of all the domains seems a little painful to me.

Was hoping to for something like this: 

    @conn.list_domains_uuid

and have it grab all uuid's for domains running or not. 

Thanks


-- 
Regards
Mick Pollard ( lunix )
------------------------------------------------
BOFH Excuse of the day:
Static Hardware Condition Warning



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