Results 1 to 7 of 7
I'm trying to redirect all traffic going to a certain IP to an internal IP. I think think can be done using iptables.
for example I want all traffic destined ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 02-08-2005 #1Just Joined!
- Join Date
- Feb 2005
- Posts
- 3
redirect using iptables
I'm trying to redirect all traffic going to a certain IP to an internal IP. I think think can be done using iptables.
for example I want all traffic destined to 216.239.37.99 to go to an internal web server 192.168.1.150
any ideas?
Thanks
John
- 02-08-2005 #2Linux Engineer
- Join Date
- Nov 2004
- Location
- Montreal, Canada
- Posts
- 1,267
Here's a great web site that you need to have a look at... It'll give you all the required info about forwading IP request
Please hit me back if you require more information\"Meditative mind\'s is like a vast ocean... whatever strikes the surface, the bottom stays calm\" - Dalai Lama
\"Competition ultimatly comes down to one thing... a loser and a winner.\" - Ugo Deschamps
- 02-08-2005 #3Just Joined!
- Join Date
- Feb 2005
- Posts
- 3
That is a great site, but unfortunately I couldnt find what I'm looking for. I'm not sure if I worded my question correctly. What I'm trying to do is stop all outgoing requests to only specific IP on the web all other request I would like it to pass thru. When there is a request going to one specific IP-I want it redirected to an internal web site.
- 02-14-2005 #4Just Joined!
- Join Date
- Feb 2005
- Posts
- 3
---bump---
anyone???
- 02-14-2005 #5Linux Newbie
- Join Date
- Feb 2005
- Posts
- 129
- 09-13-2008 #6Just Joined!
- Join Date
- Sep 2008
- Posts
- 1
you people are morons
why do you think it neccessary to fill the internet with misinformation about how to perform a ceratin action?
he wants to redirect outgoing traffic to an internal machine. this has NOTHING to do with NAT or masquerading. you people have no idea what you're talking about about. you post replies thinking that you are helping someone when in reality you are polluting search engines with ridiculous answers. the individual who replied with IP FORWARDING in all uppercase has absolutely no understanding of IP, let alone the netfilter implementations in linux 2.4+.
a word to all those amateur computer WHIZZARDS! out there -- don't say ANYTHING unless you can back it up with solid information.
what you want is the PREROUTING chain for the nat table:
iptalbes -t nat -A PREROUTING -d 216.239.37.99 \
-p tcp --dport 80 -j DNAT --to 192.168.1.150
- 09-13-2008 #7
HI punkpulse !
This thread is more than three years old. I dont think thread starter needs any help after such a long time.
I would suggest you post suggestion in a bit recent threads.It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First



