Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


How does ns1 and ns2 work?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

How does ns1 and ns2 work?

I have a DNS Cluster set up in WHM (ns1 in main server, ns2 in an leb).

When you go to intodns.com/mydomain.com, sometimes ns2 appears on top, sometimes ns1 appears on top.

ie. it shows:
ns2.domain.com
ns1.domain.com

instead of

ns1
ns2

Does that mean that it is served by ns2? Or is it always ns1 serving?

Thanks!

Comments

  • oneilonlineoneilonline Member, Host Rep

    If I believe I understand what you are seeing on the site, the one on top is the one that provided the info. It will ping which every one responds first.

  • VPNVPN Member
    edited January 2014

    @oneilonline said:
    If I believe I understand what you are seeing on the site, the one on top is the one that provided the info. It will ping which every one responds first.

    That's right. It will query the parent servers of the TLD for it's nameservers and then asks all the listed nameservers for information on the requested domain. Whichever server responds first will be listed first. Typically in your setup, as you probably have sites and such on the server listed as ns1, it's ping time will probably be a fraction slower than your secondary server.

    Regardless of this, whatever nameserver you have in the SOA will be the primary nameserver of that domain although I believe that doesn't have much importance now.

  • gbshousegbshouse Member, Host Rep

    NS records are served in round robin order

  • Great! Understood! Thanks everyone =)

Sign In or Register to comment.