[Dovecot] IMAP creates .userid directory even after pop.

Jorgen Lundman lundman at lundman.net
Fri Mar 21 09:51:44 EET 2008


 > convert_mail =
 > 
mbox:/export/mbox/migrate/%u:INBOX=/export/mbox/migrate/%u/%u:INDEX=Maildir:%h/mail/ 


This is the problem. The line "INBOX=/export/mbox/migrate/%u/%u" is what 
creates the .user directory.

We had to go with %u/%u because if %u is a file you get the error:

POP3(user1): open() failed with subscription file 
/export/mbox/migrate/user1/.subscriptions: Not a directory

and we fail to see any way to tell it not to look for the subscriptions 
file. However, we commented out the copy_subscriptions line from 
convert_plugin.c, and left the convert line as:

convert_mail = 
mbox:/export/mbox/migrate/%u:INBOX=/export/mbox/migrate/%u:INDEX=Maildir:%h/mail/

Now it works well, does not create the user/mail/.user directory, DOES 
convert into the user/mail/cur/ directory.

It still creates a user/Maildir/ (+ .imap/INBOX) directory, which seems 
to be mostly useless, but we can live with that. (Just remove them all 
when mbox are converted).

Lund


Jorgen Lundman wrote:
> 
> 
> We are currently running dovecot-1.0.10 on Solaris 10 x86.
> 
> Several users has noticed that they get different emails when using pop 
> vs using IMAP. When I check a user's home directory, I find the 
> following situation:
> 
> /nfs/mail/1/1/hiro.11/mail/:
> drwx------   6 176785   1000         512 Mar 21 07:53 .
> drwxr-xr-x   3 176785   1000         512 Feb 29 17:01 ..
> drwx------   5 176785   1000         512 Feb 19 12:52 .hiro_11_c7
> drwx------   2 176785   1000        8192 Mar 21 07:53 cur
> -rw-------   1 176785   1000        1445 Mar 21 07:53 dovecot-uidlist
> -rw-------   1 176785   1000         144 Mar 21 07:53 dovecot.index
> -rw-------   1 176785   1000       57344 Mar 21 07:53 dovecot.index.cache
> -rw-------   1 176785   1000       66424 Mar 21 07:53 dovecot.index.log
> drwx------   2 176785   1000        7680 Mar 21 10:34 new
> drwx------   2 176785   1000        1536 Mar 21 10:34 tmp
> 
> /nfs/mail/1/1/hiro.11/mail/.hiro_11_c7/:
> drwx------   5 176785   1000         512 Feb 19 12:52 .
> drwx------   6 176785   1000         512 Mar 21 07:53 ..
> drwx------   2 176785   1000         512 Feb 19 12:52 cur
> -rw-------   1 176785   1000        1037 Feb 19 12:52 dovecot-uidlist
> -rw-------   1 176785   1000         120 Feb 19 12:52 dovecot.index
> -rw-------   1 176785   1000          24 Feb 19 12:52 dovecot.index.log
> -rw-------   1 176785   1000           0 Feb 19 12:52 maildirfolder
> drwx------   2 176785   1000        1536 Feb 19 12:52 new
> drwx------   2 176785   1000        1536 Feb 19 12:52 tmp
> 
> I suspect that is less than ideal. What exactly is creating these 
> folders, and how do we stop it? I can clean it up ok (which I'd rather 
> do as one maintenance) but only once I know it wont happen again.
> 
> Should also mention that we have a mbox convert script running for a 
> couple of months, to convert their old mail. Then it will be removed:
> 
> convert_mail = 
> mbox:/export/mbox/migrate/%u:INBOX=/export/mbox/migrate/%u/%u:INDEX=Maildir:%h/mail/ 
> 
> 
> Should also mention, one server in the cluster was incorrectly running 
> version dovecot-1.0.2 (boy was that fun to track down).
> 
> Lund
> 
> 

-- 
Jorgen Lundman       | <lundman at lundman.net>
Unix Administrator   | +81 (0)3 -5456-2687 ext 1017 (work)
Shibuya-ku, Tokyo    | +81 (0)90-5578-8500          (cell)
Japan                | +81 (0)3 -3375-1767          (home)


More information about the dovecot mailing list