[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: limit traffic based on IPs



On Mon, Aug 12, 2013 at 4:28 AM, binary dreamer
<dreamer.binary@gmail.com> wrote:
> stuck big time with the syntax of an iptable.
> i would like to permit the speed of 512/512kbps to ips 192.168.1.2-5
> i would like to permit the speed of 1024/1024kbps to ips 192.168.1.6-10
> i would like to permit the speed of 2048/2048kbps to ips 192.168.1.11-12
> the rest of the ips will set to free traffic

Basically what you want to do is 'mark' the packet with iptables (it's
a kernel flag) and then 'handle' it with tc. Just a quick google
(though tc if fairly complex and has a tree like structure which you
might want to read about):
http://www.linuxquestions.org/questions/linux-networking-3/iptables-mark-combine-with-tc-382100/


Reply to: