Skip to content

Commit

Permalink
docs: add gateway qos doc
Browse files Browse the repository at this point in the history
  • Loading branch information
oilbeater committed Jul 10, 2020
1 parent 352f1e8 commit 4b8faed
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ kind-init:
kind delete cluster --name=kube-ovn
kind create cluster --config yamls/kind-single.yaml --name kube-ovn
kind load docker-image --name kube-ovn ${REGISTRY}/kube-ovn:${RELEASE_TAG}
kubectl taint node kube-ovn-control-plane node-role.kubernetes.io/master:NoSchedule-
bash dist/images/install.sh

kind-init-ha:
Expand Down
25 changes: 24 additions & 1 deletion docs/qos.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# QoS

Kube-OVN supports dynamically configurations of Ingress and Egress traffic rate limiting.
Kube-OVN supports dynamically configurations of Ingress and Egress traffic rate limiting for a single pod level and gateway level.

## Pod QoS
Use the following annotations to specify QoS:
- `ovn.kubernetes.io/ingress_rate`: Rate limit for Ingress traffic, unit: Mbit/s
- `ovn.kubernetes.io/egress_rate`: Rate limit for Egress traffic, unit: Mbit/s
Expand All @@ -22,3 +23,25 @@ spec:
- name: qos
image: nginx:alpine
```

## Gateway QoS
*This feature is still in master branch*

Kube-OVN will create an `ovn0` interface on each host to route traffic from cluster pod network
to external network. Kube-OVN control gateway QoS by modify the QoS config of `ovn0` interface.

For a subnet with central gateway mode, only one node act as the gateway, so you can modify the
node QoS annotation to control the QoS of the subnet to external network.

```bash
apiVersion: v1
kind: Node
metadata:
annotations:
ovn.kubernetes.io/ingress_rate: "3"
ovn.kubernetes.io/egress_rate: "1"
name: liumengxin-ovn1-192.168.16.44
```

You can also use this annotation to control the traffic from each node to external network
through these annotations.

0 comments on commit 4b8faed

Please sign in to comment.