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

Re: [Xen-API] How to get the host (slave) and vm real-time metrics(e.g. cpu_utilization)


  • To: xen-api@xxxxxxxxxxxxx
  • From: Will Sun <willsun810@xxxxxxxxx>
  • Date: Mon, 24 Nov 2014 09:49:42 +0800
  • Delivery-date: Mon, 24 Nov 2014 01:49:53 +0000
  • List-id: User and development list for XCP and XAPI <xen-api.lists.xen.org>

I am sorry for the messy codes . here I will resend my message.
I build a pool includes 3 hosts

2014-11-24 9:34 GMT+08:00 Will Sun <willsun810@xxxxxxxxx>:
The attachments are the picatures, incase you cannot see the pictures in the 1st email.
Thank youÂ


Best Regards!

Jesson

2014-11-24 9:24 GMT+08:00 Will Sun <willsun810@xxxxxxxxx>:

HiÂall,

IÂbuildÂaÂpoolÂincludesÂ3ÂhostsÂÂ:ÂvGate7ÂvGate8ÂvGate9.ÂÂvGate9ÂisÂtheÂmaster,othersÂareÂslaves.

IÂbuildÂaÂpageÂtoÂshowÂtheÂhostÂandÂvmÂmetrics(e.g.Âcpu_utilization)ÂonÂtheÂsameÂpage.ItÂworksÂfineÂforÂtheÂmasterÂ(vGate9)Â.ButÂitÂcannotÂgetÂtheÂslaveÂmetrics.

AsÂfollows:

Â

Â

Â

Â


InÂpython,IÂuseÂtheÂfollowingÂcodes to get the CPU Usage:



IÂattemptÂtoÂmakeÂanÂAPIÂcallÂtoÂaÂslaveÂ(evenÂsomethingÂtrivialÂlikeÂpool.get_all()),ÂIÂgetÂthe ['HOST_IS_SLAVE' ] exception,ÂalongÂwithÂtheÂmaster'sÂIPÂaddress.

TheÂmainÂproblemÂisÂtoÂget three hostsÂreal-timeÂperformingÂmetricsÂandÂtoÂshowÂthemÂonÂtheÂsameÂpage.Â

IsÂthereÂanyÂworkaroundÂtoÂsolveÂthisÂproblem?ÂThankÂyouÂinÂadvance!

Â



Best Regards!


Jesson




_______________________________________________
Xen-api mailing list
Xen-api@xxxxxxxxxxxxx
http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.