SSH Match does not work?
Hi there,
I tried dport, sport, changed priority but everytime I look into the classes with #tc -s class ls dev eth1, there is no SSH traffic going
in?? (see below script)
Stef: Remeber my last post : [LARTC]4 Users no Bandwidth Borrowing ?
Do you think that this script gives the user 10.3.0.4 & 10.3.0.5 only 8k ? no more no less
no borrowing?
I put CEIL to the same amount as Rate. I only want that they dont get borrowed any bandwidth.
Can you help me?
Thanls. Osgaldo
#!/bin/sh
#tc qdisc del dev eth1 root
#tc qdisc add dev eth1 root handle 1: htb
#tc class add dev eth1 parent 1: classid 1:1 htb rate 23kbps ceil 23kbps #tc class add dev eth1 parent 1:1 classid 1:10 htb rate 8kbps ceil 8kbps #tc class add dev eth1 parent 1:1 classid 1:11 htb rate 8kbps ceil 8kbps #tc class add dev eth1 parent 1:1 classid 1:12 htb rate 4kbps ceil 4kbps #tc class add dev eth1 parent 1:1 classid 1:13 htb rate 3kbps ceil 3kbps #tc filter add dev eth1 protocol ip parent 1:0 prio 2 u32 match ip dst 10.3.0.4 flowid 1:10
#tc filter add dev eth1 protocol ip parent 1:0 prio 2 u32 match ip dst 10.3.0.5 flowid 1:11
#tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip sport 80 0xffff flowid 1:12
#tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip dport 22 0xffff flowid 1:13
# tc -s class ls dev eth1 class htb 1:11 parent 1:1 prio 0 rate 64Kbit ceil 64Kbit burst 1680b cburst 1680b Sent 0 bytes 0 pkts (dropped 0, overlimits 0) lended: 0 borrowed: 0 giants: 0 tokens: 168099 ctokens: 168099
class htb 1:1 root rate 184Kbit ceil 184Kbit burst 1834b cburst 1834b
Sent 4261 bytes 16 pkts (dropped 0, overlimits 0)
rate 62bps
lended: 0 borrowed: 0 giants: 0
tokens: 60209 ctokens: 60209
class htb 1:10 parent 1:1 prio 0 rate 64Kbit ceil 64Kbit burst 1680b cburst 1680b
Sent 585 bytes 9 pkts (dropped 0, overlimits 0)
rate 13bps
lended: 9 borrowed: 0 giants: 0
tokens: 157701 ctokens: 157701
class htb 1:13 parent 1:1 prio 0 rate 24Kbit ceil 24Kbit burst 1629b cburst 1629b
Sent 0 bytes 0 pkts (dropped 0, overlimits 0)
lended: 0 borrowed: 0 giants: 0
tokens: 434665 ctokens: 434665
class htb 1:12 parent 1:1 prio 0 rate 32Kbit ceil 32Kbit burst 1639b cburst 1639b
Sent 3676 bytes 7 pkts (dropped 0, overlimits 0)
lended: 7 borrowed: 0 giants: 0
tokens: -129853 ctokens: -129853
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 6 lines · Osgaldo Suanzes
Hi there,
I tried dport, sport, changed priority but everytime I look into the classes with #tc -s class ls dev eth1, there is no SSH traffic
going in?? (see below script)
Quoted 8 lines
Stef: Remeber my last post : [LARTC]4 Users no Bandwidth Borrowing ?
Do you think that this script gives the user 10.3.0.4 & 10.3.0.5 only 8k ? no more no less
no borrowing?
I put CEIL to the same amount as Rate. I only want that they dont get borrowed any bandwidth.
Can you help me?
An ssh connection is going to port 22. The return data is coming from port
22. So you have to use sport 22 just like you did in the http filter. Your tc commands are ok.
Stef
Signature · 8 lines
[email protected] "Using Linux as bandwidth manager" http://www.docum.org/ #lartc @ irc.oftc.net _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/