[Samba] Samba 4.8.5 breaks Time Machine support

Philipp Wollermann philipp.wollermann at gmail.com
Tue Sep 11 18:58:07 UTC 2018


Hi,

tl;dr - Samba 4.8.5 broke macOS's Time Machine support (at least for
me), patching in the "follow-up patch" from
https://bugzilla.samba.org/show_bug.cgi?id=13441 makes it work again.
It would be great if it could be included in an official patch release
soon. :)

Just writing about the problem and solution here, in case someone else
stumbles upon it. Couldn't find any existing report about it on the
web.

I recently upgraded Samba from 4.8.4 to 4.8.5 on my Arch Linux machine
and noticed that my macOS machines could no longer make Time Machine
backups reliably on a Samba share on that server.

macOS machines would often show the message: "The identity of the
backup disk has changed since the previous backup". Verifying the
backup would give the message: "Time Machine couldn't verify your
backups, because verification was interrupted".

The system log on the Mac would show the following errors:

Failed to create Time Machine Information file
/Volumes/timemachine-1/philwo-imac.sparsebundle/com.apple.TimeMachine.MachineID.plist,
error: Error Domain=NSPOSIXErrorDomain Code=13 "Permission denied"
UserInfo={NSFilePath=/Volumes/timemachine-1/philwo-imac.sparsebundle/com.apple.TimeMachine.MachineID.plist,
NSLocalizedDescription=/Volumes/timemachine-1/philwo-imac.sparsebundle/com.apple.TimeMachine.MachineID.plist:
Permission denied (error 13)}

Sandbox: backupd(9170) System Policy: deny(2) file-write-data
/Volumes/timemachine-1/philwo-imac.sparsebundle/com.apple.TimeMachine.MachineID.plist

While this initially looked like a macOS issue to me, when I
downgraded Samba to 4.8.4, things worked fine again and the error
message also disappeared.

Using "git bisect", I found that this commit seems to be the culprit:
af4cb57d4f713990973f44678dc5e6d2f9cfa984 ("vfs_fruit: delete 0 byte
size streams if AAPL is enabled")

A follow-up patch and test case for this issue was posted to the
original bug that the commit referenced a few days ago:
https://bugzilla.samba.org/show_bug.cgi?id=13441. Patching this in
results in a working version of Samba for me and macOS happily making
backups again.

FYI, here's my system environment and config:

OS: Arch Linux (4.14.68-1-lts)
Filesystem: ZFS-on-Linux (0.7.10)

$ testparm
# Global parameters
[global]
disable netbios = Yes
disable spoolss = Yes
load printers = No
logging = systemd
mdns name = mdns
printcap name = /dev/null
server min protocol = SMB2
show add printer wizard = No
smb ports = 445
streams_xattr:store_stream_type = no
streams_xattr:prefix = user.
fruit:encoding = native
fruit:metadata = stream
fruit:copyfile = yes
fruit:nfs_aces = no
idmap config * : backend = tdb
ea support = Yes
printing = bsd
store dos attributes = Yes
vfs objects = catia fruit streams_xattr

[timemachine]
create mask = 0765
path = /mnt/timemachine
read only = No
valid users = @users
fruit:time machine = yes

Cheers,
Philipp



More information about the samba mailing list