3 ms·
In the case of atomic file writing, the rename() doesn't cause a fsync of the parent directory?
by RenThraysk 2y ago
In the case of atomic file writing, the rename() doesn't cause a fsync of the parent directory?
- holowoodman 2y agoDepends on the file system. In NFS, yes. In others, maybe not.
- altfredd 2y ago> rename() doesn't cause a fsync of the parent directory? It does not. At best it will schedule a journal commit asynchronously (I recall that ext4 maintainer complained about adding this "workaround for buggy user code" on lkml). If you want to receive an IO error when renaming fails, make sure to call fsync() yourself.