ventura rsync functionality to msdos/usb filesystems

I use rsync to maintain 14GB of usb media (ms-dos fat). Often the changes are subtle, so the command typically takes under 30 seconds.


However, since upgrading to Ventura the workflow has broken. Here is a typical example:


rsync -aP --modify-window=1 $HOME/usbfiles/ /Volumes/usbstick/usbfiles/


With Venture, every invocation of the command transfers ALL OF THE FILES. This breaks the functionality of rsync, and changes a 30 second refresh operation to a 30 minute (or greater) file transfer.


Invoking the -i option with rsync shows that a time mismatch triggers a transfer of each file from the source directory. Indeed, after the transfer the files do not reflect their original timestamp, which rsync normally maintains, rather their modify time is set to the transfer time.


I presume this is a bug in the ventura kernel msdos filesystem handling?


As this is very problematic. Is their any short term workaround before a system update can be applied?



MacBook Air 13″, macOS 13.0

Posted on Nov 16, 2022 12:32 PM

Reply
Question marked as Top-ranking reply

Posted on Dec 6, 2022 11:45 AM

mu-on, thanks for this data point. I tried your technique and confirm mode 700 file permissions successfully workaround rsync APFS to VFAT partitions where mode 644 APFS files fail. This technique is only applicable if the filesystem will be read by Linux or Microsoft, not sure if other operating systems can read VFAT.


I also confirmed the mode 700 workaround does not help rsync transfers to ms-dos partitions.


This issue is also reported on the rsync github page https://github.com/WayneD/rsync/issues/412 where I've uploaded cli commands to reproduce the issue https://github.com/WayneD/rsync/files/10126464/apple-discussion-254383328.txt


In those commands it looked like rsync would fail, and work, on alternate invocations. I have since observed that on regular invocations (when rsync is expected to set the timestamp), subsequent rsync invocations would work 50% of the time, per file. Ie, if 10 files were transferred, approximately five of them would be arbitrarily re-transferred, with every subsequent rsync.


Nevertheless, the procedure of "touch -r" from every src file to every dest file, after every rsync, is effective to prevent re-transfer of unchanged files on the next invocation. It is unnecessary re-touch unchanged files, but the touch operation is lightweight so I just do it every time, to workaround the issue.


A ktrace should shed some light on what's going on with the ms-dos arbitrary re-transfers, and the impact of vfat permissions on setting the destination timestamps.

Similar questions

17 replies

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

ventura rsync functionality to msdos/usb filesystems

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.