All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brent Clark <bclark@eccotours.dyndns.org>
To: iptables <netfilter@lists.netfilter.org>
Subject: port 80 out new ISP
Date: Fri, 19 Aug 2005 17:55:16 +0200	[thread overview]
Message-ID: <430600E4.3090004@eccotours.dyndns.org> (raw)

Hi all

For a few days now I have been struggling to get my HTTP traffic across my new ISP.

I currently have been reading the following doc.

http://linux-ip.net/html/adv-multi-internet.html

and have changed my scripts accordingly.

But for some reason, it still dont work

my setup is as so

firewall:
eth0 196.36.10.114    -> Routes traffic to old ISP
eth1 192.168.111.10    -> Private Lan
eth2 192.168.10.100    -> for ADSL

Adsl modem:
ipaddress: 192.168.10.200 (external ip dynamically assigned)


## Create the table
ip route flush table TELKOM  >>/dev/null
ip route show table main |grep -Ev ^default\
   | while read ROUTE ; do
     ip route add table TELKOM $ROUTE
  done

## Add the ADSL as route to route table 4

ip route add default via 192.168.10.200 dev eth2 table TELKOM >>/dev/null

## Add the route to table TELKOM

ip rule add fwmark 1 table TELKOM >> /dev/null
gate:~#


$IPT -t nat -A PREROUTING -i eth1 -t mangle -p tcp --dport 80 -j MARK --set-mark 1
$IPT -t nat -A PREROUTING -i eth1 -t mangle -p tcp --dport 443 -j MARK --set-mark 1

# SNAT the Private LAN
$IPT -t nat -A POSTROUTING -o eth0 -s 192.168.111.0/24 -j SNAT --to-source 196.36.10.114
#$IPT -t nat -A POSTROUTING -o eth2 -s 192.168.111.0/24 -j SNAT --to-source 192.168.10.200
$IPT -t nat -A POSTROUTING -o eth2 -s 192.168.111.0/24 -j MASQUERADE



             reply	other threads:[~2005-08-19 15:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-19 15:55 Brent Clark [this message]
2005-08-19 17:05 ` port 80 out new ISP /dev/rob0
2005-08-19 17:22   ` Brent Clark
2005-08-19 18:05   ` Brent Clark
2005-08-20  0:00     ` Robert Nichols
2005-08-20  9:51       ` Brent Clark
2005-08-21  9:19   ` Jan Engelhardt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=430600E4.3090004@eccotours.dyndns.org \
    --to=bclark@eccotours.dyndns.org \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.