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

[Xen-API] newbie: get_guest_metrics result MESSAGE_METHOD_UNKNOWN

To: xen-api@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-API] newbie: get_guest_metrics result MESSAGE_METHOD_UNKNOWN
From: Akira Akira <akira.lists.1948@xxxxxxxxx>
Date: Tue, 17 Mar 2009 22:07:39 +0900
Delivery-date: Tue, 17 Mar 2009 06:07:44 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=0z4fmltUpLycBRZNcM+/qa2BnSWqUQ3bkeWkek+4uDA=; b=vb2NYffj0FICnU2QIQoSJfeef018FBs8o7mq5rnzBaAlQUbaitRvLd/0RLWpnpl6+z WjWkh9vgTdd6T/qImJVE1b/goF+wTJ5PkVMk5hWWcBKxEORc7UaQsq4k85HkmxKbYQao fntDNxEx5435SS2lInBBtyde76GDsBgH7Wetk=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=QmVSm7wwntMyIrjIv4QA6DAkQdBnFDYcPGRQpYxDc7PEfIGf5y8NlwJ+n3U70VSU/Z 6P6G1Jr6sp26SacvcsHkwTRQ8WK3TbPLwn2gTgR5XXQHdJcXBfmNfOO8b+7KeryThU6F 3DdcjZ4T7+1ptMyNFKYRyk5YSuxy4aFpnL6ow=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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>
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
Hi All,

Although I already searched the mailing list archives to try to find a solution, I could only find people reporting this error without a solution.

I am trying to get the guest metrics to monitor the guest for memory shortage, for example. So here is what I executed (in python):

1) 
session = XenAPI.Session(url)
session.xenapi.login_with_password(username, password)
vms = session.xenapi.VM.get_all_records()
for vm in vms:
        g_metrics = session.xenapi.VM.get_guest_metrics(vm)

2)
session = XenAPI.Session(url)
session.xenapi.login_with_password(username, password)
vms = session.xenapi.VM.get_all_records()
for vm in vms:
        metrics = session.xenapi.VM.get_metrics(vm)
        g_metrics = session.xenapi.VM_guest_metrics.get_record(metrics)

And as a result I am getting the same following error for both codes:

XenAPI.Failure: MESSAGE_METHOD_UNKNOWN

The error is always in the last line (the one in which I try to obtain a guest metrics and assign it to g_metrics).

I am referring to this page to use the Xen API: http://wiki.xensource.com/xenwiki/XenApi

The documentation I am using is: API Revision 1.1, Date: 16th August 2007. Is there a more recent documentation? Am I using the wrong documentation?

Thank you in advance.

                     Akira
_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api
<Prev in Thread] Current Thread [Next in Thread>