Having both atime and noatime on Samba server

Lapis asked:

I’m looking to improve my current setup:

I have a samba server (debian), that share a folder located in an ext4 partition, mounted with relatime option.

I’m using the files access time for various reasons on my windows and linux clients, and it’s working well.

Now I’m regularly making a backup of that folder (with rsync), but, as you have guessed, that reset all the access times to the current time.

I tried many solution, but I think I’ve exhausted everything I could find…

Any ideas on how I could read those files to backup them without updating the acces time ? The solution I’m using is mount -o remount,noatime /mnt/hdd before each backup, and the opposite once the backup is done.

Thanks by advance 🙂

My answer:


Why go with complicated stuff when rsync already has a command line option for this?

From the man page:

       --atimes, -U             preserve access (use) times

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.