Tuesday, June 5, 2012

How the find the Active Directory Domain Controllers listed in DNS on Linux...

Assumptions:

  • You have the "host" utility from BIND.
  • You can do a zone transfer from the local DNS server
  • Your Active Directory admins have properly configured DNS for Active Directory
If you have the above, use the following command:

host -t srv -l your.active.directory.dns.domain | grep _kerberos._tcp.*._sites.dc._msdcs.your.active.directory.dns.domain

Replace your.active.directory.dns.domain with your actual AD DNS domain.