# Networking Quality Of Service QoS Configuration

The networking Quality of Service (QoS) configuration feature in <code class="expression">space.vars.product\_name</code> enables you to provide different networking service levels for your virtual machines. By using quality of service (QoS) policies, you can apply rate limits to egress and ingress traffic, and do similar networking QoS operations.

You can apply QoS policies to individually to ports. You can also apply QoS policies to a tenant network. When you do this, ports with no specific policy attached will inherit the network level QoS policy.

### QoS Rules

The QoS policies in <code class="expression">space.vars.product\_name</code> allow you to define following rules:

* `bandwidth_limit`: Provides bandwidth limitations on networks, ports or public (floating) IPs. If implemented, any traffic that exceeds the specified rate is dropped.
* `minimum_bandwidth`: Provides minimum bandwidth constraints on certain types of traffic. If implemented, best efforts are made to provide no less than the specified bandwidth to each port on which the rule is applied.
* `dscp_marking`: Marks network traffic with a Differentiated Services Code Point (DSCP) value.

### Configure and Apply QoS Policies

Create a QoS policy:

```bash
pcdctl network qos policy create --share --project <project_ID> <policy_name>
```

Create new rules for the QoS policy:

```bash
pcdctl network qos rule create --type <rule-type> [rule properties] <policy_name>
```

Apply the policy to a port

```bash
pcdctl port set --qos-policy <policy_name> <port_name|port_ID>
```

Apply the policy to a network

```bash
pcdctl network set --qos-policy <policy_name> <network_name|network_ID>
```

### QoS Rule Properties

Following table describes the various rule policies you can specify when creating QoS rules.

| Policy           | Description                                                                                                                                                                                                                                                                                                                                                 |
| ---------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| max\_kbps        | The maximum rate (in Kbps) that the VM can send.                                                                                                                                                                                                                                                                                                            |
| max\_burst\_kbps | <p>The maximum amount of data (in kbits) that the port can send in an VM if the token buffer is full. The token buffer replenishes at a "max\_kbps" rate.</p><p>The burst value for TCP traffic can be set as 80% of desired bandwidth limit value. For example, if the bandwidth limit is set to 1000kbps then a burst value of 800kbps is sufficient.</p> |
| min-kbps         | The minimum bandwidth (in Kbps) guaranteed to a VM.                                                                                                                                                                                                                                                                                                         |
| ingress/egress   | The direction of traffic the rule is applied to. From the perspective of a VM, ingress indicates download, and egress indicates upload.                                                                                                                                                                                                                     |
| dscp-mark        | Specifies the decimal value of a DSCP mark.                                                                                                                                                                                                                                                                                                                 |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.platform9.com/private-cloud-director/virtualized-networking/networking-quality-of-service-qos-configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
