Cédric ML
2016-Dec-07 10:22 UTC
Dovecot migration via dsync : mail_location problem (INBOX) ?
Hello, I'm trying to migrate mail accounts from an old dovecot 1.0.15 to a new dovecot 2.2.26. I've set up a master-user on old dovecot, and I run dsync on new server, like this : # doveadm -D -o mail_fsync=never sync -R -u user at domain.tld imapc: my user at domain.tld looks like this (on the new server): # doveadm user user at domain.tld field value uid 2000 gid 2000 home /home/vmail/domain.tld/user mail maildir:/home/vmail/domain.tld/user/mail quota_rule *:bytes=0 User mail folder on the old server looks like this : # ls -la /home/virtual/user at domain.tld/ total 64 drwx------ 11 vmail vmail 4096 2016-12-06 16:26 ./ drwxrwx--- 234 vmail vmail 12288 2016-12-05 12:57 ../ drwx------ 2 vmail vmail 89 2016-12-06 15:29 cur/ -rw------- 1 vmail vmail 352 2016-12-06 16:26 dovecot.index -rw------- 1 vmail vmail 19456 2016-12-06 16:26 dovecot.index.cache -rw------- 1 vmail vmail 2220 2016-12-06 16:26 dovecot.index.log -rw------- 1 vmail vmail 10 2016-12-06 15:14 dovecot-keywords -rw------- 1 vmail vmail 170 2016-12-06 16:21 dovecot-uidlist drwx------ 5 vmail vmail 148 2016-12-05 16:52 .Drafts/ drwx------ 5 vmail vmail 148 2016-12-05 16:52 .FauxIndesirable/ drwx------ 5 vmail vmail 148 2016-12-05 16:52 .Indesirable/ -rw-r----- 1 vmail vmail 293 2016-12-06 15:29 maildirsize drwx------ 2 vmail vmail 85 2016-12-06 15:29 new/ drwx------ 5 vmail vmail 148 2016-12-05 16:52 .Sent/ drwx------ 5 vmail vmail 148 2016-12-05 16:52 .Spam/ drwx------ 2 vmail vmail 6 2016-12-07 10:46 tmp/ drwx------ 5 vmail vmail 4096 2016-12-06 15:36 .Trash/ When I run the sync, with "doveadm -D -o mail_fsync=never sync -R -u user at domain.tld imapc:" on the new server, the new server synchronises the mail from the new server, and the file system on the new server looks like this : root at dovecot-pa3:/home/vmail/domain.tld# ls -la /home/vmail/domain.tld/user/mail/ total 84 drwx------ 15 mailbox mailbox 4096 Dec 7 11:02 . drwx------ 3 mailbox mailbox 4096 Dec 7 11:02 .. drwx------ 2 mailbox mailbox 4096 Dec 7 11:02 cur -rw------- 1 mailbox mailbox 556 Dec 7 11:02 dovecot.index.log -rw------- 1 mailbox mailbox 96 Dec 7 11:02 dovecot.mailbox.log -rw------- 1 mailbox mailbox 51 Dec 7 11:02 dovecot-uidlist -rw------- 1 mailbox mailbox 8 Dec 7 11:02 dovecot-uidvalidity -r--r--r-- 1 mailbox mailbox 0 Dec 7 11:02 dovecot-uidvalidity.5847de3b drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .Drafts drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.Drafts drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.FauxIndesirable drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.Indesirable drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.Sent drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.Spam drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .INBOX.Trash drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .Junk -rw------- 1 mailbox mailbox 17 Dec 7 11:02 maildirsize drwx------ 2 mailbox mailbox 4096 Dec 7 11:02 new drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .Sent -rw------- 1 mailbox mailbox 23 Dec 7 11:02 subscriptions drwx------ 2 mailbox mailbox 4096 Dec 7 11:02 tmp drwx------ 5 mailbox mailbox 4096 Dec 7 11:02 .Trash But dovecot is condigured to have ".Trash", ".Junk" etc... folders, not ".INBOX.Trash" I've try multiple things : - use namespaces for compatibility and add "-n <namespace>" in sync command, without success - modify the mail_location for the user, tried to add LAYOUT=fs, INBOX=<folder>, ... without success. Can anybody help me with that please ? Here's the #doveconf -n output : ------------------------------------------------------- # 2.2.devel (f7f4b65): /etc/dovecot/dovecot.conf # Pigeonhole version 0.4.devel (53a3582) # OS: Linux 3.16.0-4-amd64 x86_64 Debian 8.6 auth_mechanisms = plain login doveadm_password = # hidden, use -P to show it doveadm_port = 12345 imapc_features = rfc822.size fetch-headers imapc_host = oldserver.domain.tld imapc_master_user = masteruser imapc_password = # hidden, use -P to show it imapc_user = %u mail_plugins = " quota notify replication" mail_prefetch_count = 20 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 index ihave duplicate mime foreverypart extracttext mbox_write_locks = fcntl dotlock namespace compat { hidden = no list = no location = maildir:~/mail/ prefix = INBOX separator = / } namespace inbox { hidden = no inbox = yes list = yes location mailbox Drafts { auto = subscribe special_use = \Drafts } mailbox Junk { auto = subscribe special_use = \Junk } mailbox Sent { auto = subscribe special_use = \Sent } mailbox Trash { auto = subscribe special_use = \Trash } prefix separator = / } passdb { args = /etc/dovecot/dovecot-sql.conf.ext driver = sql } plugin { mail_replica = tcp:192.168.159.9:12345 quota = maildir:User quota quota_grace = 10%% quota_rule = Trash:storage=+100M quota_status_nouser = DUNNO quota_status_overquota = 552 5.2.2 Boite de messagerie pleine. quota_status_success = DUNNO quota_warning = storage=95%% quota-warning 95 %u quota_warning2 = storage=85%% quota-warning 85 %u sieve = file:~/sieve;active=~/.dovecot.sieve sieve_before = /var/lib/dovecot/sieve/ sieve_before2 = /home/vmail/%d/%n/sieve/Vacation.sieve sieve_default = /var/lib/dovecot/sieve/dovecot.sieve sieve_default_name = default sieve_global = /var/lib/dovecot/sieve/ } protocols = " imap sieve pop3 sieve" service aggregator { fifo_listener replication-notify-fifo { mode = 0666 user = mailbox } unix_listener replication-notify { mode = 0666 user = mailbox } } service auth { inet_listener { port = 12346 } unix_listener /var/spool/postfix/private/auth { group = postfix mode = 0660 user = postfix } unix_listener auth-userdb { group = mailbox user = mailbox } } service config { unix_listener config { user = mailbox } } service doveadm { inet_listener { port = 12345 } user = mailbox } service imap-login { inet_listener imap { port = 143 } inet_listener imaps { port = 993 } } service managesieve-login { inet_listener sieve { port = 4190 } process_min_avail = 1 service_count = 1 vsz_limit = 64 M } service quota-warning { executable = script /usr/local/bin/quota-warning.sh unix_listener quota-warning { user = mailbox } user = mailbox } service replicator { process_min_avail = 1 unix_listener replicator-doveadm { group = mailbox mode = 0660 } } ssl = required ssl_cert = </etc/ssl/certs/crt-and-intermediate.pem ssl_key = # hidden, use -P to show it userdb { driver = prefetch } userdb { args = /etc/dovecot/dovecot-sql.conf.ext driver = sql } protocol lmtp { postmaster_address = postmaster at domain.tld } protocol lda { mail_plugins = " quota notify replication sieve" postmaster_address = postmaster at domain.tld } protocol imap { mail_plugins = " quota notify replication imap_quota" } ------------------------------------------------------- Best regards, C?dric
Sami Ketola
2016-Dec-07 11:33 UTC
Dovecot migration via dsync : mail_location problem (INBOX) ?
> On 7 Dec 2016, at 12.22, C?dric ML <cedric.bassaget.ml at gmail.com> wrote: > > Hello, > > I'm trying to migrate mail accounts from an old dovecot 1.0.15 to a new dovecot 2.2.26. > I've set up a master-user on old dovecot, and I run dsync on new server, like this : > > # doveadm -D -o mail_fsync=never sync -R -u user at domain.tld imapc: >?> But dovecot is condigured to have ".Trash", ".Junk" etc... folders, not ".INBOX.Trash" > I've try multiple things : > - use namespaces for compatibility and add "-n <namespace>" in sync command, without success > - modify the mail_location for the user, tried to add LAYOUT=fs, INBOX=<folder>, ... without success. > > Can anybody help me with that please ? >you can try setting imapc_prefix=INBOX and imapc_list_prefix=INBOX or maybe ?INBOX.' Sami
Cédric ML
2016-Dec-07 12:02 UTC
Dovecot migration via dsync : mail_location problem (INBOX) ?
hi Sami, imapc_prefix is not a valid option. but imapc_prefix_list="INBOX" is great ! It does the trick ! Thanks a lot. Regards, C?dric Le 07/12/2016 ? 12:33, Sami Ketola a ?crit :>> On 7 Dec 2016, at 12.22, C?dric ML <cedric.bassaget.ml at gmail.com> wrote: >> >> Hello, >> >> I'm trying to migrate mail accounts from an old dovecot 1.0.15 to a new dovecot 2.2.26. >> I've set up a master-user on old dovecot, and I run dsync on new server, like this : >> >> # doveadm -D -o mail_fsync=never sync -R -u user at domain.tld imapc: >> > ? > >> But dovecot is condigured to have ".Trash", ".Junk" etc... folders, not ".INBOX.Trash" >> I've try multiple things : >> - use namespaces for compatibility and add "-n <namespace>" in sync command, without success >> - modify the mail_location for the user, tried to add LAYOUT=fs, INBOX=<folder>, ... without success. >> >> Can anybody help me with that please ? >> > you can try setting imapc_prefix=INBOX and imapc_list_prefix=INBOX or maybe ?INBOX.' > > Sami >
Apparently Analagous Threads
- Dovecot migration via dsync : mail_location problem (INBOX) ?
- dsync migration from maildir layout=fs to maildir seperator / - folders or inbox but not both
- dsync migration from maildir layout=fs to maildir seperator / - folders or inbox but not both
- doveadm-sync stateful
- Asterisk 13 / realtime voicemail creation