Bug 15999 - net ads join still fails with multiple DCs
Summary: net ads join still fails with multiple DCs
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Tools (show other bugs)
Version: 4.23.0
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Samba release manager
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-02-12 19:18 UTC by Pavel Filipenský
Modified: 2026-05-27 22:33 UTC (History)
2 users (show)

See Also:


Attachments
4.24 patch (8.54 KB, patch)
2026-04-28 09:12 UTC, Pavel Filipenský
asn: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Filipenský 2026-02-12 19:18:08 UTC
During joining a domain with multiple DCs we need to deal with situation that machine account is created using LDAP at one of the DCs and there is a window till the account is replicated to the other DCs.

The fix in https://bugzilla.samba.org/show_bug.cgi?id=15905 makes sure that keytab code calls ads_init() with a particular DC (the one which was used for creating the machine account). 

However there are two more calls during libnet_Join() that might talk to DC and we must make sure that it is the right DC:


libnet_join_post_processing_ads_modify() (etype update)
libnet_join_post_verify() (domain membership verification)

The fix will follow.
Comment 1 Pavel Filipenský 2026-02-25 09:49:02 UTC
Fix in progress: https://gitlab.com/samba-team/samba/-/merge_requests/4435
Comment 2 Samba QA Contact 2026-04-07 14:10:04 UTC
This bug was referenced in samba master:

a6938e9fdf59094da359637eb1f7e847a531ba2e
689f9d49c3715240a28d9d898c6b83be4ee18971
3459eeb20ea54f4f412ec3d1fe3d9e98b94e1ca4
Comment 3 Pavel Filipenský 2026-04-28 09:12:52 UTC
Created attachment 18952 [details]
4.24 patch
Comment 4 Andreas Schneider 2026-04-28 09:16:04 UTC
Comment on attachment 18952 [details]
4.24 patch

lgtm
Comment 5 Andreas Schneider 2026-04-28 09:16:24 UTC
Bjöen, please include that patch.
Comment 6 Samba QA Contact 2026-05-12 14:57:44 UTC
This bug was referenced in samba v4-24-test:

7fc82a5945729c53769417d7f67dc4d5a941bf00
932b05ae0e2b36189435ef80ecaa0d21949003fe
69d016d34b6aff281ff0482713ba73bf5adb7073
Comment 7 Samba QA Contact 2026-05-12 15:55:21 UTC
This bug was referenced in samba v4-24-stable (Release samba-4.24.2):

7fc82a5945729c53769417d7f67dc4d5a941bf00
932b05ae0e2b36189435ef80ecaa0d21949003fe
69d016d34b6aff281ff0482713ba73bf5adb7073