[Dovecot] 2nd REPOST: mbox vs maildir
I'm going to assume this is just not possible, or that no one has an
answer, which would lead me back to uw-imap since it does work as-is. So I'll post it again, hoping that there is a solution for this setup and that folks have just been too busy to help think about it and/or help come up with a possible solution.
Ignoring my previous message just for a second, I realized that my
config wasn't correct. First the layout:
~mail/
~mail/Drafts
~mail/Ashley-Feb09
~mail/Others-Feb09
~mail-Archives/
~mail-Archives/2009/
~mail-Archives/2009/Ashley/
~mail-Archives/2009/Ashley/Ashley-Dec09
~mail-Archives/2009/Ashley/Ashley-Nov09
~mail-Archives/2009/Ashley/Ashley-Oct09
So I (now) have this for namespaces:
namespace private { separator = / prefix = "mail/" location = mbox:~/mail:INBOX=/var/mail/%u inbox = yes hidden = no list = yes # for v1.1+ }
namespace private { separator = / prefix = "mail-Archives/" location = maildir:~/mail-Archives:LAYOUT=fs inbox = no hidden = no list = yes subscriptions = yes }
But when I'm in Thunderbird and I try to subscribe to anything that
falls inside of ~/mail-Archives/ it won't work. I can browser all the way down to the folder, but I can't see anything within that folder.
For example, consider the full path to the following 'Ashley-Dec09'
mailbox:
~mail-Archives/2009/Ashley/Ashley-Dec09
In Thunderbird, when I hit 'Subscribe' I can browse down to '2009'
and I can see 'Ashley', but I can't drill down into it and subscribe to 'Ashley-Jan09'.
What am I missing here?
Ashley M. Kirchner put forth on 2/17/2010 9:46 AM:
Hi Ashley, sorry no one had tried to help you yet. I'm not a dovecot expert, just a user, but I'll try to help.
But when I'm in Thunderbird and I try to subscribe to anything that falls inside of ~/mail-Archives/ it won't work. I can browser all the way down to the folder, but I can't see anything within that folder.
Not to be a jerk, but there is stuff in this folder, yes? What version of T-Bird, on what OS?
For example, consider the full path to the following 'Ashley-Dec09' mailbox:
~mail-Archives/2009/Ashley/Ashley-Dec09
In Thunderbird, when I hit 'Subscribe' I can browse down to '2009' and I can see 'Ashley', but I can't drill down into it and subscribe to 'Ashley-Jan09'.
Do you have any other IMAP clients working in this scenario, such as Outlook, Eudora, or webmail such as Roundcube or Squirrelmail? Eliminate the client as the source of the problem first, then troubleshoot dovecot. You can't know if it's a dovecot problem if you're only testing with one client.
Test a couple of others clients and see if they suffer this problem. I use TB 3.0.1, but I'm all mbox format here, so I can't duplicate your issue.
Also, these folders already existed, correct? T-Bird did not create them, correct? If you can, within TB, create another folder tree the same number of layers deep, and see if you run into the same or similar problems. Perform this test with two other IMAP clients as well.
-- Stan
On Wed, 2010-02-17 at 08:46 -0700, Ashley M. Kirchner wrote:
namespace private { separator = / prefix = "mail/"
Things would probably be simpler if you used prefix="" here.
location = mbox:~/mail:INBOX=/var/mail/%u
So you've mboxes..
namespace private { separator = / prefix = "mail-Archives/" location = maildir:~/mail-Archives:LAYOUT=fs
Are these really maildirs? Seems like exactly the opposite of what they're good at :) (Maildir is good for active mails, mbox for unchanging archives.)
Timo Sirainen wrote:
Things would probably be simpler if you used prefix="" here. The reason I used a prefix is for the way things show up in Thunderbird and Outlook. Without the prefix, it all falls under the same "tree" as their INBOX. By adding the prefix, they get an extra level called 'mail' where everything lives in. It's a visual thing.
namespace private { separator = / prefix = "mail-Archives/" location = maildir:~/mail-Archives:LAYOUT=fs
Are these really maildirs? Seems like exactly the opposite of what they're good at :) (Maildir is good for active mails, mbox for unchanging archives.) I guess this is where I'm confused and would love a primer on what the differences are, and when to use what. In our setup, we have:
/var/mail/%u
where the user's INBOX resides
/home/%u/mail/
where all the *active* mailboxes are, for example things
they pull out of INBOX and put in these boxes for short
term and they refer to them daily
/home/%u/mail-Archives/
this is where long term archives are, this is stuff that
comes OUT of their /home/%u/mail/ and put here, and always
stored in a yearly hierarchy, for example:
/home/%u/mail-Archives/2009/Ashley/Ashley-Dec09
/home/%u/mail-Archives/2009/Ashley/Ashley-Nov09
/home/%u/mail-Archives/2010/Ashley/Ashley-Jan10
etc.
So, am I using the wrong setup for the namespaces? Possibly, I went
by what I found online. This is the first time I've ever tried to run Dovecot. Previously we ran uw-imap.
A
On Thu, 2010-02-18 at 09:52 -0700, Ashley M. Kirchner wrote:
Timo Sirainen wrote:
Things would probably be simpler if you used prefix="" here. The reason I used a prefix is for the way things show up in Thunderbird and Outlook. Without the prefix, it all falls under the same "tree" as their INBOX. By adding the prefix, they get an extra level called 'mail' where everything lives in. It's a visual thing.
I'd think other people would also hate that. I would. :) Anyway, if it's intentional then be sure to set subscriptions=yes for that namespace too (although I think it's default anyway).
namespace private { separator = / prefix = "mail-Archives/" location = maildir:~/mail-Archives:LAYOUT=fs
Are these really maildirs? Seems like exactly the opposite of what they're good at :) (Maildir is good for active mails, mbox for unchanging archives.) I guess this is where I'm confused and would love a primer on what the differences are, and when to use what.
mbox and maildir are completely different mailbox formats. In mbox a single file contains all messages, while in maildir each message is in a different file.
/home/%u/mail-Archives/ this is where long term archives are, this is stuff that comes OUT of their /home/%u/mail/ and put here, and always stored in a yearly hierarchy, for example: /home/%u/mail-Archives/2009/Ashley/Ashley-Dec09
So Ahsley-Dec09 is a file? It sounds like you're using mbox, so you should use:
location = mbox:~/Mail-Archives
(the :LAYOUT=fs is unnecessary, because it's the default with mboxes anyway.)
So, am I using the wrong setup for the namespaces? Possibly, I went
by what I found online. This is the first time I've ever tried to run Dovecot. Previously we ran uw-imap.
It's probably a good use of namespaces, although it would be simpler if you just put archives under ~/mail/Archives/.
Timo Sirainen wrote:
location = mbox:~/Mail-Archives
(the :LAYOUT=fs is unnecessary, because it's the default with mboxes anyway.) Made the above change as you suggested. That turned my namespaces into:
namespace private { separator = / prefix = "mail/" location = mbox:~/mail:INBOX=/var/mail/%u inbox = yes hidden = no list = no # for v1.1+ }
namespace private { separator = / prefix = "mail-Archives/" location = mbox:~/mail-Archives inbox = no hidden = no list = yes subscriptions = yes }
Now when I open Outlook, I get nothing except the INBOX. I can't
see anything else. When I go into 'IMAP Folders' and hit refresh, I see
the INBOX file, and the tree for 'mail-Archives', but I can't see any
files (mailboxes) within that tree, so I can't subscribe to anything.
The 'mail/' namespace doesn't seem to exist since it doesn't show up at all.
Checking Thunderbird, I can see and subscribe to anything in
'mail/', but like Outlook I can only see the tree in 'mail-Archives' but I can't see the individual files (mailboxes) within the folders to be able to subscribe to them.
It's probably a good use of namespaces, although it would be simpler if you just put archives under ~/mail/Archives/. That was done for remote backup purposes. This way we can backup the user's ~mail/ folder every night, and the ~mail-Archives/ once a month.
-- W | It's not a bug - it's an undocumented feature. +-------------------------------------------------------------------- Ashley M. Kirchner mailto:ashley@pcraft.com . 303.442.6410 x130 IT Director / SysAdmin / Websmith . 800.441.3873 x130 Photo Craft Imaging . 2901 55th Street http://www.pcraft.com ..... . . . Boulder, CO 80301, U.S.A.
On Thu, 2010-02-18 at 10:21 -0700, Ashley M. Kirchner wrote:
namespace private { separator = / prefix = "mail/" location = mbox:~/mail:INBOX=/var/mail/%u inbox = yes hidden = no list = no # for v1.1+ }
namespace private { separator = / prefix = "mail-Archives/" location = mbox:~/mail-Archives inbox = no hidden = no list = yes subscriptions = yes }
Those look correct.
Now when I open Outlook, I get nothing except the INBOX. I can't
see anything else. When I go into 'IMAP Folders' and hit refresh, I see the INBOX file, and the tree for 'mail-Archives', but I can't see any files (mailboxes) within that tree, so I can't subscribe to anything.
The 'mail/' namespace doesn't seem to exist since it doesn't show up at all.Checking Thunderbird, I can see and subscribe to anything in
'mail/', but like Outlook I can only see the tree in 'mail-Archives' but I can't see the individual files (mailboxes) within the folders to be able to subscribe to them.
Well, clients can become confused a bit too easily. Try talking IMAP protocol directly: http://wiki.dovecot.org/TestInstallation
After logging in, the important commands to try would be:
a LIST "" * b LSUB "" * c SELECT mail-Archive/something-that-actually-exists d SUBSCRIBE mail-Archive/something-that-actually-exists
Where does it fail?
Timo Sirainen wrote:
Well, clients can become confused a bit too easily. Try talking IMAP protocol directly: http://wiki.dovecot.org/TestInstallation
After logging in, the important commands to try would be:
a LIST "" * b LSUB "" * c SELECT mail-Archive/something-that-actually-exists d SUBSCRIBE mail-Archive/something-that-actually-exists
Where does it fail?
Ok, we're getting closer. It failed when selecting a mailbox,
permission denied. And I figured out why ... for some reason when the user was cloned from the old server to this one, their -x bit didn't stick for that mail-Archives/ folder. Now that that's fixed, I *can* see and *can* subscribe to the individual mailboxes within any of the archived folders.
But, there's a big difference between how Thunderbird sees things
and what Outlook sees, and I'm almost certain it's a problem with the client:
Thunderbird will see exactly what I have subscribed to, stuff in
mail/ and stuff in mail-Archives/. Outlook will *not* see mail/, at all. And it *will* see *everything* that's in mail-Archives/, whether I'm subscribed to it or not, it shows up. That's ... kind of annoying to say the least.
On Thu, 2010-02-18 at 11:06 -0700, Ashley M. Kirchner wrote:
Thunderbird will see exactly what I have subscribed to, stuff in
mail/ and stuff in mail-Archives/. Outlook will *not* see mail/, at all. And it *will* see *everything* that's in mail-Archives/, whether I'm subscribed to it or not, it shows up. That's ... kind of annoying to say the least.
Deleting and recreating the Outlook account might be the easiest fix.
Timo Sirainen wrote:
Deleting and recreating the Outlook account might be the easiest fix Ok, that solved the seeing everything problem. But Outlook still won't see the user's 'mail/' folder with mailboxes in it. Could that be because I don't have a 'subscriptions=' line in that namespace? It works fine for Thunderbird ...
-- W | It's not a bug - it's an undocumented feature. +-------------------------------------------------------------------- Ashley M. Kirchner mailto:ashley@pcraft.com . 303.442.6410 x130 IT Director / SysAdmin / Websmith . 800.441.3873 x130 Photo Craft Imaging . 2901 55th Street http://www.pcraft.com ..... . . . Boulder, CO 80301, U.S.A.
Ashley M. Kirchner wrote:
Timo Sirainen wrote:
Deleting and recreating the Outlook account might be the easiest fix Ok, that solved the seeing everything problem. But Outlook still won't see the user's 'mail/' folder with mailboxes in it. Could that be because I don't have a 'subscriptions=' line in that namespace? It works fine for Thunderbird ... Actually, I take that back. For a few reasons:
a) I had 'list = no' in the 'mail/' namespace. Setting it to
'yes' allows Outlook to now see that namespace correctly. However, b) Every time Outlook gets launched, both the 'mail/' and 'mail-Archives/' show up briefly, then disappear. I have to hit a 'Update Folder List' for them to re-appear.
The last issue I'm not sure is actually a Dovecot problem though.
But if anyone else is having this behavior, I would love to hear if there's a solution.
-- W | It's not a bug - it's an undocumented feature. +-------------------------------------------------------------------- Ashley M. Kirchner mailto:ashley@pcraft.com . 303.442.6410 x130 IT Director / SysAdmin / Websmith . 800.441.3873 x130 Photo Craft Imaging . 2901 55th Street http://www.pcraft.com ..... . . . Boulder, CO 80301, U.S.A.
Spoke too fast. I can't move mailboxes across namespaces. Is that
a limitation? For example, if I have a mailbox in 'mail/' that I want to move into 'mail-Archives/' I get an error saying:
The current command did not succeed. The mail server responded:
Can't rename mailbox to another storage type.
This is through Thunderbird. I was able to do this with uw-imap.
-- W | It's not a bug - it's an undocumented feature. +-------------------------------------------------------------------- Ashley M. Kirchner mailto:ashley@pcraft.com . 303.442.6410 x130 IT Director / SysAdmin / Websmith . 800.441.3873 x130 Photo Craft Imaging . 2901 55th Street http://www.pcraft.com ..... . . . Boulder, CO 80301, U.S.A.
On Thu, 2010-02-18 at 11:40 -0700, Ashley M. Kirchner wrote:
Spoke too fast. I can't move mailboxes across namespaces. Is that a limitation? For example, if I have a mailbox in 'mail/' that I want to move into 'mail-Archives/' I get an error saying:
The current command did not succeed. The mail server responded:
Can't rename mailbox to another storage type.
Yeah, Dovecot v1.2 doesn't like this. v2.0 allows it though.
Timo Sirainen wrote:
Yeah, Dovecot v1.2 doesn't like this. v2.0 allows it though.
In that case, Timo you have solved all of my configuration problems
today. With Dovecot 2.0 still in beta, I'll just sit back and wait.
Thank you very much for all your help today!
My next task? Figuring out mail quotas ... just my kinda day.
participants (3)
-
Ashley M. Kirchner
-
Stan Hoeppner
-
Timo Sirainen