AMiLDA FORUM

You are not logged in.

Announcement

### Our Homepage is down at the moment...work in progress !! ###

#1 2007-02-14 21:30:44

artworx
Member
Romania
Registered: 2006-06-15
Last visit: 2008-06-07
Posts: 21

limit download speed for 1 ip

So i've found this little snippet of code:

Code::

DEV='eth0'
tc qdisc add dev $DEV root handle 1: cbq avpkt 1000 bandwidth 768kbit
tc class add  dev $DEV parent 1: classid 1:1 cbq rate 100kbit allot 1500 =
prio 5 bounded isolated
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip dst =
192.168.0.2 flowid 1:1

but the problem is that after the first line i get this error:

Code::

# tc qdisc add dev eth0 root handle 1: cbq avpkt 1000 bandwidth 768kbit  
RTNETLINK answers: Invalid argument

The same code works on my desktop machine.

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2008 PunBB