[Dovecot] NFS

Miquel van Smoorenburg miquels at cistron.nl
Thu Apr 27 02:45:40 EEST 2006


On Wed, 2006-04-26 at 13:26 +0200, Miquel van Smoorenburg wrote:
> On Tue, 2006-04-25 at 17:33 +0300, Timo Sirainen wrote:
> > I've finally managed to run Dovecot without errors in two computers with
> > maildir and indexes stored in NFS. I added a page to wiki about this:
> > 
> > http://wiki.dovecot.org/NFS
> > 
> > Suggestions how to keep attribute cache enabled but to allow Dovecot to
> > specifically request not to use a cached value (when it's important)
> > would be welcome.
> 
> Timo, you use Debian - if you have liblockfile-dev installed, the
> manpage of lockfile-create(3) has a section called "REMOTE FILE SYSTEMS
> AND THE KERNEL ATTRIBUTE CACHE".
> 
> See the part on chmod() there on how to invalidate the attribute cache
> for one file on Linux.
> 
> Manpage is attached.

I'be just tested on Linux 2.6 and freebsd 4.10 some more. It appears
that the chmod trick doesn't work on freebsd, and freebsd 4.10 doesn't
have support for fntl locking either AFAIK.

However both of them invalidate the attribute cache of a file directly
when you do fd = open("file", O_WRITE|O_APPEND); which makes sense.
Perhaps you can use that as a semi-portable way to invalidate a files
attribute cache.

Mike.



More information about the dovecot mailing list