View previous topic :: View next topic |
Author |
Message |
knoxville Tux's lil' helper
Joined: 04 Mar 2003 Posts: 96
|
Posted: Thu Oct 02, 2003 10:59 am Post subject: problem with qos script |
|
|
hello, im using the qos script from c`t but now i have the problem that it also slows down samba transfers to the hosts im throttling the internet bandwidth to
heres the part of the code
Code: |
###########
# Incoming
###########
/sbin/tc qdisc add dev $INTIF root handle 2:0 htb default 20
/sbin/tc class add dev $INTIF parent 2:0 classid 2:2 htb rate 100mbit ceil 100mbit
/sbin/tc class add dev $INTIF parent 2:2 classid 2:20 htb rate 100mbit ceil 100mbit prio 1
/sbin/tc class add dev $INTIF parent 2:2 classid 2:21 htb rate 150kbit ceil 750kbit prio 0
/sbin/tc class add dev $INTIF parent 2:2 classid 2:22 htb rate 32kbit ceil 32kbit prio 3
# ACKs
iptables -A POSTROUTING -t mangle -o $INTIF -m length --length :200 -j MARK --set-mark 21
# SSH
iptables -A POSTROUTING -t mangle -o $INTIF -p tcp --sport 22 -j MARK --set-mark 21
# eDonkey
iptables -A POSTROUTING -t mangle -o $INTIF -p tcp --dport 4662 -j MARK --set-mark 22
iptables -A POSTROUTING -t mangle -o $INTIF -p tcp --sport 4662 -j MARK --set-mark 22
# clients to throttle
iptables -A POSTROUTING -t mangle -o $INTIF -d 192.168.111.216 -j MARK --set-mark 22
|
i want that even the throttled clients can still use the intranet at full speed (borrow from another class?)
thanks for your inputs |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Fri Oct 03, 2003 1:02 am Post subject: |
|
|
I am confused....
knoxville wrote: | [...]the problem that it also slows down samba transfers to the hosts im throttling the internet bandwidth to |
knoxville wrote: | i want that even the throttled clients can still use the intranet at full speed (borrow from another class?) |
So you want to throttle Samba or the Internet? |
|
Back to top |
|
|
knoxville Tux's lil' helper
Joined: 04 Mar 2003 Posts: 96
|
Posted: Fri Oct 03, 2003 6:26 am Post subject: |
|
|
devon wrote: | I am confused....
knoxville wrote: | [...]the problem that it also slows down samba transfers to the hosts im throttling the internet bandwidth to |
knoxville wrote: | i want that even the throttled clients can still use the intranet at full speed (borrow from another class?) |
So you want to throttle Samba or the Internet? |
ok i want to throttle the intErnet but if i do so, also the intRAnet gets throttled
sorry for confusing you |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Sat Oct 04, 2003 6:15 pm Post subject: |
|
|
My bad, I didn't read closely enough.
Are all the machines in the same subnet? Is the server doing the tc throttling also the samba server? |
|
Back to top |
|
|
knoxville Tux's lil' helper
Joined: 04 Mar 2003 Posts: 96
|
Posted: Tue Oct 07, 2003 6:46 am Post subject: |
|
|
devon wrote: | My bad, I didn't read closely enough.
Are all the machines in the same subnet? Is the server doing the tc throttling also the samba server? |
yes its all done on the same machine, sorry for my late reply |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Tue Oct 07, 2003 4:30 pm Post subject: |
|
|
It seems to me that since the same server is doing the throttling and serving the samba shares, the "iptables -A POSTROUTING -t mangle -o $INTIF -d 192.168.111.216 -j MARK --set-mark 22" line will rate-limit both the Internet and intranet. Wouldn't this work to rate-limit Internet connections?
Code: | iptables -A POSTROUTING -t mangle -o $INTIF -d 192.168.111.216 -s !IP_OF_SERVER -j MARK --set-mark 22 |
|
|
Back to top |
|
|
knoxville Tux's lil' helper
Joined: 04 Mar 2003 Posts: 96
|
Posted: Wed Oct 08, 2003 8:07 am Post subject: |
|
|
devon wrote: | It seems to me that since the same server is doing the throttling and serving the samba shares, the "iptables -A POSTROUTING -t mangle -o $INTIF -d 192.168.111.216 -j MARK --set-mark 22" line will rate-limit both the Internet and intranet. Wouldn't this work to rate-limit Internet connections?
Code: | iptables -A POSTROUTING -t mangle -o $INTIF -d 192.168.111.216 -s !IP_OF_SERVER -j MARK --set-mark 22 |
|
ahhh thanks a lot man it worked like a charm! why didnt i get this idea dammit thanks again |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Thu Oct 09, 2003 7:07 am Post subject: |
|
|
knoxville wrote: | ahhh thanks a lot man it worked like a charm! why didnt i get this idea dammit thanks again |
No problem. Glad I could help. |
|
Back to top |
|
|
|