Command to query Domain Controller, GC, FSMO roles servers in Domain and also in Forest

To find all domain controllers in the current domain, type:
dsquery server

To find all domain controllers in the forest, and then display their relative distinguished names, type:
dsquery server -forest

To find GC's in current domain, type:
dsquery server -isgc

To find all the GC's in the forest, type:
dsquery server -forest -isgc

To find all domain controllers in the particular site, and then display their relative distinguished names, type:
dsquery server -site <Sitename>

To find the domain controllers in the domain that holds FSMO roles, type:
netdom /Query:FSMO

To find all domain controllers in the particular domain that are global catalog servers, type:
dsquery server –domain <FQDN domain name> -isgc

***Share your comments about the post***

No comments:

Post a Comment