setting manila quota raises db error

Bug #1908352 reported by Paul Ali
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Low
Paul Ali

Bug Description

Setting any manila quota with a value greater than 2147483647 raises oslo_db.exception.DBDataError: (pymysql.err.DataError) which is communicated to the user as ERROR: The server has either erred or is incapable of performing the requested operation. (HTTP 500).

This is understandable given the mariadb integer limit of 2147483647.However, a more descriptive error should be communicated to the user as when a share quota that is less than -1 is being set.A more descriptive error message is reported to the user :
ERROR: Quota limit must be -1 or greater. (HTTP 400)

Steps to reproduce:

manila quota-update %share_id% --snapshots 10000000000

Actual Result:
ERROR: The server has either erred or is incapable of performing the requested operation. (HTTP 500) (Request-ID: req-1d03200b-623e-4ef8-a7d6-cfcdef01b98f)

Logs for manila API service
http://paste.openstack.org/show/801076/

Revision history for this message
Tom Barron (tpb) wrote :

Thanks for finding this bug, Paul. I confirmed it. Are you planning on submitting a fix yourself?

Changed in manila:
status: New → Confirmed
importance: Undecided → Low
milestone: none → wallaby-2
Revision history for this message
Paul Ali (paulali) wrote :

You are welcome Tom.I have assigned it to myself.I will work on it and submit a fix.

Changed in manila:
assignee: nobody → Paul Ali (paulali)
Paul Ali (paulali)
Changed in manila:
status: Confirmed → In Progress
Changed in manila:
milestone: wallaby-2 → wallaby-3
Changed in manila:
milestone: wallaby-3 → wallaby-rc1
tags: added: wallaby-rc-bugsquash
Revision history for this message
Goutham Pacha Ravi (gouthamr) wrote :

Fix proposed to branch: master
    https://review.opendev.org/782856

Changed in manila:
milestone: wallaby-rc1 → xena-1
tags: removed: wallaby-rc-bugsquash
Changed in manila:
milestone: xena-1 → xena-2
Revision history for this message
Vida Haririan (vhariria) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.opendev.org/c/openstack/manila/+/782856
Committed: https://opendev.org/openstack/manila/commit/daf7b3aacf1481c967db4706e7cfa7be09976c52
Submitter: "Zuul (22348)"
Branch: master

commit daf7b3aacf1481c967db4706e7cfa7be09976c52
Author: paulali <email address hidden>
Date: Wed Mar 24 20:39:05 2021 +0000

    Adds a clear error message to operator-set limits

    When an operator sets a limit that is greater than 2147483647, an
    explicit error message "Quota limit should not exceed 2147483647"
    is communicated. This is better than the initial error message
    which was "ERROR: The server has either erred or is
    incapable of performing the requested operation. (HTTP 500)."

    Closes-Bug: #1908352
    Change-Id: I0d301c5f527c3e16e14021b679c85bd51833a1d6

Changed in manila:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/manila/+/798882

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/manila/+/798882
Committed: https://opendev.org/openstack/manila/commit/2a6325951967c7dda52cb9c8beccd78e1cfb0605
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit 2a6325951967c7dda52cb9c8beccd78e1cfb0605
Author: paulali <email address hidden>
Date: Wed Mar 24 20:39:05 2021 +0000

    Adds a clear error message to operator-set limits

    When an operator sets a limit that is greater than 2147483647, an
    explicit error message "Quota limit should not exceed 2147483647"
    is communicated. This is better than the initial error message
    which was "ERROR: The server has either erred or is
    incapable of performing the requested operation. (HTTP 500)."

    Closes-Bug: #1908352
    Change-Id: I0d301c5f527c3e16e14021b679c85bd51833a1d6
    (cherry picked from commit daf7b3aacf1481c967db4706e7cfa7be09976c52)

tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 13.0.0.0rc1

This issue was fixed in the openstack/manila 13.0.0.0rc1 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 12.1.0

This issue was fixed in the openstack/manila 12.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to manila (master)

Related fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/manila/+/820952

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to manila (master)

Reviewed: https://review.opendev.org/c/openstack/manila/+/820952
Committed: https://opendev.org/openstack/manila/commit/021e7ab02f30ae45c1ad20c5493c973d709fcd3e
Submitter: "Zuul (22348)"
Branch: master

commit 021e7ab02f30ae45c1ad20c5493c973d709fcd3e
Author: Goutham Pacha Ravi <email address hidden>
Date: Tue Dec 7 14:14:32 2021 -0800

    Move db release note to correct folder

    This change must be backported to stable/wallaby
    as well.

    Change-Id: I6d4f2cc263fc7dd099ce27e674709baf3916ea9b
    Related-Bug: #1908352
    Signed-off-by: Goutham Pacha Ravi <email address hidden>

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.