Archive for January 16, 2006

Monday, January 16, 2006 [Tweets] [Favorites]

Fixing rsync on Tiger

Mac OS X 10.4.4 recently shipped, and yet after four OS updates rsync is still broken. It frequently crashes when using the -E/--extended-attributes option, it doesn’t preserve the modification dates of files with resource forks, and it copies all the extended attributes even if they haven’t changed.

J.D. Bakker comes to the rescue with a patch that claims to fix the most severe problems. He’s written clear instructions for how to apply it, and it seems to work. At last, it looks like I’ll be able to keep my PowerBook synchronized.

Actually, the first few times I tried it, it didn’t work. I kept getting these errors:

rsync error: protocol incompatibility (code 2) at sender.c(59)
rsync: fstat failed: No such file or directory (2)

and on different files each time. Mac OS X Hints suggested disabling Spotlight, and that stopped the errors. I would have thought that Spotlight should be disabled on the target volume, since it was the one being modified, however I found that it was necessary to disable it on the source volume. Then it worked.

For this and other reasons, I seem destined to always have Spotlight turned off. Thus, I really appreciate it when developers don’t rely on Spotlight being available. It’s cool if you make your app’s data available to Spotlight, but I shouldn’t have to turn on Spotlight to search from within your app.