Forum Moderators: phranque
I am trying to set a server where to host all my domains, like a domain parking server.
I don't know where on the server I add the "A" record to associate the hosted domains to the server's IP address.
Curently it works by creating an "A" record for each domain at godaddy domain manager and entering server's IP as the "A" record's IP.
Can I configure the server's "A" records to host any domain *just* by setting the nameservers to NS1.myserver.com, NS2.myserver.com?
the purpose of the name servers is to translate domains to ips.
you can direct as many domains as you can handle all to one ip including wildcard subdomains which are essentially infinite in number.
it is the web server configuration on that host that figures out how to handle the various domains and subdomains being directed to it.
in /etc/named.conf:
zone "domain1.com" IN {
type master;
file "domain1.com";
allow-update { none; };
}; created /var/named-chroot/var/named/domain1.com:
$TTL 86400
@ IN SOA domain1.com. other.other.com. (
1997022700 ; Serial
10800 ; Refresh
3600 ; Retry
604800 ; Expire
10800 ) ; Minimum
domain1.com. IN NS 208.109.209.186
domain1.com. IN A 208.109.209.186
www.domain1.com. IN CNAME domain1.com. domain1.com loads ok in browser now.
But...
Is there a way to simplify this? I don't know if adding the zone was needed or not.
Ideally I would like it to work for any domain so that I dont have to do this for all my domains. Is there a way?
[edited by: adrianTNT at 3:58 pm (utc) on Feb. 17, 2009]