question about file write time update?

Jeremy Allison jra at
Mon Mar 12 15:49:23 UTC 2018

On Mon, Mar 12, 2018 at 12:36:33PM +0800, ssdl.566 wrote:
>  Hi  Jeremy:
>               First of all, thank you very much for your replies to my previous
> questions.
>               Recently, I have a question about write time update on normal
> files.
>               I noticed that the file will be marked modified 2 second later
> after first write , and the write time didnot get changed for subsequent writes
> until close.
>               I want to know why? is this the requirement by protocol? for what
> reason?
>              another question: 
>               is it possible that samba donot manage write time in tdb, just
> store and fetch file write time  from underlying filesystem instead? 

Nope. If we do it that way we don't pass the Windows tests.

Windows has a delayed write time update (remember, SMBX is
just "Windows on the wire") as part of the NTFS spec, and
so to match application expected behavior we must do it as
Windows does.

For SMB3+ unix extensions, we could just report the underlying
filesystem times.

More information about the samba-technical mailing list