s4-join supply the NTDS GUID to the provision
authorAndrew Bartlett <abartlet@samba.org>
Thu, 25 Aug 2011 09:13:34 +0000 (19:13 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 13 Sep 2011 05:37:12 +0000 (15:37 +1000)
Unlike other join operations, the creation of a subdomain makes local
changes to the DB, so we need to pass in the NTDS GUID to ensure the
one set on the object created in the parent domain is the one that is
used.

Andrew Bartlett

source4/scripting/python/samba/join.py

index 1759990deb96d2fae492fda70a1b453c278a74e8..2967ddf7e78ff3c40ca293e3665491c77a2df60a 100644 (file)
@@ -440,7 +440,7 @@ class dc_join(object):
                             serverdn=ctx.server_dn, domain=ctx.domain_name,
                             hostname=ctx.myname, domainsid=ctx.domsid,
                             machinepass=ctx.acct_pass, serverrole="domain controller",
-                            sitename=ctx.site, lp=ctx.lp)
+                            sitename=ctx.site, lp=ctx.lp, ntdsguid=ctx.ntds_guid)
         print "Provision OK for domain DN %s" % presult.domaindn
         ctx.local_samdb = presult.samdb
         ctx.lp          = presult.lp