netcmd: Determine which files are to be copied for an offline domain backup
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Tue, 16 Mar 2021 03:22:40 +0000 (16:22 +1300)
committerKarolin Seeger <kseeger@samba.org>
Tue, 13 Jul 2021 12:31:15 +0000 (12:31 +0000)
commit54c353e9ad65a8a764963bddd6396dab4779bfe3
tree19c767c664d5408e226ed4c7d0fbe0dd9f867f62
parent4a68b1cb2dc9b32f49423b96c1fd935f5886d057
netcmd: Determine which files are to be copied for an offline domain backup

The old behaviour attempted to check for and remove files with duplicate
names, but did not do so due to a bug, and would have left undetermined
which files were given priority when duplicate filenames were present.
Now when hardlinks are present, only one instance of each file is
chosen, with files in the private directory having priority. If one
backup dir is nested inside another, the files contained in the nested
directory are only added once. Additionally, the BIND DNS database is
omitted from the backup.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14027

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
(cherry picked from commit 3723148e7aa7e6d4a48a1a38112f121f52b6ee6f)
python/samba/netcmd/domain_backup.py
selftest/knownfail.d/bug-14027 [deleted file]