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-users

[Xen-users] CPU Metric

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-users] CPU Metric
From: tommy schneider <tommy.schneider@xxxxxxxx>
Date: Wed, 15 Apr 2009 15:47:26 +0200
Delivery-date: Wed, 15 Apr 2009 06:42:56 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla-Thunderbird 2.0.0.19 (X11/20090103)
Hi there (Sorry for my poor English, i'm French)

I've a question for Xen users,
I'm trying to create a small app in Java, for get info about Xen VM.

A thing i need, is the percentage of total CPU that a VM use, the same information as the virt-manager show for each VM.

Does someone know how to get easily this information (i just need the percentage), i can use script but i don't know how to do it.

I've looked at the code of virt-manager, and i've found this :
centCpuTime = (cpuTime) * 100.0 / ((now - prevTimestamp)*1000.0*1000.0*1000.0*self.host_active_processor_count())
(Found in /usr/share/virt-manager/virtManager/connection.py)

If this line is the good one, how does it work ??? i can't understand it.

Thanks for you help
Tommy








_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-users] CPU Metric, tommy schneider <=