[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Route question
> I have a dialup static IP 139.a.b.c
>
> The box doing this has an ethernet NIC which I give the IP of 192,168.1.1
>
> Now I want to add a box running Linux. With another 192.168.1.x address it does
> just fine BUT I want to expose it to the internet and it has its own assigned IP
> 203.x.y.z
>
> Punching a hole in my firewall rules for 203.x.y.z in and out = no problem and
> my ISP routes the 203 address via my 139 address so outside packets get to my
> gateway.
>
Are you sure about that?
> How can I route them to the Linux box?
>
You can't with just one ip address. It sounds like your ISP has just
basically allowed you to add an alias to your dial up interface. To route
you need a different subnet on each side of your router, hence the
192.168. on one side and the 139.x.x.x and 203.x.x.x on the other.
One solution is to redirect traffic to 203. on the external interface
to the 192.168. address of the linux box.
Greg
> I tried aliasing the 203 address to the Linux NIC that already had its 192 and
> adding a route in the gateway which said to route packets for the 203 address to
> the 192.168.1.x address. I figured that they would end up on the right NIC and
> it would see them as its own but this does not work.
>
> I know I can do this easily with a "real" router or by adding more NICs and
> giving the gateway box another 203 address but I'm sure I should be able to do
> it with one NIC each and only one 203. Can it be done? Maybe the 203 box should
> not have a 192 address as well? But then how would I tell the gateway where to
> send the packets?