News for hackers. Stuff that matters.
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by snapetom on Monday September 28, 2020 @08:26PM (#24622812)
Thanks for the warning about TM to NAS. Out of curiosity, were you using HFS+ and AFP via hfsprogs and Netatalk?

I set up a Pi4 with an external drive attached to it via USB3 about a year ago. I wanted to set up a solution for me and my wife's Macs. There's plenty of "tutorials" out there and found there were all pretty much the same - HFS+ and AFP. If you follow them, they work great - for a few days.

Eventually all my Macs (Mojave and Catalina) would get a Time Machine error saying the backup was corrupted and would have to build a new version. This happened a couple of times, and eventually tried using SMB. That made the problem go away. All great, so I thought.

Then, any time I had a power outage, the whole file system on the drive would get corrupted. They could only be mounted as read only, and no amount of fsck fixed it. Switching from HFS+ to ext4 fixed that issue.

Things have been pretty reliable since then. I've been able to recover a few files here and there, but haven't had to fully recover from a disaster.

TL;DR - every blog that tells you to create a TM machine/Pi backup using hfsprogs and Netatalk is wrong. Don't do it that way. Use smb and ext4

Re:APFS changes in Big Sur: how Time Machine backs up to APFS by mrpippy on Monday September 28, 2020 @11:33PM (#24623948)
That’s bizarre, I have no idea why anyone would recommend HFS+ for that. It’s a Linux system running Netatalk, which uses normal POSIX file I/O. ext4 is a far better choice.

Cargo-cult HOWTOs is the only explanation I can think of.

Re:APFS changes in Big Sur: how Time Machine backs up to APFS by snapetom on Tuesday September 29, 2020 @01:10AM (#24624342)
> Cargo-cult HOWTOs is the only explanation I can think of.

Pretty much. When I google "raspberry Pi time machine," every result I see, except one, tells you to do the HFS+/AFP method. These results include content churning sites like techradar and howtogeek.

The only site that recommends ext4/smb that comes up, fourth on my list of results, is this one: https://mudge.name/2019/11/12/using-a-raspberry-pi-for-time-...

Re:APFS changes in Big Sur: how Time Machine backs up to APFS by duskwuff on Monday September 28, 2020 @11:52PM (#24624016)
netatalk is also the wrong solution nowadays. AFP is unmaintained, both on the netatalk side and on macOS. Instead, Samba supports Time Machine backups via the "fruit" (!) extension, which also provides some nice performance improvements for macOS clients.

https://manpages.debian.org/buster/samba-vfs-modules/vfs_fru...

TL;DR though: add the following configuration to the global section of your smb.conf:

    vfs objects = fruit streams_xattr
    fruit:aapl = yes
    fruit:metadata = netatalk
And under the section for your Time Machine share:

    fruit:time machine = yes
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by nikisweeting on Tuesday September 29, 2020 @02:12AM (#24624621)
SMB on ZFS also works excellently, 4 years and counting with many power losses, ungraceful ejections, etc. never a corrupted backup.
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by epmaybe on Monday September 28, 2020 @08:55PM (#24623059)
Interesting. I have a backup using Netatalk, but on ext4. Are you saying a simple samba share should work just fine?
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by snapetom on Tuesday September 29, 2020 @02:05AM (#24624578)
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by pronoiac on Monday September 28, 2020 @11:08PM (#24623833)
Out of curiosity, how long has it been since you switched to ext4?
Re:APFS changes in Big Sur: how Time Machine backs up to APFS by snapetom on Tuesday September 29, 2020 @01:58AM (#24624544)
6 months. 3 power failures in the meantime and remounting has been flawless.