[openstack-dev] 答复: Ceilometer memory.usage can not get info from libvirt

ZhiQiang Fan aji.zqfan at gmail.com
Mon Nov 17 13:50:03 UTC 2014


libvirt cannot inspect memory usage because some condition is not satisfied.

But the AttributeError exception is ugly, Ceilometer should add basic check
for return value, otherwise the unnecessary exception will bother cloud
operator.  I have reported a bug in Ceilometer for this issue, see
https://bugs.launchpad.net/ceilometer/+bug/1393415

On Mon, Nov 17, 2014 at 5:51 PM, Rao Dingyuan <raodingyuan at chinacloud.com.cn
> wrote:

> As described in the document:
> http://docs.openstack.org/developer/ceilometer/measurements.html#measurements
>
>
>
> “””
>
> *Note*
>
>
>
> To enable the libvirt memory.usage supporting, you need libvirt version
> 1.1.1+, qemu version 1.5+, and you need to prepare suitable balloon driver
> in the image, particularly for Windows guests, most modern Linuxes have it
> built in. The memory.usage meters can’t be fetched without image balloon
> driver.
>
>
>
> “””
>
> J
>
>
>
>
>
>
> ------------------------------
>
> E_mail: raodingyuan at chinacloud.com.cn
>
>
>
> *发件人:* Du Jun [mailto:dj199008 at gmail.com]
> *发送时间:* 2014年11月17日 16:57
> *收件人:* OpenStack Development Mailing List (not for usage questions)
> *主题:* [openstack-dev] Ceilometer memory.usage can not get info from
> libvirt
>
>
>
> Hi all,
>
> 2014-11-17 16:04:01.563 5162 INFO ceilometer.agent [-] Polling pollster
> memory.usage in the context of meter_source
> 140000 2014-11-17 16:04:01.564 5162 DEBUG
> ceilometer.compute.pollsters.memory [-] Checking memory usage for instance
> 7e53172c-f05f-4fda-9855-af6775c1f4a8 get_samples
> /opt/stack/ceilometer/ceilometer/compute/pollsters/memory.py:31
> 140002 2014-11-17 16:04:01.573 5162 WARNING
> ceilometer.compute.virt.libvirt.inspector [-] Failed to inspect memory
> usage of instance-00000002, can not get info from libvirt
> 140003 2014-11-17 16:04:01.574 5162 ERROR
> ceilometer.compute.pollsters.memory [-] Could not get Memory Usage for
> 7e53172c-f05f-4fda-9855-af6775c1f4a8: 'NoneType' object has no attribute
> 'usage'
> 140004 2014-11-17 16:04:01.574 5162 TRACE
> ceilometer.compute.pollsters.memory Traceback (most recent call last):
> 140005 2014-11-17 16:04:01.574 5162 TRACE
> ceilometer.compute.pollsters.memory   File
> "/opt/stack/ceilometer/ceilometer/compute/pollsters/memory.py", line 37, in
> get_samples
> 140006 2014-11-17 16:04:01.574 5162 TRACE
> ceilometer.compute.pollsters.memory     'usage': memory_info.usage}))
> 140007 2014-11-17 16:04:01.574 5162 TRACE
> ceilometer.compute.pollsters.memory AttributeError: 'NoneType' object has
> no attribute 'usage'
>
> When
>
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
>


-- 
blog: zqfan.github.com
git: github.com/zqfan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20141117/c3a07f6b/attachment.html>


More information about the OpenStack-dev mailing list