Univention Bugzilla – Bug 28373
3.0-2: Nach samba4 DC rejoin können lokal keine samba Benutzer angelegt werden
Last modified: 2012-12-12 21:10:17 CET
Mit dem über Bug 27886 für UCS@school in UCS eingeführte --keep-existing für samba-tool-domain join DC können nach einem erneuten Join eines Samba4 Slave DCs auf dem DC gegen das lokale Samba4 keine Benutzer mehr angelegt werden. Ursache ist, daß der Slave DC zwar seinen RID-Pool beibehält (ohne --keep-existing wird ihm ein neuer zugewiesen), aber daran die Attribute rIDNextRID und RidPreviousAllocationPools entfernt. Diese Attribute werden laut AD-Dokumentation nicht repliziert, sondern sind nur lokal vorhanden. Da der rIDNextRID Zählerstand fehlt, versucht der DC dann eventuell schon vergebene objectSids zu vergeben. ================= rIDNextRID: The RID that was assigned to the last security principal that was created on the local domain controller. RidNextRid is a non-replicated value in Active Directory. RidPreviousAllocationPools is a non-replicated value in Active Directory. ================= +++ This bug was initially created as a clone of Bug #25393 Comment 1 +++ Man kann auf dem frisch neu gejointen Slave einfach keine Benutzer anlegen (Fehlermeldung scheint auf den erstem Blick nicht korrekt zu usein): ================================================================ root@slave12:~# samba-tool user add foo1 univention ERROR(ldb): Failed to add user 'foo1': - ../ldb_tdb/ldb_index.c:1189: Failed to re-index objectSid in CN=foo1,CN=Users,DC=arucs3i8,DC=qa - ../ldb_tdb/ldb_index.c:1121: unique index violation on objectSid in CN=foo1,CN=Users,DC=arucs3i8,DC=qa ================================================================
Created attachment 4630 [details] Patch liest rIDNextRID aus und gibt es beim join vor Das dürfte auch UCS@school DCs in der Zentrale betreffen (nicht am Außenstandort).
Der Patch 92_bug27027_keep_existing_option_for_domain_join_dc.patch ist für UCS 3.1-0 entsprechend angepasst, Paket baut, Test steht noch aus.
Der Patch war doch deutlich aufwändiger, weil das provision die vorgegebene next_rid leider nicht wirklich setzt. Mit dem angepassten Patch verlieft der Test jetzt OK, UCS 3.1-0 Changelog Eintrag ist jetzt auch da: "A bug affecting rejoins of Samba 4 DCs has been fixed, where the RID pool rIDNextRID counter was lost, possibly blocking the local creation of new Samba 4 accounts. Now this counter will be preserved during rejoins (\ucsBug{28373})." Im join.log sieht man damit jetzt: ============================================================================== cleanup_old_join: rIDAllocationPool: 9015136355904 cleanup_old_join: preserving rIDNextRID: 1601 cleanup_old_join: preserving rIDPreviousAllocationPool: 9015136355904 [...] Calling bare provision [...] do_join: restoring rIDNextRID: 1601 do_join: successfully restored rIDNextRID Joined domain ARUCS3I8 (SID S-1-5-21-3971689879-1817862189-368804197) as a DC ============================================================================== Der Patch setzt die alte rIDNextRID nur, wenn nach einem Re-Join der rIDAllocationPool der gleiche geblieben ist (was mit --keep-existing immer der Fall sein sollte). Mit univention-s4search "cn=rid set" sieht man dann auch dass rIDNextRID vorhaden und auf den Wert vor dem Join gesetzt ist.
Ich kann nach dem neuen Joinen in meiner Domäne über jeden Samba DC Benutzer anlegen und diese werden problemlos repliziert. Changelog: OK.
UCS 3.1-0 has been released: http://forum.univention.de/viewtopic.php?f=54&t=2125 If this error occurs again, please use "Clone This Bug".