[Dovecot] Dovecot-1.0.beta1: New mail sometimes fails to appear

Timo Sirainen tss at iki.fi
Sun Jan 22 15:01:47 EET 2006


On Sun, 2006-01-22 at 14:50 +0200, Tom Alsberg wrote:
> Timo Sirainen wrote:
> > Maybe NFS is caching Dovecot's stat() calls which check if the mbox has
> > changed?
> 
> I will try to check whether this is the case.  You mean the NFS client 
> (FreeBSD kernel) caching, not the server (NetApp), right?  Something 
> like this happening on the server seems not to make any sense to me.

Right, in client side.

> However I doubt that, as I've never had anything like that happening (we 
> use FreeBSD and NFS all the time) - I'm using FreeBSD 5.4 on my 
> workstation too, and there when reading mail (with mutt) I always see 
> new mail.

Well, that's pretty much all I can think of currently.. In non-NFS
environment I haven't heard of problems with new mails not being found.

It's also possible that mutt does something slightly differently which
causes NFS cache to be reset. You could maybe try this with Dovecot too.
Although I'm not sure how that would be done.. chmod() apparently at
least resets it.

Hmm. From mutt's configure:

AC_ARG_ENABLE(nfs-fix, [  --enable-nfs-fix           Work around an NFS with broken attributes caching ],
        [if test x$enableval = xyes; then
                AC_DEFINE(NFS_ATTRIBUTE_HACK)
        fi])

Which does after each stat():

#ifdef NFS_ATTRIBUTE_HACK
  if (sb.st_mtime > sb.st_atime)
  {
    newtime.modtime = sb.st_mtime;
    newtime.actime = time (NULL);
    utime (ctx->path, &newtime);
  }
#endif

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20060122/4e55c1e8/attachment-0001.pgp


More information about the dovecot mailing list