Files
zpericic 86a0d2cdd1 Initial import of qos-profiles
Role subpackages set the system-wide default qdisc and TCP congestion
control via /usr/lib/sysctl.d, without pulling in the base package:

  server   fq + bbr        bare metal, VM guests
  vmhost   fq_codel + bbr  hypervisors, container hosts
  router   fq_codel + cubic
  desktop  fq_codel + cubic

The base package applies cake per interface from
/etc/qos-profiles/<iface>.conf, layered over role defaults and
/etc/qos-profiles/defaults.conf:

- LINK_RATE with per-direction overrides, shaped to SHAPE_PERCENT
  (default 95, per direction overridable)
- outbound fairness per source host and diffserv4; inbound via ifb,
  fairness per destination host, besteffort with DSCP wash
- NAT awareness, extra cake args (shared and per direction), raw
  qdisc overrides
- config parsed without executing it, validated before any change,
  previous state undone on each run

Applied by the qos-profiles@<iface> unit (bound to the device) or the
qos-profiles-networkmanager dispatcher subpackage, installed
automatically on hosts with NetworkManager. Includes ready-made
examples for VM hosts, OVH dual-NIC servers, DC and home routers.
2026-10-10 22:41:12 +02:00

51 lines
2.0 KiB
Plaintext

# qos-profiles interface configuration, all variables. Ready-made setups are
# in /usr/share/qos-profiles/examples/.
# Copy to /etc/qos-profiles/<iface>.conf. Applied by the NetworkManager
# dispatcher when the interface comes up, or without NetworkManager by:
# systemctl enable --now qos-profiles@<iface>
#
# Defaults come from the installed role package (/usr/lib/qos-profiles/) and
# /etc/qos-profiles/defaults.conf. Use a physical NIC: bond and VLAN devices
# have no queue of their own.
# Full link rate in both directions (bit, kbit, mbit, gbit, tbit).
# Cake shapes to SHAPE_PERCENT of it.
#LINK_RATE=1gbit
# Per-direction link rates, override LINK_RATE.
# EGRESS_RATE: "unlimited" = cake without shaping (default without LINK_RATE,
# fine while the NIC line rate is the bottleneck), "none" = off
# INGRESS_RATE: "none" = no inbound shaping (default without LINK_RATE)
#EGRESS_RATE=100mbit
#INGRESS_RATE=none
# Percentage of the link rate to shape to, so the queue builds here and not
# in the upstream equipment. Per-direction values override SHAPE_PERCENT.
#SHAPE_PERCENT=95
#EGRESS_SHAPE_PERCENT=95
#INGRESS_SHAPE_PERCENT=90
# DiffServ classes: besteffort, diffserv3, diffserv4, diffserv8, precedence.
# Inbound marks come from the internet, so they're ignored by default and
# cleared before forwarding (INGRESS_WASH=yes).
#DIFFSERV=diffserv4
#INGRESS_DIFFSERV=besteffort
#INGRESS_WASH=yes
# Fairness per host behind NAT on this machine (yes/no).
#NAT=no
# Extra cake options for both directions: link overhead (ethernet, pppoe-ptm,
# docsis, ...), rtt, or a different fairness mode (flows, triple-isolate, ...).
# Per-direction options are added after CAKE_ARGS.
#CAKE_ARGS="ethernet"
#EGRESS_CAKE_ARGS="ack-filter"
#INGRESS_CAKE_ARGS=""
# ifb device for inbound shaping, default ifb-<iface> (max 15 characters).
#IFB=ifb-wan
# Raw qdisc specs; when set, replace everything above for that direction.
#EGRESS="fq_codel target 3ms"
#INGRESS="cake besteffort dual-dsthost ingress bandwidth 450mbit"