Bug 281672 (samba_4.19.8_1_broken_replication) - net/samba419 4.19.8_1 breaks replication
Summary: net/samba419 4.19.8_1 breaks replication
Status: Closed FIXED
Alias: samba_4.19.8_1_broken_replication
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Some People
Assignee: Xavier Beaudouin
URL:
Keywords:
Depends on:
Blocks: DEFAULT_VERSIONS=samba=4.19
  Show dependency treegraph
 
Reported: 2024-09-23 19:52 UTC by Oljas Kuzembaev
Modified: 2025-02-06 15:41 UTC (History)
5 users (show)

See Also:
bugzilla: maintainer-feedback? (samba)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Oljas Kuzembaev 2024-09-23 19:52:38 UTC
command:
samba-tool drs replicate DC2 DC1 dc=samdom,dc=example,dc=com

returns:
ERROR(ldb): uncaught exception - 00002020: Operation unavailable without authentication
  File "/usr/local/lib/python3.11/site-packages/samba/netcmd/__init__.py", line 279, in _run
    return self.run(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/samba/netcmd/drs.py", line 535, in run
    msg = self.samdb.search(base=self.samdb.get_config_basedn(),
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Expected Results:
Replicate from DC1 to DC2 was successful.

It works fine on 4.19.7 and 4.16
Comment 1 Oljas Kuzembaev 2024-10-23 09:57:53 UTC
4.19.9 the problem still persists
Comment 2 Sergey Nasonov 2024-10-23 10:19:15 UTC
DC replication with samba 4.19.7 and 4.19.8 on FreeBSD working fine when samba builded with internal LDB and TDB tools.

To build samba with internal LDB and TDB I am added: 
SAMBA4_BUNDLED_TDB=yes
SAMBA4_BUNDLED_LDB=yes
to /etc/make.conf and rebuild net/samba419
Maybe there is rationale to make LDB and TDB bundled with samba by default?
Comment 3 Oljas Kuzembaev 2024-10-23 19:06:22 UTC
(In reply to Sergey Nasonov from comment #2)
That worked!
Thanks!
Comment 4 shellingfield 2025-02-03 06:05:34 UTC
Hi,

my rough patch for pkg-plist.ad_dc on #284473 were also effective at least on my environment, with

- samba419-4.19.9_5 (from ports)
- ldb28-2.8.2 (from pkg)
- tdb-1.4.9,1 (from pkg)

I hope this helps you.

Regards,
Comment 5 Xavier Beaudouin freebsd_committer freebsd_triage 2025-02-04 10:59:44 UTC
Hello

Will take your pkg-plist.ad_dc on #284473 update net/samba419, hope this will fix this issue
Comment 6 commit-hook freebsd_committer freebsd_triage 2025-02-04 12:02:02 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=ff0a14ef5fdf6c4d39fcfaa04e5b3c7f8b8fed6d

commit ff0a14ef5fdf6c4d39fcfaa04e5b3c7f8b8fed6d
Author:     shellingfield@icloud.com <shellingfield@icloud.com>
AuthorDate: 2025-02-04 11:07:33 +0000
Commit:     Xavier Beaudouin <kiwi@FreeBSD.org>
CommitDate: 2025-02-04 12:01:18 +0000

    net/samba419: Fix plist for ad_dc replication

    PR:             281672
    Reported by:    Oljas Kuzembaev <oljas@oml.su>
    Approved by:    0mp (mentor)
    Approved by:    samba (0mp, kiwi)
    Differential Revision:  https://reviews.freebsd.org/D48827

 net/samba419/pkg-plist.ad_dc | 3 +++
 1 file changed, 3 insertions(+)
Comment 7 Xavier Beaudouin freebsd_committer freebsd_triage 2025-02-04 12:06:32 UTC
Changes has been commited. Please tell us if it fix everything in your side !
Kind regards
Comment 8 commit-hook freebsd_committer freebsd_triage 2025-02-04 13:17:13 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=616b16524e935a0f19db0c767000d48a5e3fa994

commit 616b16524e935a0f19db0c767000d48a5e3fa994
Author:     shellingfield@icloud.com <shellingfield@icloud.com>
AuthorDate: 2025-02-04 11:22:24 +0000
Commit:     Xavier Beaudouin <kiwi@FreeBSD.org>
CommitDate: 2025-02-04 13:16:03 +0000

    net/samba420: net/samba419: Fix plist for ad_dc replication

    PR:             284473
    PR:             281672
    Reported by:    Oljas Kuzembaev <oljas@oml.su>
    Approved by:    0mp (mentor)
    Approved by:    samba (0mp, kiwi)
    Differential Revision:  https://reviews.freebsd.org/D48828

 net/samba420/pkg-plist.ad_dc | 3 +++
 1 file changed, 3 insertions(+)
Comment 9 Sergey Nasonov 2025-02-04 13:39:37 UTC
Confirm. Path pkg-plist.ad_dc is resolved replication issue on samba 4.19.9. Thanks!
Comment 10 Mateusz Piotrowski freebsd_committer freebsd_triage 2025-02-06 15:41:55 UTC
If the problem is gone, let's close this PR. Thanks everyone!