openstack-manuals/doc/user-guide-admin/source/cli_cinder_quotas.rst
Brant Knudson 147068841a Use openstack rather than keystone
The keystone command is deprecated and should be not used in the
examples. The openstack command is the replacement.

The openstack command has handy options for extracting fields
so some of the commands were simplified.

The openstack command can use names when creating role
assignments and since this is more user-friendly the examples
were changed to use names rather than IDs.

Change-Id: Ic118284183001d10322cf357314672c5d98856a3
2015-07-12 13:51:36 +00:00

3.1 KiB

Manage Block Storage service quotas

As an administrative user, you can update the OpenStack Block Storage service quotas for a project. You can also update the quota defaults for a new project.

Block Storage quotas

Property name Defines the number of

gigabytes

Volume gigabytes allowed for each tenant.

snapshots

Volume snapshots allowed for each tenant.

volumes

Volumes allowed for each tenant.

View Block Storage quotas

Administrative users can view Block Storage service quotas.

  1. List the default quotas for all projects:

    $ cinder quota-defaults TENANT_ID
    +-----------+-------+
    |  Property | Value |
    +-----------+-------+
    | gigabytes |  1000 |
    | snapshots |   10  |
    |  volumes  |   10  |
    +-----------+-------+
  2. View Block Storage service quotas for a project:

    $ cinder quota-show TENANT_NAME

    For example:

    $ cinder quota-show tenant01
    +-----------+-------+
    |  Property | Value |
    +-----------+-------+
    | gigabytes |  1000 |
    | snapshots |   10  |
    |  volumes  |   10  |
    +-----------+-------+
  3. Show the current usage of a per-tenant quota:

    $ cinder quota-usage tenantID
    +-----------+--------+----------+-------+
    |    Type   | In_use | Reserved | Limit |
    +-----------+--------+----------+-------+
    | gigabytes |   0    |    0     |  1000 |
    | snapshots |   0    |    0     |   10  |
    |  volumes  |   0    |    0     |   15  |
    +-----------+--------+----------+-------+

Edit and update Block Storage service quotas

Administrative users can edit and update Block Storage service quotas.

  1. Clear per-tenant quota limits:

    $ cinder quota-delete tenantID
  2. To update a default value for a new project, update the property in the cinder.quota section of the /etc/cinder/cinder.conf file. For more information, see the Block Storage Configuration Reference.

  3. To update Block Storage service quotas, place the tenant ID in a variable:

    $ tenant=$(openstack project show -f value -c id tenantName)
  4. Update a particular quota value:

    $ cinder quota-update --quotaName NewValue tenantID

    For example:

    $ cinder quota-update --volumes 15 $tenant
    $ cinder quota-show tenant01
    +-----------+-------+
    |  Property | Value |
    +-----------+-------+
    | gigabytes |  1000 |
    | snapshots |   10  |
    |  volumes  |   15  |
    +-----------+-------+
  5. Clear per-tenant quota limits:

    $ cinder quota-delete tenantID