Skip to content

Instantly share code, notes, and snippets.

@ffund
Created April 4, 2022 01:55
Show Gist options
  • Save ffund/4a2b04f957a5f5bee206563f16717286 to your computer and use it in GitHub Desktop.
Save ffund/4a2b04f957a5f5bee206563f16717286 to your computer and use it in GitHub Desktop.
iface=$(ifconfig | grep -B1 "inet 10.10.1.1" | head -n1 | cut -f1 -d:)
sudo tc qdisc del dev $iface root
sudo tc qdisc add dev $iface root handle 1: htb default 3
sudo tc class add dev $iface parent 1: classid 1:3 htb rate $1
sudo tc qdisc add dev $iface parent 1:3 handle 3: pfifo limit 100
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment