Re: LARTC Digest, Vol 20, Issue 4

Linux Advanced Routing and Traffic Control

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

 



Hi,

I think you now have 2 Links to the internet. You want to route web traffic (transparent proxy triffic) via one link and the rest via the other link.

If it is the case, It is possible to do. I have done it.


here I have mentioned eth0 and eth1
eth0 is connected to one link (link1)
eth1 is connected to other link (link2) , via this link, web traffic will be routed.


echo 210 link1 >> /etc/iproute2/rt_tables
echo 211 link2 >> /etc/iproute2/rt_tables

ip route add ipaddressofonegateway dev eth0 table link1
ip route add default via
ipaddressofonegateway dev eth0 table link1

ip route add
ipaddressoftheohtergateway dev eth1 table link2
ip route add default via
ipaddressoftheohtergateway dev eth1 table link2

iptables -t mangle -A OUTPUT -p tcp --dport 80 -j MARK --set-mark 1

ip rule add fwmark 1 pri 100 table link2

iptables -t nat -o eth1 -j SNAT --to-source ipaddressofeh1

echo 0 > /proc/sys/net/ipv4/conf/eth1/rp_filter

ip rule add from ipaddressofeth0 pri 200 table link1
ip rule add from ipaddressofeth1 pri 300 table link2

that's it.

and also , you can reffer to this URL

http://www.debian-administration.org/articles/379



On 10/4/06, lartc-request@xxxxxxxxxxxxxxx < lartc-request@xxxxxxxxxxxxxxx> wrote:
Send LARTC mailing list submissions to
        lartc@xxxxxxxxxxxxxxx

To subscribe or unsubscribe via the World Wide Web, visit
         http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
or, via email, send a message with subject or body 'help' to
        lartc-request@xxxxxxxxxxxxxxx

You can reach the person managing the list at
         lartc-owner@xxxxxxxxxxxxxxx

When replying, please edit your Subject line so it is more specific
than "Re: Contents of LARTC digest..."


Today's Topics:

   1. Cant get transparent proxy to route out new ISP. (Brent Clark)
   2. ipp2p not work in iptables-1.3.6  (sonu chouhan)


----------------------------------------------------------------------

Message: 1
Date: Tue, 03 Oct 2006 13:49:00 +0200
From: Brent Clark <bclark@xxxxxxxxxxxxxxx>
Subject: Cant get transparent proxy to route out new ISP.
To: lartc@xxxxxxxxxxxxxxx
Message-ID: < 45224E2C.9050503@xxxxxxxxxxxxxxx>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Hi all

Could someone please me with my current setup.

I just got another DSL line and I have my routing  and marking the packets etc so that I can decided the fate as to which ISP I would like to route my
traffic out of etc.

I managed to get squid to be used as a trasparent proxy, but im forced to use the default gw of the machine and for the likes of my I cant figure out to
send traffic out the new ISP.

So my question / request for help is, Would anyone please advise me as to how I can choose what ISP I can route my transparent proxy.

I was thinking that maybe it is a POSTROUTING marking that I need to do, and the the routing tables will take care of the rest.

Kinds Regards and thank you in advance.

Brent Clark




------------------------------

Message: 2
Date: Tue, 3 Oct 2006 10:18:15 -0700 (PDT)
From: sonu chouhan < hi100nu@xxxxxxxxx>
Subject: ipp2p not work in iptables-1.3.6
To: lartc@xxxxxxxxxxxxxxx
Message-ID: < 20061003171815.54564.qmail@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
Content-Type: text/plain; charset="iso-8859-1"

hi all,
  I had compiled iptables 1.3.6 on my redhat enterprises linux-4 box with kernel 2.6.16.17, but in this setup ipp2p-0.8.2 not working after upgrade of iptables from 1.3.5 to 1.3.6, so plz help me out.
  thanks in advance

  sonu...


---------------------------------
Do you Yahoo!?
Get on board. You're invited to try the new Yahoo! Mail.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ds9a.nl/pipermail/lartc/attachments/20061003/6c311ee8/attachment.html

------------------------------

_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc


End of LARTC Digest, Vol 20, Issue 4
************************************



--
Thank you
Indunil Jayasooriya
_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux