Displaying 1 result from an estimated 1 matches for "patternbuff".
Did you mean:
patternbuffer
2018 May 15
0
Query for DC in the same site...
In my scripts i'm using that query to catch DC:
host -t SRV _kerberos._udp.ad.fvg.lnf.it | awk '{print $NF}'| sed 's/.$//'
and works, but now that the domain get more complex, i want to limit
server lookups to the DC in the same site.
Googling around lead me to:
https://patternbuffer.wordpress.com/2007/12/13/finding-your-active-directory-site-and-domain-controllers/
and seems to work. With the local network i can get the site:
root at vdcsv1:~# ldbsearch -H /var/lib/samba/private/sam.ldb -b "CN=Subnets,CN=Sites,CN=Configuration,DC=ad,DC=fvg,DC=lnf,DC=it" "(c...