[Dovecot] How to get rid of locks
Timo Sirainen
tss at iki.fi
Sun Apr 8 12:54:20 EEST 2007
On 8.4.2007, at 12.41, Miquel van Smoorenburg wrote:
> On Sat, 2007-04-07 at 22:30 +0300, Timo Sirainen wrote:
>> Although Dovecot is already read-lockless and it uses only short-
>> lived write locks, it's be really nice to just get rid of the locking
>> completely. :)
>>
>> I just figured out that O_APPEND is pretty great. If the operating
>> system updates seek position after writing to a file opened with
>> O_APPEND, writes to Dovecot's transaction log file can be made
>> lockless.
>
> Doest his mean there's even less chance of indexes working on NFS
> (where
> O_APPEND doesn't really work) ?
No. I haven't forgotten NFS users. You missed this part:
> The O_APPEND at least doesn't work with NFS, so it'll have to be
> optional anyway.
I'm now trying to think of ways to simplify the index file handling.
That allows me to then implement NFS workarounds more easily, such as
forcing attribute cache flushing when it's needed.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 186 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20070408/2be78968/attachment.pgp
More information about the dovecot
mailing list