← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1364246] [NEW] Instance snapshot is "successfully created" but fails due to Glance quota

 

Public bug reported:

Description of problem:  Horizon's instance snapshot notification
process is flawed. Process completion should be reported at the end of
the process, meaning snapshot is created plus uploaded successfully to
Glance. Maybe this is what happens but due to Glance quota the
snapshot's status = "deleted" and it's later deleted, meaning no
snapshot for instance.

Version-Release number of selected component (if applicable):
RHEL6
python-django-horizon-2014.1.2-1.el6ost.noarch


How reproducible:
Every time

Steps to Reproduce:
1. Edit Glance config (/etc/glance/glance-api.conf)
 debug=True
 user_storage_quota=xxxx
Restart Glance service. 

2. Upload image(s) so that Glance quota is almost full.
3. launch an instance from one of the images.
4. Create a snapshot of the instance, you will notice Horizon mentions it's created successfully. 
5. Check Glance images you may momentarily see snapshot being created with status "deleted" but it will be removed due to quota being breached.
6. On Glance's api.log you will see something like:

2014-09-02 09:49:24.262 3464 INFO glance.api.common [f1400ea8-37b1-4eb0-9cbc-a7a3f41b88ce 23b10b101af14a96b21d895c1a2f7602 d392e844a4e44d03908770c4b4338cb4 - - -] User 23b10b101af14a96b21d895c1a2f7602 attempted to upload an image of size 19333120 that will exceeed the quota. 10497152 bytes remaining.
2014-09-02 09:49:24.263 3464 INFO glance.api.v1.upload_utils [f1400ea8-37b1-4eb0-9cbc-a7a3f41b88ce 23b10b101af14a96b21d895c1a2f7602 d392e844a4e44d03908770c4b4338cb4 - - -] Denying attempt to upload image because it exceeds the .quota: The size of the data 19333120 will exceed the limit. 10497152 bytes remaining.
   

Actual results:
Nova creates temp snapshot file it's uploaded to Glance, but due to Glance's quota being maxed out the snapshot is deleted. Horizon pop up reports instance snapshot as  "successfully created.." but no snapshot image is left on Glance.

Expected results:
If for any reason the end result in this case an instance's snapshot image isn't created to the full expected outcome, an alert or error should be returned rather than a misleading and wrong "successfully created.." notification. It would be nice if error could give details like "Snapshot failed due to Glance quota being breached". 

Maybe the problem is with Glance work flow, but wrong end result is
reported by Horizon.

** Affects: horizon
     Importance: Undecided
         Status: New

** Attachment added: "Horizon and Glance logs"
   https://bugs.launchpad.net/bugs/1364246/+attachment/4192985/+files/logs.tar.gz

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1364246

Title:
  Instance snapshot is "successfully created" but fails due to Glance
  quota

Status in OpenStack Dashboard (Horizon):
  New

Bug description:
  Description of problem:  Horizon's instance snapshot notification
  process is flawed. Process completion should be reported at the end of
  the process, meaning snapshot is created plus uploaded successfully to
  Glance. Maybe this is what happens but due to Glance quota the
  snapshot's status = "deleted" and it's later deleted, meaning no
  snapshot for instance.

  Version-Release number of selected component (if applicable):
  RHEL6
  python-django-horizon-2014.1.2-1.el6ost.noarch

  
  How reproducible:
  Every time

  Steps to Reproduce:
  1. Edit Glance config (/etc/glance/glance-api.conf)
   debug=True
   user_storage_quota=xxxx
  Restart Glance service. 

  2. Upload image(s) so that Glance quota is almost full.
  3. launch an instance from one of the images.
  4. Create a snapshot of the instance, you will notice Horizon mentions it's created successfully. 
  5. Check Glance images you may momentarily see snapshot being created with status "deleted" but it will be removed due to quota being breached.
  6. On Glance's api.log you will see something like:

  2014-09-02 09:49:24.262 3464 INFO glance.api.common [f1400ea8-37b1-4eb0-9cbc-a7a3f41b88ce 23b10b101af14a96b21d895c1a2f7602 d392e844a4e44d03908770c4b4338cb4 - - -] User 23b10b101af14a96b21d895c1a2f7602 attempted to upload an image of size 19333120 that will exceeed the quota. 10497152 bytes remaining.
  2014-09-02 09:49:24.263 3464 INFO glance.api.v1.upload_utils [f1400ea8-37b1-4eb0-9cbc-a7a3f41b88ce 23b10b101af14a96b21d895c1a2f7602 d392e844a4e44d03908770c4b4338cb4 - - -] Denying attempt to upload image because it exceeds the .quota: The size of the data 19333120 will exceed the limit. 10497152 bytes remaining.
     

  Actual results:
  Nova creates temp snapshot file it's uploaded to Glance, but due to Glance's quota being maxed out the snapshot is deleted. Horizon pop up reports instance snapshot as  "successfully created.." but no snapshot image is left on Glance.

  Expected results:
  If for any reason the end result in this case an instance's snapshot image isn't created to the full expected outcome, an alert or error should be returned rather than a misleading and wrong "successfully created.." notification. It would be nice if error could give details like "Snapshot failed due to Glance quota being breached". 

  Maybe the problem is with Glance work flow, but wrong end result is
  reported by Horizon.

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1364246/+subscriptions


Follow ups

References