Creating QoS policies

Prerequisites

To create a QoS policy with rules

  1. Create a QoS policy:

  2. Create a rule for the QoS policy:

    • To create a bandwidth limit, specify bandwidth-limit for the --type option and specify rule parameters. For example, to limit the egress traffic to 3 Mbps, run:

      # openstack --insecure network qos rule create --type bandwidth-limit \
      --max-kbps 3000 --max-burst-kbits 2400 --egress policy1
      +----------------+--------------------------------------------------+
      | Field          | Value                                            |
      +----------------+--------------------------------------------------+
      | direction      | egress                                           |
      | id             | 6f036f09-d952-420d-986b-27c7eb14b2da             |
      | location       | Munch({'project': Munch({'domain_name': Default, |
      |                | 'domain_id': None, 'name': admin,                |
      |                | 'id': u'e215189c0472482f93e71d10e1245253'}),     |
      |                | 'cloud': '', 'region_name': '', 'zone': None})   |
      | max_burst_kbps | 2400                                             |
      | max_kbps       | 3000                                             |
      | name           | None                                             |
      | project_id     |                                                  |
      +----------------+--------------------------------------------------+
    • To create a minimum bandwidth guarantee, specify minimum-bandwidth for the --type option and specify rule parameters. For example, to guarantee the minimum of 100 Kbps to the ingress traffic, run:

      # openstack --insecure network qos rule create --type minimum-bandwidth \
      --min-kbps 1000 --ingress policy1
      +------------+--------------------------------------------------+
      | Field      | Value                                            |
      +------------+--------------------------------------------------+
      | direction  | ingress                                          |
      | id         | 4eb79c67-e2b7-4ee7-845c-4cbe39f095cd             |
      | location   | Munch({'project': Munch({'domain_name': Default, |
      |            | 'domain_id': None, 'name': admin,                |
      |            | 'id': u'e215189c0472482f93e71d10e1245253'}),     |
      |            | 'cloud': '', 'region_name': '', 'zone': None})   |
      | min_kbps   | 1000                                             |
      | name       | None                                             |
      | project_id |                                                  |
      +------------+--------------------------------------------------+