HTB + NAT on Debian (outgoing traffic shaping problems)

From: Laurynas Butkus (lauris_at_night.lt)
Date: 05/12/04


Date: 12 May 2004 05:17:27 -0700

hello,

I'm running Debian Woody with 2.4.26 kernel. I have 3 NIC:
eth0 - 192.168.0.0 subnet
eth1 - 192.168.2.0 subnet
eth2 - DSL link

there are ~5 computers in every subnet and I want them to get equal
incoming and outgoing traffic with possibility to borrow unused
channel.

I have successfully used htb.init to shape my incoming traffic but I
ran into problems with outgoing. I try to mark outgoing packets with
iptables, but it doesn't work...

I do marking like this:
iptables -t mangle -A PREROUTING -s 192.168.2.10 -j MARK --set-mark
101

then NAT:
$IPT -t nat -A POSTROUTING -s $FRIEND -j SNAT --to $IP_BLUE

then in sysconfig:

cat ./eth2
DEFAULT=2

cat ./eth2-2.root
# root class containing total bandwidth
RATE=320Kbit
MTU=300

cat ./eth2-2\:101.madcrock
RATE=1Kbit
MARK=101
LEAF=sfq

I try to shape myself down to 1Kbit but during upload I get 2 and more
Kb/s...
Please help me to solve this problem.

Thanks in advance,
Laurynas



Relevant Pages

  • Re: HTB + NAT on Debian (outgoing traffic shaping problems)
    ... > 192.168.0.0 subnet ... > incoming and outgoing traffic with possibility to borrow unused channel. ... get it's packets from its associated queue. ...
    (comp.os.linux.networking)
  • Re: HACMP persistent IP address and default route based on service address
    ... I think your problem might be related to the way aix creates outgoing ... alternate between these when making outgoing connections, ... "...in AIX 5.1 multiple interfaces can have a route to the same subnet. ...
    (comp.unix.aix)
  • RE: Cross-domain browsing
    ... are replicated to all WINS servers. ... 136712 Common Questions About Browsing with Windows ... >linked using RRAS VPN demand-dial connection and each is in its own subnet. ... >correctly in both domains and for computers in either domain. ...
    (microsoft.public.win2000.networking)
  • Re: Networks
    ... Verify that the IPs exist on the same subnet by looking at the subnet ... After you are able to Ping by IP, you can try to Ping by Name. ... > How can i create a network with two windows xp machines? ... > computers on, when one of them is in windows, it says ...
    (microsoft.public.windowsxp.network_web)
  • Re: Puzzling Subnet Browsing Issue with ISA 2004
    ... ISA not letting through queries on ports 137-139? ... > subnet cannot browse computers on another subnet within the lan. ... The client computers can see all the other machines in ...
    (microsoft.public.isaserver)