[Samba] Upgrading Samba AD DCs from Debian 12 (Bookworm) to Debian 13 (Trixie)

Rowland Penny rpenny at samba.org
Sat Nov 8 11:06:03 UTC 2025


On Wed, 5 Nov 2025 21:22:59 +0000
Carlos Gardel via samba <samba at lists.samba.org> wrote:

> Hello Rowland, Luis, and Olivier,
> Thank you for your input!
> I think I will follow your advice and start by upgrading the DC where
> Samba is installed from the Debian backports repository. After that,
> I will attempt to upgrade the self-compiled DC. I will also consider
> replacing the self compiled DC with a new DC with Debian's packages!
> The reason I have a self-compiled installation on one of the DCs is
> that I initially followed the Samba Wiki’s recommendation for this
> setup years ago (when I was running my DCs on CentOS 6). 

Centos was RHEL rebuilt with different logos etc. and like RHEL you
could not provision a Samba AD domain using the standard OS packages,
the code had been removed by redhat. Originally if you wanted a Samba
AD DC on Centos, you had to compile Samba yourself. 

> At that
> time, the Wiki did not contain any warnings about building Samba from
> source. 

There is no major problem with building from source, though it does lock
you into continuing to have to build it yourself. There is a minor
problem, Samba from time to time (though not recently) removes or
renames files. If you compile a new version of Samba over an existing
version, the compile does not delete any 'removed' or 'renamed' files,
this can lead to problems.
 
> When I later moved to Debian for the DCs, Debian's packaged
> Samba version was quite old, so I decided to continue using a
> self-compiled build — this was before I became aware of Debian
> backports. For the self-compiled DC, I built Samba using the Wiki
> instructions by first running the bootstrap script and then:

Debian picks a Samba version and then sticks to it, though they do
back port important updates. Debian is a lot more proactive now when it
comes to Samba, Trixie comes with Samba 4.22.4, but when Debian finally
creates the trixie-backports repo, I expect that a newer Samba version
to appear there, 4.23.x perhaps. If you are using Debian, then I
suggest you always use Samba from backports if there is one.

> 
> $./configure
> $ make
> $ make install
> 
> I did not set any custom --prefix, and the Debian system itself was
> installed with minimal packages (“SSH Server” and “Standard System
> Utilities”), so there are no Debian Samba packages installed
> alongside the self-compiled version.
> 
> I have noted that on the self-compiled DC, smb.conf is located under
> /usr/local/samba, whereas on the DC using Debian backports, Samba’s
> configuration resides in /etc/samba.

This is one of the problems, unless you set numerous configure options,
all of Samba ends up in /usr/local/samba by default. Then any files
created during the join also end up in /usr/local/samba and if you then
were to install OS distro Samba packages, the distro packages would not
use the databases etc in /usr/local/samba.

> 
> Referring to Rowland’s comment:
> 
> "What I wouldn't do is to upgrade the existing DC and try and
> upgrade/install Samba unless your self compiled Samba has the parts of
> Samba in the same places as where Debian packages place them."
> 
> Is there a specific --prefix or installation path that could (or
> should) be used to to install a self compiled version of samba to the
> directories used by Debian’s Samba packages?

Probably, though without doing some 'digging', I am not entirely sure
what they are.
The easiest way, do not attempt to do it, just replace the OS with self
compiled Samba with an OS with its own Samba packages, I can recommend
Debian 13.
 
Rowland



More information about the samba mailing list