aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
Diffstat (limited to 'main')
-rw-r--r--main/iproute2-qos/APKBUILD2
-rw-r--r--main/iproute2-qos/qos.initd22
2 files changed, 12 insertions, 12 deletions
diff --git a/main/iproute2-qos/APKBUILD b/main/iproute2-qos/APKBUILD
index bb0b27a6f3..2d3c3b8f6f 100644
--- a/main/iproute2-qos/APKBUILD
+++ b/main/iproute2-qos/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Ilya Strelkin <iilluzion@gmail.com>
# Maintainer: Ilya Strelkin <iilluzion@gmail.com>
pkgname=iproute2-qos
-pkgver=0.3
+pkgver=0.4
pkgrel=0
pkgdesc="Scripts to set up quality of service with iproute2"
url="http://git.alpinelinux.org/cgit/aports"
diff --git a/main/iproute2-qos/qos.initd b/main/iproute2-qos/qos.initd
index 9986a8cce4..09677353a9 100644
--- a/main/iproute2-qos/qos.initd
+++ b/main/iproute2-qos/qos.initd
@@ -225,11 +225,11 @@ set_filters()
set_htb()
{
$ECHO tc qdisc add dev $DEV root handle 1 htb default 60
- $ECHO tc class add dev $DEV parent 1: classid 1:2 htb rate $DEV_RATE
- $ECHO tc class add dev $DEV parent 1:2 classid 1:30 htb rate $WAN_SUB_RATE
- $ECHO tc class add dev $DEV parent 1:30 classid 1:40 htb rate $INTERACTIVE_RATE prio 1
- $ECHO tc class add dev $DEV parent 1:30 classid 1:50 htb rate $PRIVILEGED_RATE ceil $WAN_SUB_RATE prio 3
- $ECHO tc class add dev $DEV parent 1:30 classid 1:60 htb rate $BESTEFFORT_RATE ceil $WAN_SUB_RATE prio 6
+ $ECHO tc class add dev $DEV parent 1: classid 1:2 htb rate $DEV_RATE burst $(($DEV_RATE*5/4))
+ $ECHO tc class add dev $DEV parent 1:2 classid 1:30 htb rate $WAN_SUB_RATE burst $(($WAN_SUB_RATE*5/4))
+ $ECHO tc class add dev $DEV parent 1:30 classid 1:40 htb rate $INTERACTIVE_RATE ceil $WAN_SUB_RATE prio 1
+ $ECHO tc class add dev $DEV parent 1:30 classid 1:50 htb rate $PRIVILEGED_RATE ceil $WAN_SUB_RATE prio 3 burst $(($WAN_SUB_RATE*5/4))
+ $ECHO tc class add dev $DEV parent 1:30 classid 1:60 htb rate $BESTEFFORT_RATE ceil $WAN_SUB_RATE prio 6 burst $(($WAN_SUB_RATE*5/4))
if [ $OUT_OF_WAN_RATE -gt 0 ]; then
$ECHO tc class add dev $DEV parent 1:2 classid 1:70 htb rate $OUT_OF_WAN_RATE prio 7
@@ -250,7 +250,7 @@ set_hfsc()
$ECHO tc qdisc add dev $DEV root handle 1 hfsc default 60
$ECHO tc class add dev $DEV parent 1: classid 1:2 hfsc sc rate $DEV_RATE ul rate $DEV_RATE
$ECHO tc class add dev $DEV parent 1:2 classid 1:30 hfsc sc rate $WAN_SUB_RATE ul rate $WAN_SUB_RATE
- $ECHO tc class add dev $DEV parent 1:30 classid 1:40 hfsc sc umax $INTERACTIVE_HFSC_UMAX dmax $INTERACTIVE_HFSC_DMAX rate $INTERACTIVE_RATE ul rate $INTERACTIVE_RATE
+ $ECHO tc class add dev $DEV parent 1:30 classid 1:40 hfsc sc umax $INTERACTIVE_HFSC_UMAX dmax $INTERACTIVE_HFSC_DMAX rate $INTERACTIVE_RATE ul rate $WAN_SUB_RATE
$ECHO tc class add dev $DEV parent 1:30 classid 1:50 hfsc sc umax $PRIVILEGED_HFSC_UMAX dmax $PRIVILEGED_HFSC_DMAX rate $PRIVILEGED_RATE ul rate $WAN_SUB_RATE
$ECHO tc class add dev $DEV parent 1:30 classid 1:60 hfsc sc rate $BESTEFFORT_RATE ul rate $WAN_SUB_RATE
@@ -272,7 +272,7 @@ set_prio()
{
PARENT_CLASSID=10
$ECHO tc qdisc add dev $DEV root handle 1 prio bands 2 priomap 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 # by default unclassified traffic goes to flowid 1:2
- $ECHO tc qdisc add dev $DEV parent 1:1 handle 40: tbf rate $INTERACTIVE_RATE burst $INTERACTIVE_PRIO_BURST latency $INTERACTIVE_PRIO_LATENCY
+ $ECHO tc qdisc add dev $DEV parent 1:1 handle 40: tbf rate $INTERACTIVE_RATE burst $WAN_SUB_RATE latency $INTERACTIVE_PRIO_LATENCY
$ECHO tc qdisc add dev $DEV parent 1:2 handle $PARENT_CLASSID: htb default 60
$ECHO tc class add dev $DEV parent $PARENT_CLASSID: classid $PARENT_CLASSID:30 htb rate $WAN_SUB_RATE
$ECHO tc class add dev $DEV parent $PARENT_CLASSID:30 classid $PARENT_CLASSID:50 htb rate $PRIVILEGED_RATE ceil $WAN_SUB_RATE prio 3
@@ -309,7 +309,7 @@ set_police()
# burst = rate / 17 (taken basing on experemental results)
POLICE_BURST_SCALE=17
- WAN_POLICE_BURST=$((WAN_RATE / POLICE_BURST_SCALE))
+ WAN_POLICE_BURST=$((WAN_RATE / POLICE_BURST_SCALE))
WAN_POLICE_FLOWID=1
@@ -329,9 +329,9 @@ set_cpolice()
# burst = rate / 17 (taken basing on experemental results)
POLICE_BURST_SCALE=17
- INTERACTIVE_POLICE_BURST=$((INTERACTIVE_RATE / POLICE_BURST_SCALE))
- PRIVILEGED_POLICE_BURST=$((PRIVILEGED_RATE / POLICE_BURST_SCALE))
- BESTEFFORT_POLICE_BURST=$((BESTEFFORT_RATE / POLICE_BURST_SCALE))
+ INTERACTIVE_POLICE_BURST=$((INTERACTIVE_RATE / POLICE_BURST_SCALE))
+ PRIVILEGED_POLICE_BURST=$((PRIVILEGED_RATE / POLICE_BURST_SCALE))
+ BESTEFFORT_POLICE_BURST=$((BESTEFFORT_RATE / POLICE_BURST_SCALE))
CLASS_TYPES="INTERACTIVE PRIVILEGED"
INTERACTIVE_POLICE_FLOWID=1