Networking Forums  

Go Back   Networking Forums > Networking Newsgroups > Linux Networking

DNS and internal routing

Reply
 
Thread Tools Display Modes
  #1  
Old 02-11-2006, 09:38 AM
Default DNS and internal routing



Ok, here is my wish:

I have a DSL connection with a static IP and a domain name with which I
can edit the DNS entries of.

I have setup an A record and an MX record for home.mydomain.com to
point to my DSL connection's static IP.

On my internal network I have 3 machines. What I would like to be able
to do is create subdomains of home.mydomain.com based on my (ie
internal1.home.mydomain.com, internal2.home.mydomain.com etc..) and
have one of my internal machines receive all incoming traffic and route
traffic to the other internal machines based on the incoming domain
being used.

For example:

internal1.home.mydomain.com recieves all traffic for home.mydomain.com
and subdomains. If I ssh to internal3.home.mydomain.com,
internal1.home.mydomain.com recognises this and routes the traffic
through to internal3.home.mydomain.com

I realise that I can just do this with NAT for specific ports, but
would for the sake of learning, I would also like to learn how to do
this by machine name.

If somebody could point me in the direction of what I should be
learning to acheive this, I would be very appreciative.

Thanks
Scottatron



Scottatron
Reply With Quote
  #2  
Old 02-11-2006, 11:06 PM
Antoine EMERIT
Guest
 
Posts: n/a
Default Re: DNS and internal routing

"Scottatron" <(E-Mail Removed)> écrivait
news:(E-Mail Removed) oups.com:

> I realise that I can just do this with NAT for specific ports, but
> would for the sake of learning, I would also like to learn how to do
> this by machine name.


If you have the same IP for all your sub-domain , you can't do that at a
TCP/IP only level. Because the hostname is not send in the TCP/IP
connection.

Except in the upper protocol level. For example, the HTTP protocol send
the request hostname in the http header (fiels HOSTNAME=<domaine or
subdomain requested>).

This is not the case in the ssh protocol. It only open a port (default=
22).

So you can't do that with "simple" routing services. Netfilter can't
solve this problem.

In the case of http, you even have t install a "redirector" (heartbeat,
or squid or apache in proxy mode) that analyse the http header to connect
to the right internal server.


Regards

Reply With Quote
  #3  
Old 02-11-2006, 11:31 PM
Scottatron
Guest
 
Posts: n/a
Default Re: DNS and internal routing

Thanks Antoine

I figured that might be the case.

So am I correct in saying that I could do this if I had more than one
external IP address? And in that case I would use IPTables?

Scott

Reply With Quote
  #4  
Old 03-05-2006, 10:02 AM
Antoine EMERIT
Guest
 
Posts: n/a
Default Re: DNS and internal routing

"Scottatron" <(E-Mail Removed)> écrivait news:1139700715.148701.326280
@o13g2000cwo.googlegroups.com:

> Thanks Antoine
>
> I figured that might be the case.
>
> So am I correct in saying that I could do this if I had more than one
> external IP address? And in that case I would use IPTables?


Yes, you are correct.


Regards
Reply With Quote
Reply

Tags
dns, internal, routing

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
Forum Jump


All times are GMT. The time now is 07:19 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.