On Wed, Jul 19, 2006 at 08:11:39PM +0300, Mike Jackson wrote:
>  Checking the mailbox with Courier causes filesystem corruption (wrong 
> hard link count, and truncation of the message filename):
> 
> [EMAIL PROTECTED] maildirs]# find jacksonm/
> jacksonm/
> find: WARNING: Hard link count is wrong for jacksonm/: this may be a bug 
> in your filesystem driver.  Automatically turning on find's -noleaf 
> option.  Earlier results may have failed to include directories that 
> should have been searched.
> jacksonm/Maildir
> jacksonm/Maildir/cur
> jacksonm/Maildir/cur/15HB1W~B
...
>  Are these known bugs? Are they bugs in Samba or Courier IMAP?

No userland program should be able to corrupt a filesystem in this way, at
least not one not running as root (and courier-imap switches to a normal
user before it opens the Maildir).

This might be a bug in XFS, or some strange interaction between XFS and
Samba.

Truncation of message filenames is almost certainly a Samba-ism. Note the
format of the name: XXXXXX~X. This to me looks suspiciously like how Windows
maps long filenames into MS-DOS 8.3 format.

> Any 
> advice on how to proceed to resolution?

Well, there's one thing you can try first: I seem to remember that
Windows-based filesystems have problems with colons in filenames. However,
the Maildir structure specifies that colons must be used whenever a file is
moved from new/ to cur/, see http://cr.yp.to/proto/maildir.html

   "When you move a file from new to cur, you have to change its name from
   uniq to uniq:info"

I seem to remember there's a way to compile courier so that it uses a
different separator, specifically for the case where you have a Microsoft
storage backend. Google or search the list archives.

Otherwise, unless you want to dig very deeply into the operation of Samba,
trace the filesystem operations it's doing on the fileserver side, and
analyse them, probably your best bet would be to get rid of XFS and Samba.

You can get rid of Samba by switching to NFS. NFS may have its problems, but
at least it has reasonably well understood semantics in a Unix environment.
Trying to map Unix semantics to Microsoft (SMB) and back to Unix again is
pretty hairy IMO.

Regards,

Brian.

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Courier-imap mailing list
[email protected]
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-imap

Reply via email to