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
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.
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/
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.
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