[Dovecot] index location
Greetings.
We are testing with 1.2.9 and have found that with mail_full_filesystem_access set to 'yes', we cannot force indexes for folders under ~/mail to be stored in /var/dovecot/indexes/%u. /var/dovecot/indexes/%u/.imap/INBOX/dovecot.index* is created just fine, but everything else ends up in ~mail/.imap.
If I change mail_full_filesystem_access to 'no', then all indexes are created in the expected location:
$ ls -la /var/dovecot/indexes/blitz/ total 4 drwxr-xr-x 4 blitz popuser 512 Jan 25 11:46 . drwxrwxr-x 5 root popuser 512 Jan 22 16:16 .. drwxr-xr-x 3 blitz popuser 512 Jan 22 16:16 .imap drwxr-xr-x 3 blitz popuser 512 Jan 25 11:46 mail
(I probably need to set the sticky bit for this, but for testing this is OK)
We are setting the index location from /etc/passwd-dove:
blitz:x:14267:500::/usr/users/dialups/blitz::userdb_mail=mbox:~/:INBOX=/var/mail/%u:INDEX=/var/dovecot/indexes/%u
Is there a way to get this to function the way we'd like, with all indexes stored in /var/dovecot/indexes/u% ?
My apologies if I missed an explanation about this in the list archive.
Dave
I continue to experience this issue, so I thought I would re-post my inquiry.
We are testing with 1.2.9 and have found that with mail_full_filesystem_access set to 'yes', we cannot force indexes for folders under ~/mail to be stored in /var/dovecot/indexes/%u. /var/dovecot/indexes/%u/.imap/INBOX/dovecot.index* is created just fine, but everything else ends up in ~mail/.imap.
If I change mail_full_filesystem_access to 'no', then all indexes are created in the expected location:
$ ls -la /var/dovecot/indexes/blitz/ total 4 drwxr-xr-x 4 blitz popuser 512 Jan 25 11:46 . drwxrwxr-x 5 root popuser 512 Jan 22 16:16 .. drwxr-xr-x 3 blitz popuser 512 Jan 22 16:16 .imap drwxr-xr-x 3 blitz popuser 512 Jan 25 11:46 mail
(I probably need to set the sticky bit for this, but for testing this is OK)
We are setting the index location from /etc/passwd-dove:
blitz:x:14267:500::/usr/users/dialups/blitz::userdb_mail=mbox:~/:INBOX=/var/mail/%u:INDEX=/var/dovecot/indexes/%u
Is there a way to get this to function the way we'd like, with all indexes stored in /var/dovecot/indexes/u% ?
My apologies if I missed an explanation about this in the list archive.
Dave
On Wed, 2010-01-27 at 09:42 -0800, Dave Brenner wrote:
I continue to experience this issue, so I thought I would re-post my inquiry.
We are testing with 1.2.9 and have found that with mail_full_filesystem_access set to 'yes', we cannot force indexes for folders under ~/mail to be stored in /var/dovecot/indexes/%u. /var/dovecot/indexes/%u/.imap/INBOX/dovecot.index* is created just fine, but everything else ends up in ~mail/.imap.
If I change mail_full_filesystem_access to 'no', then all indexes are created in the expected location:
Looks like a bug. I'll look at it later. Do you really need it to be "yes"? :)
On 1/27/2010 12:13 PM, Timo Sirainen wrote:
Looks like a bug. I'll look at it later. Do you really need it to be "yes"? :)
I would prefer that it be, since we have quite a few users who have ~/mail hard-coded as their IMAP root path (we're on UW currently). We could get by with the split indexing for a while. It's not a show-stopper, but it does create some clutter on clients that cannot be configured to hide unsubscribed folders (for example, iPhone).
Having said all that, I am very impressed with the performance of Dovecot with mboxes. UW+SquirrelMail+IMAPProxy has been a very painful experience for us and Dovecot so far appears to be our ticket to improving user experience without a conversion to maildir. Thanks for your efforts.
Dave
On Wed, 2010-01-27 at 13:01 -0800, Dave Brenner wrote:
On 1/27/2010 12:13 PM, Timo Sirainen wrote:
Looks like a bug. I'll look at it later. Do you really need it to be "yes"? :)
I would prefer that it be, since we have quite a few users who have ~/mail hard-coded as their IMAP root path (we're on UW currently).
Did you read http://wiki.dovecot.org/Namespaces
On 1/27/2010 1:25 PM, Timo Sirainen wrote:
Did you read http://wiki.dovecot.org/Namespaces
I've been tinkering with it and have not yet gotten it to do exactly what I want. Adding the sample namespaces for UW backward compatibility causes the client to show the full ~/mail path in the subscribed folder pick list. Plus, now my autocreate rules, which use paths like ~/mail/Spam and ~/mail/Trash, are causing new folders to be created in ~/, e.g. ~/Spam. So, I end up with ~/Spam and ~/mail/Spam. Even if I clear the home level stuff out of .mailboxlist (we rebuilt) and delete the actual folders, they come right back on first login. So, I think autocreate is confused by the namespaces.
I'll need to play with it some more. Any suggestions you may have would be welcome as well.
Dave
On Thu, 2010-01-28 at 12:55 -0800, Dave Brenner wrote:
On 1/27/2010 1:25 PM, Timo Sirainen wrote:
Did you read http://wiki.dovecot.org/Namespaces
I've been tinkering with it and have not yet gotten it to do exactly what I want. Adding the sample namespaces for UW backward compatibility causes the client to show the full ~/mail path in the subscribed folder pick list. Plus, now my autocreate rules, which use paths like ~/mail/Spam and ~/mail/Trash, are causing new folders to be created in ~/, e.g. ~/Spam. So, I end up with ~/Spam and ~/mail/Spam. Even if I clear the home level stuff out of .mailboxlist (we rebuilt) and delete the actual folders, they come right back on first login. So, I think autocreate is confused by the namespaces.
The idea is that you should make everything work with the default prefix="" namespace and mail_location=mbox:~/mail. So your subscriptions should have e.g. "Spam" without prefix. Your autocreate rules should have "Spam" without prefix. After all that works properly, you create the compatibility namespaces that are used only by the clients that have already explicitly configured them.
On 1/28/2010 12:59 PM, Timo Sirainen wrote:
The idea is that you should make everything work with the default prefix="" namespace and mail_location=mbox:~/mail. So your subscriptions should have e.g. "Spam" without prefix. Your autocreate rules should have "Spam" without prefix. After all that works properly, you create the compatibility namespaces that are used only by the clients that have already explicitly configured them.
That did the trick. Now all my indexes are in /var/dovecot/indexes/%u/.imap (no more mail subdirectory) and while users can use ~/mail as their root path, they can't see it, or anything above it, in their folder tree. Perfect!
The only unexpected thing I ran into is that the full client root path is still required for the expire and quota plugins. So, if some clients use a blank root, while others use ~/mail, ~someuser/mail or mail/, you have to allow for all of them or you won't necessarily get a match (expire timestamps are not added to db; quota "ignores" are not processed). A few extra quota rules and expire folders took care of the problem. I can live with this config. :-)
Thank you for the assistance.
Dave
On 29.1.2010, at 3.54, Dave Brenner wrote:
The only unexpected thing I ran into is that the full client root path is still required for the expire and quota plugins. So, if some clients use a blank root, while others use ~/mail, ~someuser/mail or mail/, you have to allow for all of them or you won't necessarily get a match (expire timestamps are not added to db; quota "ignores" are not processed). A few extra quota rules and expire folders took care of the problem. I can live with this config. :-)
Hmm. See if adding "alias_for = " for the extra namespaces helps. If it doesn't, let me know and I'll fix those.
On 1/28/2010 6:09 PM, Timo Sirainen wrote:
Hmm. See if adding "alias_for = " for the extra namespaces helps. If it doesn't, let me know and I'll fix those.
Well, I'm finally getting back to my configuration after a few days. Here's what I've been up to:
I created these namespaces:
namespace private { separator = / prefix = ~/mail/ list = no hidden = yes } namespace private { separator = / prefix = ~%u/mail/ alias_for = ~/mail/ list = no hidden = yes } namespace private { separator = / prefix = ~/mail alias_for = ~/mail/ list = no hidden = yes } namespace private { separator = / prefix = mail/ alias_for = ~/mail/ list = no hidden = yes }
and configured the expire plugin with these mailboxes
expire = Trash 1 Spam 1
My results with different root paths on the client:
~/mail :
Feb 01 12:27:53 IMAP(blitz): Info: expire: No expiring in mailbox: ~/mail/Trash
~/mail/ :
Feb 01 12:49:04 IMAP(blitz): Info: expire: No expiring in mailbox: ~/mail/Trash
mail/ :
Feb 01 12:39:10 IMAP(blitz): Info: expire: No expiring in mailbox: mail/Trash
No path:
Feb 01 12:36:10 IMAP(blitz): Info: expire: Mails expire in 4294880896 secs in mailbox: Trash
So, it seems that even with the aliased namespaces, the mailboxes specified for the expire plugin must match the full path supplied by the client. I've tried re-ordering the namespaces, with different ones being the canonical namespace, to no avail.
Dave
participants (2)
-
Dave Brenner
-
Timo Sirainen