Bug 1393461

Summary: OPS Tools | Availability Monitoring | OS Checks | Getting Critical Traceback on cinder_api check when the check fails. Should be an appropriate error message.
Product: Red Hat OpenStack Reporter: Leonid Natapov <lnatapov>
Component: sensuAssignee: Martin Magr <mmagr>
Status: CLOSED ERRATA QA Contact: Leonid Natapov <lnatapov>
Severity: unspecified Docs Contact:
Priority: high    
Version: 10.0 (Newton)CC: mlopes, mrunge, oblaut
Target Milestone: gaKeywords: Triaged
Target Release: 10.0 (Newton)   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: osops-tools-monitoring-oschecks-0.1-0.8.9f8354bgit.el7ost Doc Type: Bug Fix
Doc Text:
Previously, during connection problems, the cinder_api check would display a traceback instead of a clear message. With this update, the check now shows a clear message when there is a connection problem.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-14 16:36:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Leonid Natapov 2016-11-09 15:29:45 UTC
Getting Critical Traceback on cinder_api check when the check fails. Should be an appropriate error message.

-------

    CINDER_API
    ----------
     
    CRITICAL: Traceback (most recent call last):
      File "/usr/lib/python2.7/site-packages/oschecks/utils.py", line 110, in safe_run
        method()
      File "/usr/lib/python2.7/site-packages/oschecks/cinder.py", line 44, in _check_cinder_api
        elapsed, quotas = utils.timeit(quotas_list)
      File "/usr/lib/python2.7/site-packages/oschecks/utils.py", line 97, in wrapper
        res = func(*arg, **kw)
      File "/usr/lib/python2.7/site-packages/oschecks/utils.py", line 105, in timeit
        return func(*args, **kwargs)
      File "/usr/lib/python2.7/site-packages/oschecks/cinder.py", line 42, in quotas_list
        return client.quotas.get(options.os_tenant_name)
      File "/usr/lib/python2.7/site-packages/cinderclient/v1/quotas.py", line 39, in get
        "quota_set")
      File "/usr/lib/python2.7/site-packages/cinderclient/base.py", line 308, in _get
        resp, body = self.api.client.get(url)
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 393, in get
        return self._cs_request(url, 'GET', **kwargs)
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 342, in _cs_request
        self.authenticate()
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 506, in authenticate
        auth_url = self._v2_auth(auth_url)
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 576, in _v2_auth
        self._authenticate(url, body)
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 587, in _authenticate
        allow_redirects=True)
      File "/usr/lib/python2.7/site-packages/cinderclient/client.py", line 320, in request
        **kwargs)
      File "/usr/lib/python2.7/site-packages/requests/api.py", line 57, in request
        return session.request(method=method, url=url, **kwargs)
      File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 475, in request
        resp = self.send(prep, **send_kwargs)
      File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 585, in send
        r = adapter.send(request, **kwargs)
      File "/usr/lib/python2.7/site-packages/requests/adapters.py", line 467, in send
        raise ConnectionError(e, request=request)
    ConnectionError: HTTPConnectionPool(host='10.35.169.17', port=5000): Max retries exceeded with url: /v2.0/tokens (Caused by NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x1ce7490>: Failed to establish a new connection: [Errno 113] No route to host',))

Comment 1 Martin Magr 2016-11-16 10:29:42 UTC
osops-tools-monitoring-oschecks-0.1-0.7.9f8354bgit.el7ost

Comment 3 Leonid Natapov 2016-11-23 14:41:52 UTC
Fixed.
tested with osops-tools-monitoring-oschecks-0.1-0.8.9f8354bgit.el7ost.

Comment 5 errata-xmlrpc 2016-12-14 16:36:30 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-2950.html