[Dovecot] Can't create subfolders of my INBOX or delete folders with IMAP

Magnus Holmgren holmgren at lysator.liu.se
Fri Mar 4 00:28:45 EET 2005


Matthew Exon wrote:
> Magnus Holmgren wrote:
> 
>> Well, the solution could be using Maildir instead of mbox as mail
>> storage format. Since the traditional mbox format uses one file per mail
>>  folder, and one directory per subfolder, you can't keep both mail and
>> folders in the same folder. (A folder is either a file containing mail
>> or a directory containing other files and directories, but not both).
> 
> OK, that was something I was considering - I just didn't know if it
> really would solve the problem.  It raises a bunch of questions though:
> 
> 1) Is there some system wide setting for this?  I don't want to port my
> own mailboxes, and then have it be the same old mbox stuff for the next
> person I create an account for.  A lot of the documentation sorta
> answers this, but it assumes you're setting up a brand new system, not
> trying to modify an existing one.

Yes, it's a system wide setting, although you could override it by
setting $MAIL somehow. See the example dovecot.conf. I have

default_mail_env = maildir:/var/mail/%u

which means that each user has his mail under /var/mail/ (and only
there), but in Maildir format (which answers your second #2 question :-).

> 2) What's the best way to do this on a Debian system?  Was there some
> setting I missed when I was setting up the box?  I would much rather set
> a debconf setting than fool around inside a config file.

I have told Exim to put incoming mail in Maildir format as above. It
will then create the necessary directories, if you don't do it when you
create new users. If you use some other (Maildir-capable) MTA/MDA, you
should be able to configure it accordingly.

> 2) What's going to happen to /var/spool/mail?  That looks like a mbox
> thing.  I'd much rather have all my mail in one place, rather than in
> two places like now.
> 
> I installed mb2md, but then I got cold feet about whether it was likely
> to work or not, so I haven't run it yet...

So in short, the most important part is to tell your MDA that you want
mail delivered into maildirs (and of course where you want it). You also
need to convert all mailboxes. I think Dovecot should be the least of
your worries.

-- 
Magnus Holmgren
holmgren at lysator.liu.se


More information about the dovecot mailing list