Bug 1417057 - Back port request of oschecks-check_glance_api fail(Bug 1364572) in OSP9
Summary: Back port request of oschecks-check_glance_api fail(Bug 1364572) in OSP9
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: sensu
Version: 9.0 (Mitaka)
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: ---
Assignee: Martin Magr
QA Contact: Leonid Natapov
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-27 06:53 UTC by Md Nadeem
Modified: 2020-03-11 15:39 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-31 15:50:55 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Md Nadeem 2017-01-27 06:53:54 UTC
Description of problem:

the bug(Bug 1364572) persist in both RHOSP8 and RHOSP9.
RHOSP8: RHOSP9: osops-tools-monitorins 0.5
RHOSP9: python-glanceclient-2.0.0
RHOSP9: python-glanceclient-1.1.1
 
>> https://bugzilla.redhat.com/show_bug.cgi?id=1364572

The bug is resolved in RHOSP10.
RHOSP10: osops-tools-monitorins 0.8
RHOSP10: python-glanceclient-2.5.0

Work-around for OSP 9:
upgrade osops-tools-monitorins to 0.8 and python-glanceclient to 2.5.0
and the issue gets resolved. 

However, this is highly not recommended to use this work around in production environment. So kindly provide an official hot-fix or backport it to OSP9

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. yum install osops-tools-monitoring-oschecks-0.1-0.5.a9d3fdagit.el7ost.noarch
2. source stackrc
3. /usr/libexec/openstack-monitoring/checks/oschecks-check_glance_api

Actual results:
ValueError: Expected endpoint

Expected results:
OK: Get images, Glance API is working: 

Additional info:

Comment 1 Md Nadeem 2017-01-31 13:02:26 UTC
The new version is released which solve this issue in OSP9 and OSP8.

>> https://access.redhat.com/downloads/content/rhel---7/x86_64/5043/osops-tools-monitoring-oschecks/0.1-0.6.a9d3fdagit.el7ost/noarch/fd431d51/package

Comment 2 Martin Magr 2017-01-31 15:44:17 UTC
For OSP-8 you have to use osops-tools-monitoring-oschecks-0.1-0.6.a9d3fdagit.el7ost to have the build with the fix. Not sure what "osops-tools-monitorins 0.5" means in description, but it seems to me, that you don't have correct version. The fix was meant for OSP-8 only, I'm currently testing the build on OSP-9 if it works there too or we will need another fix for OSP-9.

Comment 3 Martin Magr 2017-01-31 15:50:55 UTC
[root@osp9 ~]# /usr/libexec/openstack-monitoring/checks/oschecks-check_glance_api --os-username admin --os-password f29e1d5c10fe4ef6 --os-tenant-name admin --os-auth-url http://192.168.66.205:5000/v2.0
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/glance.py", line 30, in _check_glance_api
    options, args, client = glance.setup()
  File "/usr/lib/python2.7/site-packages/oschecks/utils.py", line 171, in setup
    client = self.glance._get_versioned_client(api_version, options)
  File "/usr/lib/python2.7/site-packages/glanceclient/shell.py", line 446, in _get_versioned_client
    return glanceclient.Client(api_version, endpoint, **kwargs)
  File "/usr/lib/python2.7/site-packages/glanceclient/client.py", line 51, in Client
    endpoint, url_version = utils.strip_version(endpoint)
  File "/usr/lib/python2.7/site-packages/glanceclient/common/utils.py", line 393, in strip_version
    raise ValueError("Expected endpoint")
ValueError: Expected endpoint

[root@osp9 ~]# rpm -q osops-tools-monitoring-oschecks
osops-tools-monitoring-oschecks-0.1-0.5.a9d3fdagit.el7ost.noarch

______________________________________________________________________


[root@osp9 ~]# /usr/libexec/openstack-monitoring/checks/oschecks-check_glance_api --os-username admin --os-password f29e1d5c10fe4ef6 --os-tenant-name admin --os-auth-url http://192.168.66.205:5000/v2.0
WARNING: Get images took more than 5 seconds, it's too long.|response_time=5
[root@osp9 ~]# /usr/libexec/openstack-monitoring/checks/oschecks-check_glance_api --os-username admin --os-password f29e1d5c10fe4ef6 --os-tenant-name admin --os-auth-url http://192.168.66.205:5000/v2.0
OK: Get images, Glance API is working: list 1 images in 0 seconds.|response_time=0
[root@osp9 ~]# rpm -q osops-tools-monitoring-oschecks
osops-tools-monitoring-oschecks-0.1-0.6.a9d3fdagit.el7ost.noarch
[root@osp9 ~]#


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