svn commit: r295800 - head/usr.bin/cap_mkdb

Dmitry Marakasov amdmi3 at amdmi3.ru
Sat Feb 20 00:04:44 UTC 2016


* Stefan Esser (se at FreeBSD.org) wrote:

> Log:
>   Remove O_SYNC from the options passed to dbmopen().
>   
>   The output file is created as a temporary file that is moved over the
>   existing file after completion. Thus there is no need to immediately
>   flush all created db records to the temporary file.

How is it guaranteed that the temporary file is completely written to
disk before it's moved over the old database? I've run cap_mkdb under
ktrace and I don't see fsync call there.

-- 
Dmitry Marakasov   .   55B5 0596 FF1E 8D84 5F56  9510 D35A 80DD F9D2 F77D
amdmi3 at amdmi3.ru  ..:  jabber: amdmi3 at jabber.ru      http://amdmi3.ru


More information about the svn-src-head mailing list