dsync mail from a remote server

Kai Schaetzl maillists at conactive.com
Mon Sep 10 15:55:39 EEST 2018


I would like to transfer mail for some users from an old dovecot (with no 
doveadm) to a modern dovecot (2.3.2). I've read up on
https://wiki2.dovecot.org/Tools/Doveadm/Sync
https://wiki2.dovecot.org/Migration/Dsync

and I'm not sure if I can use doveadm for this purpose.

I need doveadm to login to the remote server (source) with a 
username/password via IMAP, fetch all mail and deliver it to a local user 
(target), preferrably with the same folder structure that exists on the 
source account.
Is this possible?

I don't understand this page completely:
https://wiki2.dovecot.org/Migration/Dsync

For some testing (that's why I used pop3, to keep it simple) I put a file 
for pop3c in conf.d (mostly identical with the file shown on that page) 
and restarted dovecot. Then I tried a command line like this:
doveadm -o pop3c_user=user -o pop3c_password=password backup -R -u 
user at domain pop3c:
This creates an error: 
dsync(user at domain): Error: Mail locations must use the same virtual 
mailbox hierarchy separator (specify separator for the default namespace)

I'm not sure what this exactly means.
Does it refer to the account naming structure of user at domain? The source 
server does not have such usernames, only the target server I run the 
command on. Or does it refer to structure within the mailbox? (which can't 
really be the case as it doesn't login to the source and can't know the 
structure yet).
So, if it indeed refers to the user naming structure, can I tell it to use 
the "simple" account names on the source machine?

Am I correct in assuming that I can override any pop3c_ setting in the 
conf file with -o? For instance also using -o pop3c_host= and that if 
there is -o pop3c_user=user on the command line I don't need a pop3c_user 
in the conf file? (no master-user).

Thanks for any help on this.
(If it doesn't work I can use fetchmail, but that is much less preferrable 
as it "delivers" all mail, so it's all "new" and in the INBOX.

Kai




More information about the dovecot mailing list