Option to not update Atime on filesystems not mounted noatime
hashproduct+rsync at gmail.com
Thu Aug 2 15:57:43 GMT 2007
On 8/2/07, Matthias Schniedermeyer <ms at citd.de> wrote:
> I once wrote to the mutt-maillinglist why mutt doesn't set atime
> explicitly, so that it works even on noatime-mounted filesystems, but i
> was totally ignored. Maybe that question was just stupid.
Setting the atime explicitly makes perfect sense to me. If you were
ignored, the mutt community must have been stubborn or (more likely)
> Could you give me a hint, so i can patch my local rsync?
Add the option (--o_noatime or whatever you want to call it) in all
the appropriate places in options.c, including a variable to store
whether the option is on. Then declare the variable in sender.c and
modify the do_open call in send_files to pass NO_ATIME if the variable
is true. There are a number of do_open calls, but the one in
send_files is the most important (it opens the source files).
Additionally, if you care about listing source directories without
hitting their atimes, there seems to be information about how to do it
at http://www.cygwin.com/ml/libc-alpha/2005-09/msg00104.html ; the
relevant opendir is in send_directory in flist.c .
If you send your patch to the list, Wayne would be likely to include
it in patches/ of the source distribution for the benefit of others.
More information about the rsync