Limit bandwidth of guest wlan

Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking
Author Message
PaddyW
DD-WRT Novice


Joined: 25 Nov 2009
Posts: 36
Location: germany/nrw/

PostPosted: Thu Aug 14, 2014 10:39    Post subject: Limit bandwidth of guest wlan Reply with quote
Hey there,
I followed the Kong Guest Wifi Setup Tutorial for setting up a guest wlan.

Here's the Link:
http://tips.desipro.de/2013/12/06/guest-wifi-setup-dd-wrt/

Is there any way to limit the bandwidth for this virtual interface?
For example: I want 75% of my available bandwidth for my own wlan, and 25% for the guest wlan Twisted Evil. I would like to prevent, that guest's download huge files and prevent best speeds for my own wireless network Laughing.

Kind regards,
Patrick
Sponsor
jfish99
DD-WRT User


Joined: 25 Aug 2011
Posts: 112

PostPosted: Thu Aug 14, 2014 15:12    Post subject: Reply with quote
Here you go - you need to modify the subnet and allocated bandwidth

Code:


TCA="tc class add dev br1"
TFA="tc filter add dev br1"
TQA="tc qdisc add dev br1"
SFQ="sfq perturb 10"
tc qdisc del dev br1 root
tc qdisc add dev br1 root handle 1: htb
tc class add dev br1 parent 1: classid 1:1 htb rate 1024kbit
$TQA parent 1:1 handle 10: $SFQ
$TFA parent 1:0 prio 2 protocol ip handle 10 fw flowid 1:1
iptables -t mangle -A POSTROUTING -d 192.168.200.0/24 -j MARK --set-mark 10
TCAU="tc class add dev imq0"
TFAU="tc filter add dev imq0"
TQAU="tc qdisc add dev imq0"
insmod imq
insmod ipt_IMQ
ip link set imq0 up
tc qdisc del dev imq0 root
tc qdisc add dev imq0 root handle 1: htb
tc class add dev imq0 parent 1: classid 1:1 htb rate 512kbit
$TQAU parent 1:1 handle 10: $SFQ
$TFAU parent 1:0 prio 2 protocol ip handle 10 fw flowid 1:1
iptables -t mangle -A PREROUTING -s 192.168.200.0/24 -j MARK --set-mark 10
iptables -t mangle -A PREROUTING -j IMQ --todev 0

PaddyW
DD-WRT Novice


Joined: 25 Nov 2009
Posts: 36
Location: germany/nrw/

PostPosted: Thu Aug 14, 2014 15:37    Post subject: Reply with quote
Thank you!

Seems like I have to do some homework now.
Thought this could be a checkbox thing or two lines of code Embarassed
Mile-Lile
DD-WRT Guru


Joined: 24 Feb 2013
Posts: 1634
Location: Belgrade

PostPosted: Fri Aug 15, 2014 9:37    Post subject: Reply with quote
Don't use that generator it is outdated, and it will probably not work correct. Use GUI instead. See picture below. If your internet connection is hosted on that router then use wan up/down to limit users, or if you use router in wds sta or client bridge mode than use LAN limitting cause WAN is disabled in that case...
Mile-Lile
DD-WRT Guru


Joined: 24 Feb 2013
Posts: 1634
Location: Belgrade

PostPosted: Fri Aug 15, 2014 9:42    Post subject: Reply with quote
Or, you can do it like this, it is much better:)
PaddyW
DD-WRT Novice


Joined: 25 Nov 2009
Posts: 36
Location: germany/nrw/

PostPosted: Fri Aug 15, 2014 10:34    Post subject: Reply with quote
Thank you very much!
2chp
DD-WRT Novice


Joined: 10 Jun 2015
Posts: 25

PostPosted: Thu Jun 11, 2015 13:48    Post subject: Reply with quote
Hi,

In the example image, netmask would you place the guest IP in there and then the main SSID IP?

Thanks
drk
DD-WRT Novice


Joined: 19 Mar 2015
Posts: 23

PostPosted: Sun Oct 04, 2015 17:09    Post subject: Reply with quote
As discussed in other topics script works for downloads only.
GUI method gave me opposite result - it works for uploads only.
Tried with Netmask Priority only, tried with other settings filled - upload only is limided.
Played with Enable Per User Default Limits - the same, uploads only.
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum