Andy:
Namespaces are not a concept peculiar to Dovecot -- they're an extension to the IMAP protocol and are documented in RFC 2342.
<http://www.faqs.org/rfcs/rfc2342.html>
Think of a namespace as a separate tree containing mail. One of the more common applications of namespace is to have one's normal private namespace for one's personal mail, and a shared namespace for group mailboxes.
Dovecot, as of the 1.0 tree, supports some namespace functionality -- basically the parts that are most useful (IMHO).
Namespaces in mbox format consist of a directory hierarchy containing mailboxes as plain files within that tree. A mailbox either contains mail (i.e., the mailbox is a plain file) or a container for one or more mailboxes (i.e., the mailbox is a directory).
Namespaces in maildir format consist of a tree of directories. The hierarchy, however, is expressed differently than with a mbox tree. With maildir format, all folders are rooted in a common directory but their names -- in dot-separated format -- define the logical hierarchy. In the example below, each of the dot-separated components are presented by an IMAP server as one level of a tree structure.
ls -as /var/imap/dovecot/roma/ 1 .Personal.Lists.Dovecot/ 1 .Personal.Lists.Illiana railroad list/ 1 .Personal.Lists.Oil history list/
You don't necessarily need a distinct namespace to do what you want, provided that you organize your mail as you want. If you want folders that can contain both mail as well as subordinate folders, you need maildir.
If your users have an existing hierarchy of folders in mbox form, you can certainly support this with or without namespaces defined in Dovecot.
I hope that this answers your basic questions. Perhaps the RFC will be helpful, though it's possibly more than you likely want to know!
Andy Cravens <acravens@uen.org> wrote:
I need to do the same thing, emulate the hierarchy of folders. However, I do not completely understand the concept of namespaces. I have read the configuration file and the documentation on the dovecot web site and I just don't get it. Can someone explain it differently?
I already have dovecot running on a test server and do not have any namespaces defined. I am moving our user's mbox files to the new server and converting to maildir. Everything works fine except that I don't know how to handle users who have mboxes in subfolders. After reading these recent messages on namespaces I've come to the conclusion I need to emulate the directory structore which involves the implementation of a namespace and defining a hierarchy separator. In the example below by Steffen, they used : as the separator. Other examples I have seen use / as the separator. Is one separator better suited for a situation than another?
Andy
Steffen Kaiser wrote:
On Tue, 6 Sep 2005, Wolfram Schlich wrote:
Ah! Thanks for clearing that up. Do you have any design document reference at hand?
http://www.inter7.com/courierimap/README.maildirquota.html
quote:
"Can folders have subfolders, defined in a recursive fashion? The answer is no. If you want to have a client with a hierarchy of folders, emulate it. Pick a hierarchy separator character, say ":". Then, folder foo/bar is subdirectory .foo:bar."
Bye,