How does a server select a Domain Controller

28 June,2021 by Rambler

What is the process for a server selecting the Active Directory domain controller? When a server requires a Domain Controller , what are the steps leading to a Domain Controller decision. I'm interested to understand - to troubleshoot some Clustering setup issues. 

 

These are the steps followed by a server communicating with Domain Controllers

STEP 1 :  Execute a Query against  the Primary DNS server , returning each Domain Controller (DC) in the domain 

                                            nslookup -type=srv _ldap._tcp.mydomain.net

STEP 2 : The server elects  the  first DC in DNS list using LDAP to connect

STEP 3 : Is the chosen DC in the same AD site site as the member server ? Based on information configured in AD sites 

        if yes --> server starts using the DC

        if no --->  DC will communicate to server member its site 

                                --> server will send new DNS query for the DC list for it's own site

                               --> Member selects the first DC in the DNS list , using LDAP to connect 

                                __>if no DC on local site - connect to any DC in the domain

 

Note:cache local site name in registry to speed up future request 

 

Useful commands using the nltest tool . The nltest tool is available if the AD DS or AD LDS server role is installed. 

--List trusted domains

nltest /trusted_domains

--List DCs in a specific domain 

nltest /dclist:mydomain

 

--Return the AD site of the current server

nltest /dsgetsite  

--List every DC registered the site name

nslookup -type=srv _ldap._tcp.mydomain.net

 

Read more 

 How to get the Active Directory Site subnets


Author: Rambler (http://www.dba-ninja.com)


Share:

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment on How does a server select a Domain Controller


dba-ninja.com