Networking Forums

Networking Forums > Computer Networking > Linux Networking > routing from the outside in

Reply
Thread Tools Display Modes

routing from the outside in

 
 
Mike Dixon
Guest
Posts: n/a

 
      11-12-2003, 02:44 PM
Can somebody point me to a simple howto on getting a redhat 9 box on the
internal network seen from the outside on port 80?

INTERNET
|
\/
ippp0
REDHAT 7.3 (2.2 kernel)
eth0
|
\/
INTERNAL NETWORK
INCLUDING RH9 BOX (192.168.0.150)

Many thanks in advance
Mike Dixon


 
Reply With Quote
 
 
 
 
Dragan Colak
Guest
Posts: n/a

 
      11-12-2003, 04:10 PM
On Wed, 12 Nov 2003 14:44:18 +0000, Mike Dixon wrote:

> Can somebody point me to a simple howto on getting a redhat 9 box on the
> internal network seen from the outside on port 80?
>
> INTERNET
> |
> \/
> ippp0
> REDHAT 7.3 (2.2 kernel)
> eth0
> |
> \/
> INTERNAL NETWORK
> INCLUDING RH9 BOX (192.168.0.150)
>
> Many thanks in advance
> Mike Dixon


You have to forward your router's port 80 to the internal box. You want to
use iptables for that. My rule for that looks like this:

iptables -A PREROUTING -t nat -p tcp -i $EXT_INTERFACE --dport 80 \
-j DNAT --to 192.168.0.150:80

For more help take at look at 'man iptables'.

Dragan

 
Reply With Quote
 
Leslie Cox
Guest
Posts: n/a

 
      11-13-2003, 03:23 AM

"Dragan Colak" <(E-Mail Removed)> wrote in message
news(E-Mail Removed)...
> On Wed, 12 Nov 2003 14:44:18 +0000, Mike Dixon wrote:
>
> > Can somebody point me to a simple howto on getting a redhat 9 box on the
> > internal network seen from the outside on port 80?
> >
> > INTERNET
> > |
> > \/
> > ippp0
> > REDHAT 7.3 (2.2 kernel)
> > eth0
> > |
> > \/
> > INTERNAL NETWORK
> > INCLUDING RH9 BOX (192.168.0.150)
> >
> > Many thanks in advance
> > Mike Dixon

>
> You have to forward your router's port 80 to the internal box. You want to
> use iptables for that. My rule for that looks like this:
>
> iptables -A PREROUTING -t nat -p tcp -i $EXT_INTERFACE --dport 80 \
> -j DNAT --to 192.168.0.150:80
>
> For more help take at look at 'man iptables'.
>
> Dragan
>

Hi Dragan
I too have the same problem as Mike, but when I tried your fix I got this
answer:
Warning weird character in interface '--dport' (No aliases, :, ! or * ). bad
argument '80'
Any ideas would be welcome.
Leslie Cox.


 
Reply With Quote
 
Llanzlan Klazmon The 15th
Guest
Posts: n/a

 
      11-13-2003, 04:40 AM
"Leslie Cox" <(E-Mail Removed)> wrote in
newsOCsb.31000$Ws6.6302@edtnps84:

>
> "Dragan Colak" <(E-Mail Removed)> wrote in message
> news(E-Mail Removed)...
>> On Wed, 12 Nov 2003 14:44:18 +0000, Mike Dixon wrote:
>>
>> > Can somebody point me to a simple howto on getting a redhat 9 box
>> > on the internal network seen from the outside on port 80?
>> >
>> > INTERNET
>> > |
>> > \/
>> > ippp0
>> > REDHAT 7.3 (2.2 kernel)
>> > eth0
>> > |
>> > \/
>> > INTERNAL NETWORK
>> > INCLUDING RH9 BOX (192.168.0.150)
>> >
>> > Many thanks in advance
>> > Mike Dixon

>>
>> You have to forward your router's port 80 to the internal box. You
>> want to use iptables for that. My rule for that looks like this:
>>
>> iptables -A PREROUTING -t nat -p tcp -i $EXT_INTERFACE --dport 80 \
>> -j DNAT --to 192.168.0.150:80
>>
>> For more help take at look at 'man iptables'.
>>
>> Dragan
>>

> Hi Dragan
> I too have the same problem as Mike, but when I tried your fix I got
> this answer:
> Warning weird character in interface '--dport' (No aliases, :, ! or *
> ). bad argument '80'
> Any ideas would be welcome.
> Leslie Cox.
>
>


What did you actually type after the -i ? Should be ippp0 in the OP's
example. i.e the name of the interface that connects the router to the
internet.

L.

 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Missing routing in LAN-WAN routing mc Windows Networking 5 12-03-2008 04:22 PM
Win2003 R2 server just stops routing traffic until I restart Routing service Martijn Tonies Windows Networking 8 11-03-2008 12:05 PM
NAT routing and GRE M. Strobel Linux Networking 8 10-23-2008 09:51 AM
I not find the NAT/Basic Firewall under Routing\IP Routing mtczx232@yahoo.com Windows Networking 2 12-16-2006 05:08 PM
Routing Terry Windows Networking 5 07-25-2004 08:35 PM



1 2 3 4 5 6 7 8 9 10 11