On Tue, 2011-01-04 at 19:54 +0000, ian+dovecot@comtek.co.uk wrote:
Has anybody got any tips on migrating IMAP separators? Ideally I'd be able to migrate users incrementally. Is there a way to specify the separator per-user? I can't see a way to do it with a postlogin script or userdb.
Both should be possible.
http://wiki2.dovecot.org/UserDatabase/ExtraFields shows a namespace setting, but it seems that the namespace is in version 1.2 format and my namespaces look like:
No, it's for v2.0. You just need to name your namespaces:
namespace {
namespace default {
type = private separator = . prefix = inbox = yes
} namespace {
namespace others {
(I think if you name it "shared", Dovecot thinks it's v1.x configuration and will "convert" it.)
type = shared separator = . prefix = Users.%%n. location =
maildir:/var/mail/virtual/users/%%n/Maildir/:INDEX=~/shared/%%u subscriptions = no list = children } namespace {
namespace pub {
type = public separator = . prefix = Shared. location = maildir:/var/mail/virtual/public:INDEX=~/public subscriptions = no
}
Then you can have userdb set namespace/default/separator=/, namespace/others/separator=/ and namespace/pub/separator=/. Or a post-login script to set those in environment.