Re: [Exim] MBX, UW imapd & vanishing messages

Góra strony
Delete this message
Reply to this message
Autor: Mark Rigby-Jones
Data:  
Dla: exim-users
Temat: Re: [Exim] MBX, UW imapd & vanishing messages
On Fri, 26 Jul 2002, at 10:09, Philip Hazel typed:
> The whole area of locking in Unix and Unix-like systems is a mess.


So I've been discovering :-(

> I see on the FreeBSD man page that "flock, lockf, and fcntl locks may safely
> be used concurrently" though it isn't clear what that actually means.


A quick test on 3.4-STABLE indicates that this means they do interoperate
nicely (i.e. they can't both get a write lock on the same file at the same
time).

> However, on Linux, they seem to be different.


The same applies on Compaq Tru64 (or whatever it's called this week) - on
both of these you can get seperate flock() and fcntl() write locks on the
same file at the same time.

> When I started on Exim, I got the impression that flock() was
> obsolescent, but I subsequently learned that some people have strong
> views about all of this, which is, I believe, why flock() is used in
> c-client.


Indeed, Mark Crispin seems to have "strong views" about a lot of things ;-)
(although he is fair - he describes the designers of both fcntl() and
flock() locking as cretins at various points in the c-client source...)

> The big question is: are you using NFS?


A world of no. Exim & imapd are both running on the same machine accessing
local disk.

mrj
--
              Mark Rigby-Jones, Head of Systems, ts.com Ltd
      Windsor House, 12 High Street, Kidlington, Oxford OX5 2PJ, UK
   Tel: +44-1865-856000 (Direct: +44-1865-856009) Fax: +44-1865-856001
            mrj@??? <*> http://www.community.net.uk/~mrj/