Skip to contentSkip to conversation

IpTables question...

DISCUSSION Curca Claudiu 2 participants 2 messages Feb 3, 2003 – Feb 6, 2003

lore
Share & tools
lore
#0 lore raw

I'm using RedHat Linux 8.0 on an PIII - Coppermine 750 MHz. I used Iptables for NAT networking at my home (5 PC's + 1 Server). The server is used as a gateway and dns server. My question is:

Is there any way I could limit the transfer rate of the inside computers to the internet? For example I want 192.168.3.5 to have a limit of 5 KB/s transfer rate.

Please help me!!

_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail

#1 lore raw
Quoted 10 lines · Curca Claudiu

I'm using RedHat Linux 8.0 on an PIII - Coppermine 750 MHz. I used Iptables for NAT networking at my home (5 PC's + 1 Server). The server is used as a gateway and dns server. My question is:

Is there any way I could limit the transfer rate of the inside computers to the internet?
For example I want 192.168.3.5 to have a limit of 5 KB/s transfer rate.

Please help me!!

You need to establish a Queueing Discipline. Your best choice would probably be Hierarchical Token Bucket. See
http://lartc.org/howto/lartc.qdisc.classful.html#AEN1050 in the Linux Advanced Routing and Traffic Control how-to for details on HTB, (and the full how-to for all the info...) and the section following it entitled "Classifying packets with filters" which explains how to specify a filter that matches specific IPs, or use the 'fwmark' match to let you set a mark in an iptables mangle-table PREROUTING chain and queue traffic based on the marks.

j