Find the answer to your Linux question:
Results 1 to 5 of 5
I've been a programmer for years and am just now delving into the world of LAMP (linux,apache,mysql and PHP). My intention is to use one of the dynamic DNS services ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux User
    Join Date
    Nov 2002
    Posts
    420

    Apache/Name Hosting Question


    I've been a programmer for years and am just now delving into the world of LAMP (linux,apache,mysql and PHP). My intention is to use one of the dynamic DNS services to point to my linux/apache based website. I have it running internally (linux/apahce set up at 127.0.0.1 and I access just fine.) I have been reading in the Apache doc's and would like to use name hosting so that I can point two domains to the same apache server. How do I test this? I've set both name host configs in the vhost config file but it would appear that unless I have the cname alias set up at the DNS server that it will not pick up the second name host. I'm definetly a newbie in this area and any help would be appreciated - sorry for the long post - tia - tbullard

  2. #2
    Linux Enthusiast
    Join Date
    Jun 2002
    Location
    San Antonio
    Posts
    621
    set up your named server (bind) to respond with your IP address (127.0.0.1) for test1.com and test2.com. Details for doing this will be in the BIND-howto on linuxdoc.org. They have a much better explanation than I would. If you need specific help from there, come on back.
    I respectfully decline the invitation to join your delusion.

  3. #3
    Just Joined!
    Join Date
    Nov 2002
    Posts
    3

    Apache/Name Hosting

    Thanks for the info - I'll look it up tomorrow after work - thanks again - tb

  4. #4
    Just Joined!
    Join Date
    Jul 2002
    Location
    Madison, WI.
    Posts
    36
    This isn't that complicated. For each domain, set up a DNS records (or DynDNS) to point the domain xxxxxx.com (or CNAME xxxx.xxxxxx.com) to the your server (whatever the IP address is, dynamic or not)

    Then modify httpd.conf for virtual hosting. You can host as many domains as you want on the same box.

    BTW, I haven't tested it, but conceivably the HTTP request should still contain the domain call (DynDNS or not), so apache should be able to pick it out and redirect to the proper local webserving directory for whatever domain is requested.

  5. #5
    Just Joined!
    Join Date
    Jul 2002
    Location
    Madison, WI.
    Posts
    36
    Oh, and BTW, you won't be able to host your own DNS server if you're connection is on a Dynamic IP. Well, you could for your LAN I guess...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •