summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatteo Croce2008-03-08 17:00:33 +0000
committerMatteo Croce2008-03-08 17:00:33 +0000
commitf329a1581d2edf65565b8bbfd952d1862681cf65 (patch)
tree83b7ecbd7086889ede6769168dcd1f19e7d58dc0
parent77d0acc42c1e89cd53d902ba79f0f517171526e7 (diff)
downloadarchive-f329a1581d2edf65565b8bbfd952d1862681cf65.tar.gz
added module (un)load to wshaper
SVN-Revision: 10570
-rwxr-xr-xnet/wshaper/files/wshaper.htb14
1 files changed, 14 insertions, 0 deletions
diff --git a/net/wshaper/files/wshaper.htb b/net/wshaper/files/wshaper.htb
index 2600d4398e..d912f4dcaf 100755
--- a/net/wshaper/files/wshaper.htb
+++ b/net/wshaper/files/wshaper.htb
@@ -5,6 +5,7 @@
# Set the following values to somewhat less than your actual download
# and uplink speed. In kilobits. Also set the device that is to be shaped.
+MODULES='sch_ingress sch_sfq sch_htb cls_u32'
DOWNLINK=2000
UPLINK=240
DEV=eth0
@@ -29,10 +30,23 @@ then
exit
fi
+
# clean existing down- and uplink qdiscs, hide errors
tc qdisc del dev $DEV root 2> /dev/null > /dev/null
tc qdisc del dev $DEV ingress 2> /dev/null > /dev/null
+if [ "$1" = "stop" ]
+then
+ for i in $MODULES ; do
+ rmmod $i
+ done
+ exit
+fi
+
+for i in $MODULES ; do
+ insmod $i
+done
+
###### uplink
# install root HTB, point default traffic to 1:20: