commit a23aa3f5f150d06c1943e5031a239d58ef7b068c

Björn JACKE bj at SerNet.DE
Mon Oct 4 10:30:39 MDT 2010

Hi Wilco,

> commit a23aa3f5f150d06c1943e5031a239d58ef7b068c
> Author: Wilco Baan Hofman <wilco at>
> Date:   Tue Jul 27 11:13:24 2010 +0200
> Make sure that regf only writes to disk every five seconds or when flushed or destroyed
> Brings speed up on a large .reg import from 17.5s to 0.95s, over 18 times faster
> Signed-off-by: Jelmer Vernooij <jelmer at>

this is a nice performance gain but looks problematic for me in case the time
is being adjusted backwards. In case you adjust the clock a year in the past
the last_write is suddenly far away in the future and the next
flush-to-disk time will be *very* long not just 5s. Can you modify the patch so
that you use time_mono() instead of time() to see if a flush should be done and
keep the last flush time in a separate variable instead of reusing the rtc
based absolute last_write?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <>

More information about the samba-technical mailing list