Description of problem: I executed this command: glance image-create --name RHEL6.5 --disk-format=qcow2 --container-format=bare --is-public true --copy-from http://http://storage.lab.bos.redhat.com/rhel-guest-image-6.5-20140121.0.x86_64.qcow2 Message in console was ".... image queued" When I execute "glance image-list" - its empty Error in log /var/log/glance/api.log "Failed to configure store correctly: Store sheepdog could not be configured correctly. Reason: Error in store configuration: Unexpected error while running command." Actual problem is this file does not exist "http://storage.lab.bos.redhat.com/rhel-guest-image-6.5-20140121.0.x86_64.qcow2" So what "image-create" should have outputted at the command prompt was "file not found" or even a simple "http 404" and halted - instead of inaccurately 'queuing' the image and throwing an error in the api.log Version-Release number of selected component (if applicable): RHEL-OSP4 How reproducible: Do an "glance image-create" and use a bad URL
Checked on: RHEL7 openstack-glance-2014.1-2.el7ost.noarch Using exact same image-upload command On console -> status | queued # glance image-list -> empty list. What exactly am I supposed to get on console or api.log in such a case of bad URL? Checking code (guessing) should get "The HTTP URL is invalid" # grep "The HTTP URL is invalid" -r /var/log/ returns nothing. Nor have I gotten such a notice on console. Thanks
Verified on: rhel7 python-glance-2014.1-4.el7ost.noarch python-glanceclient-0.12.0-1.el7ost.noarch openstack-glance-2014.1-4.el7ost.noarch openstack-glance-doc-2014.1-4.el7ost.noarch As expected uploading image from invalid URL, console -> "The HTTP URL is invalid" As well as notice on api.log [root@dhcp160-207 glance(keystone_admin)]# glance image-create --name RHEL6.5 --disk-format=qcow2 --container-format=bare --is-public true --copy-from http://http://storage.lab.bos.redhat.com/rhel-guest-image-6.5-20140121.0.x86_64.qcow2 Request returned failure status. 400 Bad Request The HTTP URL is invalid. (HTTP 400) Section from api.log debug=true 2014-06-12 11:15:57.197 5256 DEBUG routes.middleware [3b324204-f075-41bc-b3e7-61f61792c5b3 0d5ee85f3c4c4c18ad9e2e900998a6d3 00fbd2008f914e56b00fd3efe961bee8 - - -] Match dict: {'action': u'create', 'controller': <glance.common.wsgi.Resource object at 0x3c83350>} __call__ /usr/lib/python2.7/site-packages/routes/middleware.py:103 2014-06-12 11:15:57.324 5256 DEBUG glance.store.http [3b324204-f075-41bc-b3e7-61f61792c5b3 0d5ee85f3c4c4c18ad9e2e900998a6d3 00fbd2008f914e56b00fd3efe961bee8 - - -] The HTTP URL is invalid. get_size /usr/lib/python2.7/site-packages/glance/store/http.py:152 2014-06-12 11:15:57.325 5256 DEBUG glance.api.v1.images [3b324204-f075-41bc-b3e7-61f61792c5b3 0d5ee85f3c4c4c18ad9e2e900998a6d3 00fbd2008f914e56b00fd3efe961bee8 - - -] The HTTP URL is invalid. _get_size /usr/lib/python2.7/site-packages/glance/api/v1/images.py:679 2014-06-12 11:15:57.328 5256 INFO glance.wsgi.server [3b324204-f075-41bc-b3e7-61f61792c5b3 0d5ee85f3c4c4c18ad9e2e900998a6d3 00fbd2008f914e56b00fd3efe961bee8 - - -] 10.35.160.207 - - [12/Jun/2014 11:15:57] "POST /v1/images HTTP/1.1" 400 238 0.159937
Created attachment 908006 [details] Glance api.log
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. http://rhn.redhat.com/errata/RHEA-2014-0851.html
Cancelling old needinfo request.