File: basic-volume-qos.rst

package info (click to toggle)
cinder 2%3A27.0.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 44,028 kB
  • sloc: python: 496,072; pascal: 2,230; sh: 394; makefile: 104; xml: 26
file content (94 lines) | stat: -rw-r--r-- 2,750 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
===============================
Basic volume quality of service
===============================

Basic volume QoS allows you to define hard performance limits for volumes
on a per-volume basis.

Performance parameters for attached volumes are controlled using volume types
and associated extra-specs.

As of the 13.0.0 Rocky release, Cinder supports the following options to
control volume quality of service, the values of which should be fairly
self-explanatory:

For Fixed IOPS per volume.

* `read_iops_sec`
* `write_iops_sec`
* `total_iops_sec`

For Burst IOPS per volume.

* `read_iops_sec_max`
* `write_iops_sec_max`
* `total_iops_sec_max`

For Fixed bandwidth per volume.

* `read_bytes_sec`
* `write_bytes_sec`
* `total_bytes_sec`

For Burst bandwidth per volume.

* `read_bytes_sec_max`
* `write_bytes_sec_max`
* `total_bytes_sec_max`

For burst bucket size.

* `size_iops_sec`

Note that the `total_*` and `total_*_max` options for both iops and bytes
cannot be used with the equivalent `read` and `write` values.

For example, in order to create a QoS extra-spec with 20000 read IOPs and
10000 write IOPs, you might use the Cinder client in the following way:

.. code-block:: console

   $ cinder qos-create high-iops consumer="front-end" \
     read_iops_sec=20000 write_iops_sec=10000
   +----------+--------------------------------------+
   | Property | Value                                |
   +----------+--------------------------------------+
   | consumer | front-end                            |
   | id       | f448f61c-4238-4eef-a93a-2024253b8f75 |
   | name     | high-iops                            |
   | specs    | read_iops_sec : 20000                |
   |          | write_iops_sec : 10000               |
   +----------+--------------------------------------+

The equivalent OpenStack client command would be:


.. code-block:: console

   $ openstack volume qos create --consumer "front-end" \
     --property "read_iops_sec=20000" \
     --property "write_iops_sec=10000" \
     high-iops

Once this is done, you can associate this QoS with a volume type by using
the `qos-associate` Cinder client command.

.. code-block:: console

   $ cinder qos-associate QOS_ID VOLUME_TYPE_ID

or using the `openstack volume qos associate` OpenStack client command.

.. code-block:: console

   $ openstack volume qos associate QOS_ID VOLUME_TYPE_ID

You can now create a new volume and attempt to attach it to a consumer such
as Nova.  If you login to the Nova compute host, you'll be able to see the
assigned limits when checking the XML definition of the virtual machine
with `virsh dumpxml`.

.. note::

   As of the Nova 18.0.0 Rocky release, front end QoS settings are only
   supported when using the libvirt driver.