Linux Netfilter discussions
 help / color / mirror / Atom feed
From: "P theodorou" <props666999@hotmail.com>
To: netfilter@lists.netfilter.org
Subject: RE: DNAT failure
Date: Sat, 05 Nov 2005 09:49:26 +0000	[thread overview]
Message-ID: <BAY102-F220B61B66765771DA5831EAE630@phx.gbl> (raw)
In-Reply-To: <BAY102-F32CE5F4C40CDF72DAE41DBAE600@phx.gbl>

I have noticed that DNAT works whenever redirect to eth1 but not eth2
like here

$IPTABLES -t nat -A PREROUTING -p tcp  -i eth0  --dport 80 \
-j DNAT --to-destination  192.168.0.4   (eth1)


but when i try
$IPTABLES -t nat -A PREROUTING -p tcp  -i eth0  --dport 80 \
-j DNAT --to-destination  192.168.1.4 (eth2)




>From: "P theodorou" <props666999@hotmail.com>
>To: netfilter@lists.netfilter.org
>Subject: DNAT failure Date: Fri, 04 Nov 2005 21:30:32 +0000
>
>Hello
>
>I  face problem with DNAT  this is my testing script
>
>INET_IP="84.9.x.x"
>INET_IFACE="eth0"
>
>LAN_IP="192.168.0.1"
>LAN_IFACE="eth1"
>DMZ_HTTP_IP="192.168.0.4"
>
>
>O_IFACE="lo"
>LO_IP="127.0.0.1"
>
>
>IPTABLES="/usr/sbin/iptables"
>
>
>/sbin/depmod -a
>
>
>
>
>/sbin/modprobe ip_tables
>/sbin/modprobe ip_conntrack
>/sbin/modprobe iptable_filter
>/sbin/modprobe iptable_mangle
>/sbin/modprobe iptable_nat
>/sbin/modprobe ipt_LOG
>/sbin/modprobe ipt_limit
>/sbin/modprobe ipt_state
>
>
>
>echo "1" > /proc/sys/net/ipv4/ip_forward
>
>
>
>$IPTABLES -P INPUT ACCEPT
>$IPTABLES -P OUTPUT ACCEPT
>$IPTABLES -P FORWARD ACCEPT
>
>
>
>$IPTABLES -t nat -A PREROUTING -p tcp  -d $INET_IP --dport 80 \
>-j DNAT --to-destination $DMZ_HTTP_IP
>
>
>
>$IPTABLES -t nat -A POSTROUTING -o $INET_IFACE -j SNAT --to-source $INET_IP
>
>
>
>i do not  have a clue what the problem  but whenever i type
>the real ip on the browser i get error page doesn't exist .
>
>any hint would be really appreciated
>
>
>




      reply	other threads:[~2005-11-05  9:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-04 21:30 DNAT failure P theodorou
2005-11-05  9:49 ` P theodorou [this message]

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=BAY102-F220B61B66765771DA5831EAE630@phx.gbl \
    --to=props666999@hotmail.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox