LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 11-27-2006, 11:18 AM   #1
danrfxz
LQ Newbie
 
Registered: May 2004
Posts: 12

Rep: Reputation: 0
IpTables forwarding port 25


Hi,

I need to forward (though "bounce" may be a better word) all traffic on port 25 to another server. The machine with iptables only has 1 NIC, so it's sending the traffic out on the same interfacer it came in on. Anybody know how to do this? I'm new to iptables and linux in general. Thanks!!
 
Old 11-27-2006, 12:05 PM   #2
amitsharma_26
Member
 
Registered: Sep 2005
Location: New delhi
Distribution: RHEL 3.0/4.0
Posts: 777

Rep: Reputation: 31
Code:
iptables -t nat -A PREROUTING -p tcp --dport 25 -j DNAT --to OTHERBOX-IP
& configure otherbox to have this box as its GATEWAY.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IPCHAINS port forwarding and IPTABLES port forwarding ediestajr Linux - Networking 26 01-14-2007 07:35 PM
iptables don't do port forwarding gomen Linux - Networking 4 12-26-2005 03:05 PM
Iptables -- Port Forwarding slack_baby Linux - Networking 3 06-03-2004 02:29 PM
IPTABLES and port forwarding freibuis Linux - Networking 5 04-21-2004 09:06 PM
Iptables w/port forwarding claytonj25 Linux - Security 8 12-22-2001 08:30 AM


All times are GMT -5. The time now is 02:57 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration