Question about Cyrus, ext3, and Linux kernel 2.4.18 bug
James Ralston
qralston+ml.info-cyrus at andrew.cmu.edu
Wed Apr 16 20:52:45 EDT 2003
On 2003-04-16 at 20:21:38-0400 I wrote:
> I just skimmed the source for cyrus-imapd-2.2.0-ALPHA, and it
> appears that Cyrus doesn't fsync() parent directories. If this is
> true (i.e., I'm not misreading the source), then the entire Cyrus
> spool *must* be mounted synchronously in order to prevent data loss.
An exception: I had forgotten that at the current time (the last time
I checked, at any rate), the ext3 journal has a side-effect of causing
directory updates to be committed whenever fsync() is called.
Nonetheless, the current ext3 journal behavior is not guaranteed, and
may change. The bottom line is that under Linux, simply calling
fsync() on critical files isn't sufficient; application must manually
call fsync() on directories which are modified by manipulating
critical files.
James
More information about the Info-cyrus
mailing list