how to find the GC in an w2k domain?

Chere Zhou qzhou at isilon.com
Thu Jun 12 19:48:18 GMT 2003


Thanks for your responses!

I guess I should have asked the question as "from a domain in its forest".  
Jmcd's method works when the GC is in the domain, but not if the GC is in a 
parent domain.  Aliguor's is kind of complex, I haven't tried it yet.  But 
from what he described, I doubt it will.

So I have a domain tree, a.com, b.a.com, and c.b.a.com.  If joined samba into 
b.a.com, or c.b.a.com, how do I find the gc, which supposely in a.com?  What 
if I joined samba into a.com, but the GC is in c.b.a.com?

Chere


On Thursday 12 June 2003 09:59 am, Jim McDonough wrote:
> There's an easier way, if you have DNS setup properly.  Query for the
> record gc._msdcs.<dns domain name>
> It's not even an SRV record, it's an A record, so just plain "host
> gc._msdcs.mydomain.com" should do it.
>
> ----------------------------
> Jim McDonough
> IBM Linux Technology Center
> Samba Team
> 6 Minuteman Drive
> Scarborough, ME 04074
> USA
>
> jmcd at us.ibm.com
> jmcd at samba.org
>
> Phone: (207) 885-5565
> IBM tie-line: 776-9984
>
> |---------+------------------------------------------------------>
> |
> |         |           Anthony Liguori/Austin/IBM at IBMUS           |
> |         |           Sent by:                                   |
> |         |           samba-technical-bounces+jmcd=samba.org at list|
> |         |           s.samba.org                                |
> |         |
> |         |
> |         |           06/12/2003 11:32 AM                        |
> |
> |---------+------------------------------------------------------>
> |
>   >------------------------------------------------------------------------
>   >----------------------|
>   >
>   |       To:       qzhou at isilon.com                                       
>   |                      | cc:       samba-technical at samba.org             
>   |                                       | Subject:  Re: how to find the
>   | GC in an w2k domain?                                     |
>   |
>   >------------------------------------------------------------------------
>   >----------------------|
>
> There's a MS-CLDAP query for it.  Essentially, one takes the list of
> domain controllers in the DNS SRV record _ldap._tcp.dc._msdcs.DOMAIN then
> sends out MS-CLDAP queries on the RootDSE for the Netlogon attribute with
> a filter (&(DnsDomain=DOMAIN)(Host=myHost)(NtVer=\0\0\0\6)).  Then one
> would look for an entry that has both ADS_CLOSET and ADS_GC set (and was
> in your domain).
>
> We don't have an api yet to do this in Samba but in Windows one would use:
>
> DsGetDcName(NULL, domain, NULL, NULL, DS_GC_SERVER_REQUIRED, &dc_info);
>
> See
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/netdir/ad/
>dsgetdcname.asp
>
> for details.
>
> Anthony Liguori
> Linux/Active Directory Interoperability
> Linux Technology Center (LTC) - IBM Austin
> E-mail: aliguor at us.ibm.com
> Phone: (512) 838-1208
> Tie Line: 678-1208
>
>
>
>
> Chere Zhou <qzhou at isilon.com>
> Sent by: samba-technical-bounces+aliguor=us.ibm.com at lists.samba.org
> 11/06/2003 09:04 PM
> Please respond to qzhou
>
>
>         To:     samba-technical at samba.org
>         cc:
>         Subject:        how to find the GC in an w2k domain?
>
>
>
> I mean the Global Catelog server.  Is there a LDAP query for that?



More information about the samba-technical mailing list