Update RAM quota from Dashboard increases it by 100 times

Bug #882604 reported by Rafael Durán Castañeda
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
Critical
Devin Carlen

Bug Description

Hi,

While working on Dashboard I tried to update quotas from "system panel", but after doing that I noticed that I could overpass RAM quota. After checking Nova database I found that RAM quota was increased by 100 times (it seems the database stores the value as MB while dashboard sends a value in KB). After updating it directly on database quota checking was working properly again, but Dashboard shows quota divided by 100 (so, it expects KBs back from the database instead of MB). Looking at code from:

django-openstack/django_openstack/dash/views/images.py
django-openstack/django_openstack/syspanel/views/tenants.py

I've found that Dashboard code explicitly multiply/divide by 100, but Nova doesn't, so updating quotas from Dashboard breaks RAM quota checking.

I've attached a patch that seems to fix the bug.

Bye

Revision history for this message
Rafael Durán Castañeda (rafadurancastaneda) wrote :
Devin Carlen (devcamcar)
Changed in horizon:
status: New → Confirmed
importance: Undecided → Critical
assignee: nobody → Devin Carlen (devcamcar)
milestone: none → essex-1
Devin Carlen (devcamcar)
Changed in horizon:
status: Confirmed → Fix Committed
Devin Carlen (devcamcar)
Changed in horizon:
status: Fix Committed → Fix Released
Jeremy Stanley (fungi)
information type: Private Security → Public
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.