Created attachment 852761 [details] api log Description of problem: I set user_storage_quota = 2 in /etc/glance/glance-api.conf and tried to create an image with --copy-from: [root@cougar07 tmp(keystone_admin)]# echo '>>>>>>>' >> /var/log/glance/api.log [root@cougar07 tmp(keystone_admin)]# glance image-create --name dafna2 --disk-format qcow2 --container-format bare --copy-from http://download.eng.tlv.redhat.com/pub/rhel/released/RHEL-6/6.4/Appliance/rhel-workstation-x86_64-ec2-starter-6.4_20130130.0-1-sda.raw +------------------+--------------------------------------+ | Property | Value | +------------------+--------------------------------------+ | checksum | None | | container_format | bare | | created_at | 2014-01-20T13:56:13 | | deleted | False | | deleted_at | None | | disk_format | qcow2 | | id | 858ae6af-d9e1-4e24-9193-b85955aa0597 | | is_public | False | | min_disk | 0 | | min_ram | 0 | | name | dafna2 | | owner | d4aaa7c237054d408a65f40bb4ee74d0 | | protected | False | | size | 6442450945 | | status | queued | | updated_at | 2014-01-20T13:56:13 | +------------------+--------------------------------------+ [root@cougar07 tmp(keystone_admin)]# less /var/log/glance/api.log there is no error logged in the glance.api log (as you can see the >>>> I added in echo before running the create command - no error related to this issue is logged). Stderr: '/bin/sh: collie: command not found\n' 2014-01-20 13:41:25.844 7946 WARNING glance.store.base [-] Failed to configure store correctly: Store sheepdog could not be configured correctly. Reason: Error in store configuration: Unexpected error while running command. Command: collie Exit code: 127 Stdout: '' Stderr: '/bin/sh: collie: command not found\n' Disabling add method. 2014-01-20 13:41:25.883 7946 WARNING glance.store.base [-] Failed to configure store correctly: Store cinder could not be configured correctly. Reason: Cinder storage requires a context. Disabling add method. >>>>>>> Version-Release number of selected component (if applicable): python-glance-2013.2.1-3.el6ost.noarch python-glanceclient-0.12.0-1.el6ost.noarch openstack-glance-2013.2.1-3.el6ost.noarch How reproducible: 100% Steps to Reproduce: 1. set user_storage_quota = 2 in /etc/glance/glance-api.conf 2. create an image with --copy-from 3. look at the api.log or egrep image from /var/log/*/* Actual results: we do not have any error logged. Expected results: we should have an error logged Additional info: my setup is set from 4 server with a stand alone glance/cinder and 2 computes. with glusterfs configured for cinder.
mmh, this is strange: @Jon FYI: you may want to look here: API v1: https://github.com/openstack/glance/blob/master/glance/api/v1/upload_utils.py#L213 API v2 Looks like a log line is missing here: https://github.com/openstack/glance/blob/master/glance/quota/__init__.py#L276
The failure is now logged but it's logged as INFO: 2014-09-12 18:54:58.921 21663 INFO glance.api.common [-] User 2bcd197108b44efe84f3c5a19d40a716 attempted to upload an image of size 6442450945 that will exceeed the quota. 2 bytes remaining. 2014-09-12 18:54:58.923 21663 INFO glance.api.v1.upload_utils [-] Denying attempt to upload image because it exceeds the .quota: The size of the data 6442450945 will exceed the limit. 2 bytes remaining. 2014-09-12 18:55:01.980 21671 INFO urllib3.connectionpool [-] Starting new HTTP connection (1): 10.35.160.123 2014-09-12 18:55:02.152 21671 INFO glance.wsgi.server [25188ae9-2a1d-4791-b6ba-23051cb90e8b 2bcd197108b44efe84f3c5a19d40a716 8f8749df409d4bbab5d982384b0d6ab0 - - -] 10.35.160.123 - - [12/Sep/2014 18:55:02] "GET /v1/images/detail?sort_key=name&sort_dir=asc&limit=20 HTTP/1.1" 200 671 0.175247 However speaking to Flavio, we do not log user errors as errors and only software errors should be logged as ERRORs.
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/RHSA-2014-1337.html