xenctrl domain name
Are there any function in the xenctrl lib (xenctrl.h) or some where else that will provide a list of domains that also returns the domains name. I've found functions like xc_domain_getinfo and xc_domain_getinfolist that return a list of domains but they do not give the domain name. If there's not, is there a function to return the name of a domain from it's id?
~Shaun
Its in xenstore.
You can use xs.h via xs_read
alternaltly from the shell:
xenstore-read /local/domain/0/name
Shaun R. wrote on 08/11/2008 03:02 PM:
Quoted 9 lines
Are there any function in the xenctrl lib (
xenctrl.h) or some where else that will provide a list of domains that also returns the domains name. I've found functions likexc_domain_getinfoandxc_domain_getinfolistthat return a list of domains but they do not give the domain name. If there's not, is there a function to return the name of a domain from it's id?~Shaun
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Wonder why the name is not provided with the domain info from those functions. Getting a domain list and then having to loop through xenstore until i find the name seams like extra work.
~Shaun
why would you need to loop, if you have the domid from the domain list?
Shaun R. wrote on 08/11/2008 03:30 PM:
Quoted 9 lines
Wonder why the name is not provided with the domain info from those functions. Getting a domain list and then having to loop through xenstore until i find the name seams like extra work.
~Shaun
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
My domains are tracked by the domain name, so if i wanted to find how much cpu the domain named george was using, i would now have to get a list of domain id's and loop through each id in the store until i found the name george... Or am i missing somthing?
~Shaun
Quoted 4 lines · Shaun R.
My domains are tracked by the domain name, so if i wanted to find how much cpu the domain named george was using, i would now have to get a list of domain id's and loop through each id in the store until i found the name george... Or am i missing somthing?
That's what you have to do unless you can cache name information some other way. Xen doesn't know about domain names hence it is not possible for the libxenctrl functions to give you faster access to names via a direct hypervisor interface.
-- Keir