Hi, Alberto Sentieri wrote: > ls -ls "${NAME}" > Note that the /mnt/u1/rw/receipt is a SMB folder. I got this result: > 1024 -rwxr-xr-x 1 u1 u1 10 Apr 30 12:20 /mnt/u1/rw/receipt/test2.txt > [...] > I run the same binary and script on my debian stretch workstation, and got > 4 -rwxr-xr-x 1 u1 u1 10 Feb 5 2017 /mnt/u1/rw/receipt/test2.txt
It is quite remarkable that the SMB file is reported to use 1024 blocks for storing 10 bytes. ------------------------------------------------------------------------- I am still not convinced that SYS_utimensat is to blame. What do you get if you sleep for 3 seconds before performing it ? If still the file timestamp changes with that sleep: What happens if you close the fd without calling utimensat and re-open the file for applying utimensat only then ? (What if you let sleep between between close and re-open ?) Have a nice day :) Thomas