3

Can one IP address be registered as two different name servers, for example, can one IP address be registered as both ns2.acme.com and ns2.beta.com with my DNS registrar? (I know one IP cannot and should not be both ns1.acme.com and ns2.acme.com)

I ask because I am setting up a secondary DNS server and the names it will be serving are all on one machine right now; this machine has many IPs, one IP is ns2.acme.com and another is ns2.beta.com (clearly those are example names) and some customers have their DNS set to the "acme.com" name servers, while other have their DNS name servers set to the "beta.com" nameservers. It's the same server, it was just that the "beta.com" name was purchased years after as a replacement for the "acme.com" name, but not all customer switched their DNS.

EDIT: To clarify, I'm not talking about DNS A records, I am talking about registering IP addresses as nameservers with my registrar.

EDIT 2: Thanks to Jacob, who reminded me that the word for what I am asking is "glue records." Can one IP serve as two different glue records for two different domains?

Josh
  • 9,190
  • 28
  • 80
  • 128

6 Answers6

1

You can have as many A records as you like pointing to the same IP, there is nothing in the DNS spec that will stop you.

That said, you obviously loose some redundancy if all your name servers are on one physical machine, but if you are splitting name servers between 2 machines, and just using the same IP for multiple domains, this is less of an issue. Your more likely to see hardware issues, than you are routing errors for a single IP.

Sam Cogan
  • 38,736
  • 6
  • 78
  • 114
  • Actually, I'm not talking about DNS A records, I am talking about registering IP addresses as nameservers with my registrar. – Josh Mar 11 '11 at 17:33
1

As long as both NS are different there are no other restrictions. Multiple domains can use the same name servers.

Mircea Vutcovici
  • 17,619
  • 4
  • 56
  • 83
1

To answer your question: Yes, you can do that.

There is problem in registering several nameserver sets with your registrar using the same IP addresses.

Note that both ns1.alpha.com and ns1.beta.com will be able to resolve zones from "both" NS sets, if you choose to do this.

Also, you cannot have severeal reverse DNS entries on the IP addresses of the nameservers. But if that does not matter, you are good to go.

Frands Hansen
  • 4,657
  • 1
  • 17
  • 29
1

The record you're thinking of are called glue records... As far as 2 domain's glue records pointing to the same IP for their DNS server, it'll work. Your DNS server nor the register will care how you get the server's IP. You should remember though, that you can't set RDNS for both hostnames though.

Josh
  • 9,190
  • 28
  • 80
  • 128
Jacob
  • 9,204
  • 4
  • 45
  • 56
0

The NS records are themselves A records. There's an A record for ns1.acme.com and then you designate ns1.acme.com as the name server for the acme.com DNS zone. You can create any number of A records for the same ip address and designate those "names" as the name servers for any number of DNS zones, so the A records for ns1.acme.com and ns1.beta.com could resolve to the same ip address and both could be designated as the name server for their respective DNS zone.

joeqwerty
  • 109,901
  • 6
  • 81
  • 172
0

I think you are overthinking this. Why not just declare beta.com's nameserver to be ns1.acme.com? (or the other way around if you are getting rid of acme.com... does anyone ever get rid of a domain?)

DerfK
  • 19,493
  • 2
  • 38
  • 54