[SOLVED] Two hosts on DDNS. Can I send two domains through one router?
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Two hosts on DDNS. Can I send two domains through one router?
I have two virtual hosts that I want to be able to send through one router. I have two seperate dynamic hostnames on dyndns. Apparently my router allows me to enter two seperate hostnames locally as well: DynDNS
Host and Domain Name
Code:
host1,host2
Locally, vhost 1 is on eth0. vhost 2 is on eth0:0.
How do I tell the router which is which? Currently I see the same site with both URLs
Do I have to set one vhost to do some 'funky' stuff (black hole in my head when it comes to static routes or BIND? ). And then set the other vhost to host both sites?
I'm running CentOS and an apache webserver. I want to demo a web site 'externally' from two different sub-domains.
I've looked high and low but most examples don't seem to be simply trying to put two different web-sites up to two Dynamic DNS Hosts.
It must be possible, all the pieces are there. I'm just missing the link!!! (I think...)
Last edited by alar; 02-11-2011 at 05:05 PM.
Reason: added want to demo "externally"
if these are fronted by the same pshycial server, then yeah it's just *very* simple virtual hosts config under apache. the router doesn't care in the slightest, it just passes traffic on port 80 through to the designated back end. Ignore the "Dynamic DNS" side of things, that's irrelevant at the apache level. just a case of two FQDN's which you'll need virtual hosts for.
I don't doubt it's simple but how can I ignore the DDNS side?
I have multiple VirtualHosts on apache and I can see them all internally, usually with the same internal IP address, different hostnames of course. But if an external web-site has a link to 'another' external web site it's a different DDNS address... No???
How do I let external users click on two different links? (I'm so not a Network guy!)
A fully qualified domain name? Routers are black holes to me. Inside vs outside, which name refers to which end?
If dyndns is sending traffic on port 80 to your router it doesn't matter which domain it's for. Just have your router forward traffic for port 80 to your Apache box. Apache will determine which virtual host serves up the pages based on the domain name.
I have 2 domains with a custom account at dyndns and I just have them both point to the IP address of my router. My router doesn't care which domain the traffic is for, it just sends it all to my web server. My Apache is using name based virtual hosts so I'm only using one network connection on the web server (eth0).
It would help for you to understand the OSI model a little, and things would be a lot simpler for you. virtual hosts in apache use HTTP data, this is at layer 7. but home adsl routers only deal with traffic at layer 3 (The IP address) and layer 4 (The TCP port) so in terms of your router it doesn't see the HTTP level data, i.e. which virtual host, so it doesn't matter there what it is, or how it's defined (i.e. the DDNS stuff doesn't matter - setting DDNS is a point in time thing, which is "out of band" with respect to the use of the hostname - you just go set it when it changes and outside of that nothing else happens). Basically - Divide and conquer!
Thankyou acid_kewpie, that explanation sunk in! Using the OSI model drilled in what you said in the first post, and gilead confirmed. But now I get it!!!
Quote:
virtual hosts config under apache
So the links still don't work but I know why it is not a router issue now!!!
My focus moves to httpd.conf...
Thanks both of you
--
Allison
You don't need to run your own DNS at all, you just need valid DNS records somewhere in the system, possibly from your domain registrar etc. you *can* do it yourself, but it's probably more hassle than it's worth if you depend on it at all. Personally I used to use zoneedit.com a lot for this sort of thing.
Is the hassle with DynDNS in IP address synchonization? I already have ddclient configured and running!! Your current location's IP address is:
correct for both.
Is that how I get
Quote:
you just need valid DNS records somewhere in the system,
???
(I loved Networking in school... it's just been a really long time...)
Willing to try zoneedit.com though! Many thanks!
using a dyndns service is NOT running your own DNS in any way. It's letting someone else run it, and you kicking them occasionally. I would suggest doing what you're apparently already doing. You'd just need to run it twice for two different addresses.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.