LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Gateway/router (https://www.linuxquestions.org/questions/linux-newbie-8/gateway-router-704134/)

TheSharkBait 02-12-2009 06:21 AM

Gateway/router
 
Ive just bought a DLINK DSL-502T with half-bridge support.

Im currently wanting to set up a gateway/router using slackware linux.

Buts its doing my head in trying to figure out how get eth0 on the gateway box an external ip address.

Ive set the modem to half-bridge mode with dhcp enabled to automatically get the external ip but its not working.


Any information how how to get my external interface an external IP address would be greatly appreciated, thank you!

Tinkster 02-12-2009 02:42 PM

Out of curiosity: what's the benefit of having the external IP on
the computer over having all traffic NATed in your opinion?


Cheers,
Tink

TheSharkBait 02-12-2009 03:31 PM

From all the guides ive read, you need an external ip on the external interface?

jstephens84 02-12-2009 04:13 PM

So If I understand you correctly you want your cable modem / dsl modem to be just a modem and use your linux box as a router? Ok so I just reread your post. So what you want to do is take off dhcp on your modem then put it into bypass mode. This will still assign the eth0 on your linux box with the external ip from the ISP. Then you need to setup your eth1 with the lan ip and have it give out dhcp to the lan clients. Then you will need to add the route for 0.0.0.0 to be the next hop which will point to the gateway at your isp.

Tinkster 02-12-2009 04:30 PM

Quote:

Originally Posted by TheSharkBait (Post 3441474)
From all the guides ive read, you need an external ip on the external interface?

The guides on what?

As long as you can configure your modem to pass any
incoming traffic on the interesting ports (HTTP,SMTP, ..)
on to your server there's no need for the set-up you're
trying to achieve ... not that it looks overly complicated
(if the modem hardware supports that kind of thing).



Cheers,
Tink

servat78 02-12-2009 06:05 PM

The DSL-502T is an ADSL Internet Gateway Router, and it will be much easier for you to use that one as the gateway and for port forwarding. It is rather a waste of resources to keep a PC running for a task that can be done with a small specialized piece of hardware that consumes less power and is designed for doing just that.

If you have some specific reasons to support a lot of local PC's with fine-grained control over several local zones etc, then you will need to delve into some heavy routing/firewall howto's. Smoothwall Express is a good choice for such a routing Linux system - needs it's own hard disk and a dedicated system. I would anyway oppose the idea of using the routing PC for other duties like working, web serving, etc.

Debian


All times are GMT -5. The time now is 08:28 AM.