Jump to content

DNS settings?


michaellunsford

Recommended Posts

Short of buying the DNS for dummies book... I am trying to get a few different domain names to forward to a single domain -- http, https, ftp, email, everything...

does anyone know how to accomplish this?

example.com (main domain)
example1.com (forwards to example.com)
example2.com (forwards to example.com)

On the e-mail front, it is my hope that an email going to bob@example2.com would end up in bob@example.com's inbox. Also, any www.example2.com traffic would just go to www.example.com

why? plesk charges per domain -- I'd hate to blow five domain licenses on a single domain. Also, manually forwarding each individual email address in plesk seems like a waste of time.

thoughts?
Link to comment
Share on other sites

the name server configuration is what I'm toying with...

i have to change the following settings:

ns, mx, and "a" records. the NS records I am assuming are name servers (no problem there)
mx is set to "mail" -- which apparently is just mail.example.com
I'd like to redirect the "a" records to the main domain name. So far, it doesn't like anything but an IP address.
Link to comment
Share on other sites

  • 2 weeks later...
Now I had this very same issue with my domains. I have mydomain.com, .net, .org, and .biz. All pointing to mydomain.com. Like you I thought that I would need to use the zone file to do this but no. If they are all on the same server then all you have to do is, in your httpd.conf or mode_rewrite point them to the same directory. The same goes for any subdomains.

[code]
<VirtualHost *:80>
ServerName domain.com
ServerAlias www.domain.com
DocumentRoot "path\www\domain\public"
</VirtualHost>

<VirtualHost *:80>
ServerName domain.net
ServerAlias www.domain.net
DocumentRoot "path\www\domain\public"
</VirtualHost>

#continue this for as many as needed
#the vhosts are very simple are only meant to be an example
[/code]

or in your named.conf you could use the same zone file for all of the domians like this.
[code]
zone "domain.com" IN {
type master;
file "domain.com.zone";
};

zone "domain.net" IN {
type master;
file "domain.com.zone";
};

zone "domain.org" IN {
type master;
file "domain.com.zone";
};

zone "domain.biz" IN {
type master;
file "domain.com.zone";
};[/code]

This would have the same out come but would be alot easier then doing this with apache. I would suggest doing it this way

Hope this Helps,
Tom
Link to comment
Share on other sites

very good info. Thanks for the reply.

an interesting new feature of plesk 8 (which I have also just become aware of) is the alias feature. Odd, though, it does not change the httd.conf file (I wonder what it does change?). Plesk will also do mail -- but I'd really like to know how to accomplish this (as I'm not terribly eager to pay sw-soft for every domain I own). Would it be as simple as adding a new entry for ports 110 and 995?
Link to comment
Share on other sites

ahh, the named.conf (the file that plesk rewrites from time to time). Looks like I need another server without plesk.

as for h-sphere, I really don't have that much control over the leased server -- short of installing it myself from ssh. As my knowledge grows of how these things work, I am looking forward to doing it all myself (no plesk). Of course, there is always the dread of someone exploiting my ignorance and hacking root access.

Any suggested reading on how to setup and maintain a web server without a hosting controller?
Link to comment
Share on other sites

First what I do is store all of my zone and vhost info in a database. Then in the httpd.conf file I include a file called vhosts.conf(all of my virtual host information). Then I use the standard fwrite and fread with some mysql querys to update this infomation. This is very simple but it suits mine and my clients needs.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.