WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-api

Re: [Xen-API] Actual Memory used by DomU not see using python API.

To: "Sane, Abhijeet" <Abhijeet_Sane@xxxxxxx>
Subject: Re: [Xen-API] Actual Memory used by DomU not see using python API.
From: Alberto González Rodríguez <alberto@xxxxxxxxxxxxx>
Date: Thu, 27 May 2010 11:52:47 +0200
Cc: Goncalo Gomes <Goncalo.Gomes@xxxxxxxxxxxxx>, Jonathan Ludlam <Jonathan.Ludlam@xxxxxxxxxxxxx>, "xen-api@xxxxxxxxxxxxxxxxxxx" <xen-api@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 27 May 2010 02:53:06 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <CACE9D90AB02DA4F8DE4C45DB43BA34512B09DDFE6@xxxxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-api-request@lists.xensource.com?subject=help>
List-id: Discussion of API issues surrounding Xen <xen-api.lists.xensource.com>
List-post: <mailto:xen-api@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=unsubscribe>
References: <CACE9D90AB02DA4F8DE4C45DB43BA34512B09DDFE6@xxxxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
i use
memory_dynamic_max - memory_internal_free

2010/5/27 Sane, Abhijeet <Abhijeet_Sane@xxxxxxx>:
> Hi ,
> I am collecting Domain stats for the DomU 's on a host. I want to collect the 
> actual memory used , memory_dynamic_max using  the python api.
> The code snippet is as follows
>
>         try:
> 532                 for vm in all:
> 533                         try:
> 534                                 record = session.xenapi.VM.get_record(vm)
> 535                                 if  not record["is_control_domain"] and 
>  not record["is_a_template"] and record["resident_on"] :
> 536                                         vm_name = record["name_label"]
> 537                                         uuid = record["uuid"]
> 538                                         domid = record["domid"]
> 539                                         static_max_mem = 
> str(record["memory_static_max"])
> 540                                         vm_metrics = record["metrics"]
> 541                                         vm_metric = 
> session.xenapi.VM_metrics.get_record(vm_metrics)
> 542                                         dyn_max_mem = 
>  str(vm_metric["memory_actual"])
> 543                                         cpu_online = 
> session.xenapi.VM.get_VCPUs_max(vm)
> 544                                         vif_set = 
> session.xenapi.VM.get_VIFs(vm)
>
>
>
> I see that "memory_actual" values does not reflect the actual memory used but 
> shows the max memory available to the domain. I want to know if the rrd 
> database stores this data . Let me know if I am using the wrong field to 
> collect the data.
>
> Please guide.
>
> Abhijeet Sane
>
>
> _______________________________________________
> xen-api mailing list
> xen-api@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/mailman/listinfo/xen-api
>

_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api

<Prev in Thread] Current Thread [Next in Thread>