DynDNS, Linksys WRT54G, & subdomains?
I managed to get dynDNS working with my router to point to one of the machines on my network using port forwarding. I have several webservers on various machines in my office. Is there a way to set it up to use subdomains to point to all the machines on my network?
e.g. ws.whatever.dyndns.com might point to my workstation and laptop.whatever.dyndns.com would point to my laptop. #note whatever.dyndns.com is NOT my address. |
>linksys WRT54G
Have you read this? >Is there a way to set it up to use subdomains to point to all the machines on my network? The router will only have one internet ip address Either 1)get your ISP to give you more ip addresses so you can have the subdomains pointed to different domains. Your ISP may not want to give you more addresses. I don't know if the linksys will support multiple ip's, setting static routing entrys to direct packet's in and out might or might not work. 2)Point all the subdomains at your internet ip. Forward port 80 to a webserver. Configure virtual hosts on the webserver and have it proxy the requests to the internal webservers. I think apache supports this. The HTTP1.1 protocol allows multiple domains on one ip by sending the full URL including the domain in the request. |
I'm using slackware 9.1 on all my linux machines.
So I need to edit the httpd.conf on the server machine I have the router forwarding requests to. I will try that. I was wondering if there was something to be done in the routeradministration section. |
>So I need to edit the httpd.conf on the server machine
>I have the router forwarding requests to. and get your DNS configred so that the subdomains exist. |
Is there a good resource on the web where I can read/learn how to do this correctly?
|
To get the DNS configured, you are using dynDNS so their webpage would be a good place to start .
To configure apache, google or the apache homepage. |
I think I'm on the right track but now quite there. Names have been changed to protect the not so innocent. Wildcard is on at dyndns.org. Exerpts from httpd.conf files from both machines.
#httpd.conf machine router points to # lots of stuff omitted above here NameVirtualHost * <VirtualHost *> DocumentRoot /var/www/htdocs ServerName whatever.dyndns.org </VirtualHost> <VirtualHost *> ServerName machine2.whatever.dyndns.org Redirect / http://192.168.1.104/ </VirtualHost> #the machine with internal IP 192.168.0.4 NameVirtualHost * <VirtualHost *> DocumentRoot /var/www/htdocs ServerName machine2.whatever.dyndns.org </VirtualHost> It will redirect machine2.whatever.dyndns.org to the right machine, but once I click a link then I will get a 192.168.1.104 url. |
All times are GMT -5. The time now is 05:18 PM. |