I've written a patch to 2.6.8 which adds extended attribute support to rsync. This is not like the plethora of patches which try to separate osx meta-data into a special appledouble file (._filename). Instead, it builds on patches/xattr.patch and just adds support for the MacOS equivalent. The good news: 1. It works fine locally and to a remote mac 2. It also preserves the finder info and resource fork (these are exposed as EAs com.apple.{Finder,ResourceFork}) The bad news: 1. EAs on MacOS need not begin with 'user.' like they do on linux. Therefore, I can't backup from a mac->linux machine. However, linux- >mac->linux works fine since the Mac preserves the 'user.' namespace. 2. 2.6.9pre2 has some sort of bug where it zeros out the datum_len of the last rsync_xa in a file. I suspect a buffer overrun somewhere, but couldn't find it, so my patch doesn't work on 2.6.9pre2. My question: is this useful? should I prefix all MacOS EAs with 'user.'?
On Wed, Oct 25, 2006 at 05:57:38PM +0200, Wesley W. Terpstra wrote:> My question: is this useful? should I prefix all MacOS EAs with 'user.'?I'd love to see such a patch, as this is the direction that I'd like to see rsync take in handling MacOS extended attributes. As for prefixing all MacOS xattrs with "user.", we'd need to come up with some rules that would preserve the xattrs for all data paths: Mac -> Mac, Mac -> Posix -> Mac, and Posix -> Mac -> Posix. So, a Mac receiver would need to be able to differentiate what entries needed the extra prefix stripped, and which did not. So, perhaps adding something like "user.N0nP0s1%." to any non "user." data (that's NonPosix spelled with 2 zeros, a one, and a percent). That would make the stripping rule pretty straight forward on the Mac side. ..wayne..
Maybe Matching Threads
- [Bug 12568] New: Integer overflow still affects xattrs.c
- vfs_fruit: xattr imcompatible with netatalk
- vfs_fruit: xattr imcompatible with netatalk
- vfs_fruit: xattr imcompatible with netatalk
- Inconsistent behavior using 3.1.2 from macOS 10.12.2 to an AFP mount