Bug 1382390 - Aodh treshold alarm - HTTPException (HTTP N/A)
Summary: Aodh treshold alarm - HTTPException (HTTP N/A)
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: python-ceilometerclient
Version: 10.0 (Newton)
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 10.0 (Newton)
Assignee: Mehdi ABAAKOUK
QA Contact: Yurii Prokulevych
URL:
Whiteboard:
Depends On:
Blocks: 1382419
TreeView+ depends on / blocked
 
Reported: 2016-10-06 14:29 UTC by Yurii Prokulevych
Modified: 2016-12-14 16:10 UTC (History)
10 users (show)

Fixed In Version: python-ceilometerclient-2.6.2-1.el7ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1382419 (view as bug list)
Environment:
Last Closed: 2016-12-14 16:10:32 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1626404 0 None None None 2016-10-06 15:08:34 UTC
OpenStack gerrit 383002 0 None None None 2016-10-06 14:51:47 UTC
OpenStack gerrit 384847 0 None None None 2016-10-11 16:32:29 UTC
OpenStack gerrit 389345 0 None None None 2016-11-09 13:20:14 UTC
Red Hat Product Errata RHEA-2016:2948 0 normal SHIPPED_LIVE Red Hat OpenStack Platform 10 enhancement update 2016-12-14 19:55:27 UTC

Description Yurii Prokulevych 2016-10-06 14:29:28 UTC
Description of problem:
-----------------------
Traceback in aodh/evaluator.log during 'threshold' alarm evaluation.

2016-10-06 14:26:16.273 29443 DEBUG aodh.evaluator.threshold [-] stats query [{u'field': u'resource_id', u'type': u'', u'value': u'CustomMeter-Resource-1', u'op': u'eq'}, {'field': 'timestamp', 'value': '2016-10-06T14:26:16.273345', 'op': 'le'}, {'field': 'timestamp', 'value': '2016-10-06T14:22:16.273345', 'op': 'ge'}] _statistics /usr/lib/python2.7/site-packages/aodh/evaluator/threshold.py:124
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold [-] alarm stats retrieval failed
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold Traceback (most recent call last):
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold   File "/usr/lib/python2.7/site-packages/aodh/evaluator/threshold.py", line 128, in _statistics
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold     period=rule['period'])
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold   File "/usr/lib/python2.7/site-packages/ceilometerclient/v2/statistics.py", line 58, in list
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold     q, p))
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold   File "/usr/lib/python2.7/site-packages/ceilometerclient/common/base.py", line 63, in _list
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold     resp = self.api.get(url)
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold   File "/usr/lib/python2.7/site-packages/keystoneauth1/adapter.py", line 187, in get
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold     return self.request(url, 'GET', **kwargs)
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold   File "/usr/lib/python2.7/site-packages/ceilometerclient/client.py", line 473, in request
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold     raise exc.from_response(resp, body)
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold HTTPException: HTTPException (HTTP N/A)
2016-10-06 14:26:16.299 29443 ERROR aodh.evaluator.threshold 
2016-10-06 14:26:16.300 29443 DEBUG aodh.evaluator.threshold [-] sanitize stats [] _sanitize /usr/lib/python2.7/site-packages/aodh/evaluator/threshold.py:95



Version-Release number of selected component (if applicable):
-------------------------------------------------------------
python-aodh-3.0.0-0.20160921151816.bb5103e.el7ost.noarch
openstack-aodh-notifier-3.0.0-0.20160921151816.bb5103e.el7ost.noarch
openstack-aodh-evaluator-3.0.0-0.20160921151816.bb5103e.el7ost.noarch
python-aodhclient-0.7.0-1.el7ost.noarch
puppet-aodh-9.4.0-1.el7ost.noarch
openstack-aodh-listener-3.0.0-0.20160921151816.bb5103e.el7ost.noarch
openstack-aodh-common-3.0.0-0.20160921151816.bb5103e.el7ost.noarch
openstack-aodh-api-3.0.0-0.20160921151816.bb5103e.el7ost.noarch


How reproducible:
-----------------
100%

Steps to Reproduce:
1. Deploy overcloud.
2. Create threshold alarm:
aodh --debug alarm create \
--type threshold \
--name 'AClient-Threshold-1' \
--description 'AodhClient-Threshold-Alarm-1' \
--severity low \
--enabled True \
--alarm-action 'log://' \
--ok-action 'log://' \
--insufficient-data-action 'log://' \
--repeat-actions False \
--comparison-operator ge \
--evaluation-periods 3 \
--meter-name CustomMeter-1 \
--period 60 \
--statistic avg \
--threshold 4 \
--query 'resource_id=CustomMeter-Resource-1'

3. Check aodh/evaluator.log

Comment 1 Mehdi ABAAKOUK 2016-10-06 15:38:35 UTC
This have to be fixed in ceilometerclient to report a correct and usage error and in Aodh to fix the behavior when the sample-api is disable.

Comment 3 Mehdi ABAAKOUK 2016-10-21 09:32:07 UTC
The upstream version that fix this issue is 2.6.2 (or 2.7.0) not 2.6.1.
We are wait for the upstream release https://review.openstack.org/#/c/389345/

Comment 4 Yurii Prokulevych 2016-11-18 13:40:42 UTC
Verified with python-ceilometerclient-2.6.2-1.el7ost.noarch

2016-11-18 13:39:29.691 69360 DEBUG aodh.evaluator [-] evaluating alarm e9147794-5dcd-469d-8674-a1c0c7be72b8 _evaluate_alarm /usr/lib/python2.7/site-packages/aodh/evaluator/__init__.py:257
2016-11-18 13:39:29.691 69360 DEBUG aodh.evaluator.threshold [-] query stats from 2016-11-18 13:35:29.691288 to 2016-11-18 13:39:29.691288 _bound_duration /usr/lib/python2.7/site-packages/aodh/evaluator/threshold.py:90
2016-11-18 13:39:29.691 69360 DEBUG aodh.evaluator.threshold [-] stats query [{u'field': u'resource_id', u'type': u'', u'value': u'alarm-resource-1', u'op': u'eq'}, {'field': 'timestamp', 'value': '2016-11-18T13:39:29.691288', 'op': 'le'}, {'field': 'timestamp', 'value': '2016-11-18T13:35:29.691288', 'op': 'ge'}] _statistics /usr/lib/python2.7/site-packages/aodh/evaluator/threshold.py:125
2016-11-18 13:39:29.765 69360 WARNING aodh.evaluator.threshold [-] This telemetry installation is not configured to support alarm of type 'threshold', they should be disabled or removed.

Comment 6 errata-xmlrpc 2016-12-14 16:10:32 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHEA-2016-2948.html


Note You need to log in before you can comment on or make changes to this bug.