[Samba] How to backup data from an installation in order to restore them in a new one?
lmloge at orange.fr
Tue Feb 14 15:26:51 UTC 2023
--- Situation ---
I am about to install a new Samba suite (version 4.17.5) on a new Debian
Bullseye machine (B).
I currently have a Samba suite (version is 4.13.2-Debian), with
BIND9_DLZ DNS back end, running on another machine (A).
On machine (A):
- I created users using the "samba-tool user create" command,
- I added computers using the "samba-tool dns add" command,
- I added DNS zones using the "samba-tool dns zonecreate" command.
I don't have neither a lot of users nor a lot of machines nor a lot of
That's pretty much all the specific data I "populated" the Samba suite with.
On the new machine (B), contrary to machine (A), I would like to use the
Samba internal DNS back end.
Machine (A) is destined to be "revoked": there will be no Samba suite
running on it in the end.
--- Problem ---
These users and computers, created on machine (A), have SIDs (objectSid)
attached that I would like to keep in the new installation on machine (B).
--- Questions ---
I think that these data are stored in "sam.ldb" and maybe "idmap.ldb".
What files can I backup from the current installation (A) to be able to
restore them in the new one (B)?
Are there also ".tdb" files to backup?
Is there a documentation that explains how data are stored?
Is the fact that I am going to use the Samba internal DNS back end (by
running the "samba-tool domain provision --dns-backend=SAMBA_INTERNAL
instead of the BIND9_DLZ DNS back end, problematic in this case where I
would like to restore the data in the new installation?
Will I have to first migrate the DNS back end from BIND9_DLZ to internal
on machine (A)
(like what is explained here:
Please tell me all the files I should backup from the current
installation or how I should proceed.
Also, maybe the files from machine (A) have to be "upgraded" for machine
(B) since Samba version is going to change from 4.13.2 to 4.17.5?
Thanks and best regards.
More information about the samba