Nikolai Schupbach
2012-Jul-14 08:29 UTC
[Dovecot] Migrating with dsync and INBOX.INBOX namespace issue
I'm working on migrating IMAP users from Mirapoint Message Servers to Dovecot servers. The Mirapoint IMAP server uses INBOX as a namespace for private mailboxes. I created the same namespace in Dovecot, but when I migrate mailboxes dsync seems to ignore/miss the namespace on Mirapoint and I end up with all mailboxes under a INBOX.INBOX hierarchy. Mirapoint Source Server ----------------------- * OK server.name Mirapoint IMAP4 3.8.3-GA server ready 1 LOGIN test at test.com test 1 OK User logged in 2 NAMESPACE * NAMESPACE (("INBOX." ".")) (("user." ".")) (("" ".")) 2 OK Completed 3 LIST "" * * LIST () "." "INBOX" * LIST () "." "INBOX.Draft" * LIST () "." "INBOX.Sent" * LIST () "." "INBOX.Trash" 3 OK Completed Running Dsync ------------- # doveadm -v -o imapc_host=server.name imapc_user=test at test.com -o imapc_password=test backup -R -u test at test.com imapc: dsync(test at test.com): Info: INBOX.INBOX.Sent: only in source (guid=7d3c7eaa71cdf47ee8a1192687cda8cd) dsync(test at test.com): Info: INBOX.INBOX.Draft: only in source (guid=a6a03ff3d6ec9066b46013f4affb109a) dsync(test at test.com): Info: INBOX.INBOX.Trash: only in source (guid=b36f688eae08506001091708006abe5a) dsync(test at test.com): Info: INBOX: only in source (guid=c92f64f79f0d1ed01e6d5b314f04886c) Dovecot Destination Server Post Dsync ------------------------------------- * OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE AUTH=PLAIN] Dovecot ready. 1 LOGIN test at test.com test 1 OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS SPECIAL-USE QUOTA ACL RIGHTS=texk] Logged in 2 NAMESPACE * NAMESPACE (("INBOX." ".")) NIL NIL 2 OK Namespace completed. 3 LIST "" * * LIST (\HasChildren) "." "INBOX" * LIST (\HasNoChildren) "." "INBOX.INBOX.Sent" * LIST (\HasNoChildren) "." "INBOX.INBOX.Trash" * LIST (\HasNoChildren) "." "INBOX.INBOX.Draft" 3 OK List completed. I noticed that Mirapoint IMAP also advertises a third empty namespace and I was wondering if this was causing it, but even if I explicitly set -n "INBOX." I still have the same issue. Below is my doveconf -n output: # 2.1.6: /usr/local/etc/dovecot/dovecot.conf # OS: FreeBSD 9.0-RELEASE-p3 amd64 auth_cache_negative_ttl = 0 auth_verbose = yes default_vsz_limit = 512 M deliver_log_format = subject=%s msgid=%m: %$ disable_plaintext_auth = no imapc_features = rfc822.size mail_gid = vmail mail_home = /mailstore/domains/%d/%n mail_location = mdbox:~/mdbox mail_plugins = quota acl mail_log notify mail_temp_dir = /var/tmp mail_uid = vmail managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave spamtest namespace { inbox = yes location = prefix = INBOX. separator = . } passdb { args = /usr/local/etc/dovecot/dovecot-ldap-passdb.conf driver = ldap } plugin { acl = vfile:/usr/local/etc/dovecot/global-acls mail_log_events = delete undelete expunge copy mailbox_delete mailbox_rename mail_log_fields = uid box msgid size quota = dict:User quota::file:%h/.dovecot-quota quota_warning = storage=95%% quota-warning 95 %u sieve = ~/.dovecot.sieve sieve_extensions = +spamtest sieve_max_redirects = 32 sieve_spamtest_max_value = 10 sieve_spamtest_status_header = X-Spam-Score sieve_spamtest_status_type = score } service auth-worker { user = $default_internal_user } service auth { client_limit = 5420 unix_listener auth-userdb { group = vmail mode = 0600 user = vmail } user = $default_internal_user } service imap-login { process_min_avail = 12 service_count = 0 vsz_limit = 512 M } service imap { process_limit = 4096 vsz_limit = 512 M } service lmtp { process_min_avail = 12 user = vmail } service pop3-login { process_min_avail = 12 service_count = 0 vsz_limit = 512 M } service pop3 { process_limit = 1024 vsz_limit = 512 M } service quota-warning { executable = script /usr/local/bin/quota-warning unix_listener quota-warning { user = vmail } user = vmail } ssl = no userdb { args = /usr/local/etc/dovecot/dovecot-ldap-userdb.conf driver = ldap } verbose_proctitle = yes protocol imap { mail_max_userip_connections = 50 mail_plugins = quota acl mail_log notify imap_quota imap_acl } protocol lmtp { mail_plugins = quota acl mail_log notify sieve } Any help would be much appreciated. Regards, Nikolai.
Nikolai Schupbach
2012-Jul-15 09:39 UTC
[Dovecot] Migrating with dsync and INBOX.INBOX namespace issue
Just a follow up to this - I used the imapsync perl script and found that it synced with the namespaces correctly: /usr/local/bin/imapsync --host1 source.server.name --user1 test at test.com --password1 MASKED --host2 dest.server.name --user2 test at test.com --password2 MASKED Host1 capability: IMAP4 IMAP4rev1 ACL QUOTA LITERAL+ NAMESPACE UIDPLUS IDLE AUTH=PLAIN UNSELECT Host2 capability: IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS SPECIAL-USE QUOTA ACL RIGHTS=texk Host1 separator and prefix: [.][INBOX.] Host2 separator and prefix: [.][INBOX.] So there appears to be some problem with namespaces and dsync/imapc. On 14/07/2012, at 8:29 PM, Nikolai Schupbach wrote:> I'm working on migrating IMAP users from Mirapoint Message Servers to Dovecot servers. The Mirapoint IMAP server uses INBOX as a namespace for private mailboxes. I created the same namespace in Dovecot, but when I migrate mailboxes dsync seems to ignore/miss the namespace on Mirapoint and I end up with all mailboxes under a INBOX.INBOX hierarchy. > > Mirapoint Source Server > ----------------------- > * OK server.name Mirapoint IMAP4 3.8.3-GA server ready > 1 LOGIN test at test.com test > 1 OK User logged in > 2 NAMESPACE > * NAMESPACE (("INBOX." ".")) (("user." ".")) (("" ".")) > 2 OK Completed > 3 LIST "" * > * LIST () "." "INBOX" > * LIST () "." "INBOX.Draft" > * LIST () "." "INBOX.Sent" > * LIST () "." "INBOX.Trash" > 3 OK Completed > > Running Dsync > ------------- > # doveadm -v -o imapc_host=server.name imapc_user=test at test.com -o imapc_password=test backup -R -u test at test.com imapc: > dsync(test at test.com): Info: INBOX.INBOX.Sent: only in source (guid=7d3c7eaa71cdf47ee8a1192687cda8cd) > dsync(test at test.com): Info: INBOX.INBOX.Draft: only in source (guid=a6a03ff3d6ec9066b46013f4affb109a) > dsync(test at test.com): Info: INBOX.INBOX.Trash: only in source (guid=b36f688eae08506001091708006abe5a) > dsync(test at test.com): Info: INBOX: only in source (guid=c92f64f79f0d1ed01e6d5b314f04886c) > > Dovecot Destination Server Post Dsync > ------------------------------------- > * OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE AUTH=PLAIN] Dovecot ready. > 1 LOGIN test at test.com test > 1 OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS SPECIAL-USE QUOTA ACL RIGHTS=texk] Logged in > 2 NAMESPACE > * NAMESPACE (("INBOX." ".")) NIL NIL > 2 OK Namespace completed. > 3 LIST "" * > * LIST (\HasChildren) "." "INBOX" > * LIST (\HasNoChildren) "." "INBOX.INBOX.Sent" > * LIST (\HasNoChildren) "." "INBOX.INBOX.Trash" > * LIST (\HasNoChildren) "." "INBOX.INBOX.Draft" > 3 OK List completed. > > I noticed that Mirapoint IMAP also advertises a third empty namespace and I was wondering if this was causing it, but even if I explicitly set -n "INBOX." I still have the same issue. > > Below is my doveconf -n output: > > # 2.1.6: /usr/local/etc/dovecot/dovecot.conf > # OS: FreeBSD 9.0-RELEASE-p3 amd64 > auth_cache_negative_ttl = 0 > auth_verbose = yes > default_vsz_limit = 512 M > deliver_log_format = subject=%s msgid=%m: %$ > disable_plaintext_auth = no > imapc_features = rfc822.size > mail_gid = vmail > mail_home = /mailstore/domains/%d/%n > mail_location = mdbox:~/mdbox > mail_plugins = quota acl mail_log notify > mail_temp_dir = /var/tmp > mail_uid = vmail > managesieve_notify_capability = mailto > managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave spamtest > namespace { > inbox = yes > location = > prefix = INBOX. > separator = . > } > passdb { > args = /usr/local/etc/dovecot/dovecot-ldap-passdb.conf > driver = ldap > } > plugin { > acl = vfile:/usr/local/etc/dovecot/global-acls > mail_log_events = delete undelete expunge copy mailbox_delete mailbox_rename > mail_log_fields = uid box msgid size > quota = dict:User quota::file:%h/.dovecot-quota > quota_warning = storage=95%% quota-warning 95 %u > sieve = ~/.dovecot.sieve > sieve_extensions = +spamtest > sieve_max_redirects = 32 > sieve_spamtest_max_value = 10 > sieve_spamtest_status_header = X-Spam-Score > sieve_spamtest_status_type = score > } > service auth-worker { > user = $default_internal_user > } > service auth { > client_limit = 5420 > unix_listener auth-userdb { > group = vmail > mode = 0600 > user = vmail > } > user = $default_internal_user > } > service imap-login { > process_min_avail = 12 > service_count = 0 > vsz_limit = 512 M > } > service imap { > process_limit = 4096 > vsz_limit = 512 M > } > service lmtp { > process_min_avail = 12 > user = vmail > } > service pop3-login { > process_min_avail = 12 > service_count = 0 > vsz_limit = 512 M > } > service pop3 { > process_limit = 1024 > vsz_limit = 512 M > } > service quota-warning { > executable = script /usr/local/bin/quota-warning > unix_listener quota-warning { > user = vmail > } > user = vmail > } > ssl = no > userdb { > args = /usr/local/etc/dovecot/dovecot-ldap-userdb.conf > driver = ldap > } > verbose_proctitle = yes > protocol imap { > mail_max_userip_connections = 50 > mail_plugins = quota acl mail_log notify imap_quota imap_acl > } > protocol lmtp { > mail_plugins = quota acl mail_log notify sieve > } > > Any help would be much appreciated. > > Regards, Nikolai. > >
Seemingly Similar Threads
- master user login dovecot 2.02 trouble
- Trouble using reverse dsync backup (log in successful but almost nothing happens)
- dsync error: Error: Can't delete mailbox INBOX: INBOX can't be deleted.
- Migrating domain using IMAPc
- ACL plugin, public namespace, erroneous \HasNoChildren