Menu

#11 Shapper outgoing band using MASQ IP (part 2 ;) )

open
nobody
None
5
2003-07-18
2003-07-18
Anonymous
No

I will try to share some test I made here!

I'm using Redhat... I tried in 7.3/8.0 and 9.0 versions
and all of them has the same problem.

My computer is a Athlon XP2000+/2 x 3Com 3c905BTX
cards/Asus A7N266 motherboard/256mb DDR/ Kernel
2.4.9, 2.4.18-9 and 2.4.20....

First I configured my interfaces with NAT'ed ip address...
like

200.200.200.200 (for example) --- eth0 (linux) eth1 ----
- 192.168.1.1

iptables -A POSTROUTING -t nat -o eth0 -j MASQUERADE

CBQ version 0.72 and Download shapping works fine...
and upload was not shaped... (yes! I configured corretly
with "," at end of RULE in cbq config file).

After many tests..... I tested using valid IP Address...

200.200.200.200 --- eth0 (linux) eth1 200.200.201.1 ---
-- 200.200.201.2 (notebook workstation)

And upload works fine!!!

Well... After many many many many tests ;) When
iptables with nat command is executed the CBQ is not
shaping bandwidth of upload connections..... Even if the
notebook use the valid IP... just execute iptables -t
nat... and upload shape stops work.

I'm thinking that this problem is with tc and not with
CBQ...

Anyone has the same problem??? Anyone has any
solution?
Sorry for my bad english...

Fernando Braghetto
webmaster@hiway.com.br

Discussion

  • Nobody/Anonymous

    Logged In: NO

    I have this problem too.

    Vitor Carvalho
    vitor@pig.com.br

     
  • Rumen Nachev

    Rumen Nachev - 2004-04-03

    Logged In: YES
    user_id=409171

    Hi,
    put these:

    iptables -t nat -A POSTROUTING -s 192.168.1.
    0/24 -o eth0 -j MASQUERADE

    NOT:

    iptables -A POSTROUTING -t nat -o eth0 -j MASQUERADE

     
  • Ventsislav Genchev

    Logged In: YES
    user_id=1010275

    same as Request ID: 964549

    you just can't shape the local ip's upload after the network
    address translation.... if you try to shape the server's ip
    address you'll see that it works... cuz the local addresses
    are going out with the server's ip address...

     
  • Nobody/Anonymous

    Logged In: NO

    The solution is not so hard. I wrote short howto for you at
    this address:
    http://www.netpro.co.yu/cbqnat.html

     
  • guille4

    guille4 - 2005-05-01

    Logged In: YES
    user_id=1270318

    Hi guys, if u kernel 2.4 you can use rshaper.o in conjunction
    with cbq.init

    ;-)

     
  • Nobody/Anonymous

    Logged In: NO

    well,, trying to shape servers ip doesn't work.
    the problem is:
    I want to limit just some [200 :) ] ports, witch uses only
    the server itself.

    NAT should be left unlimited. well, this shaper should
    limit the system, it is running on..

    soft, that is installed: iptables, cbqinit.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.