doveadm sync backup from old to new server

Aki Tuomi aki.tuomi at open-xchange.com
Fri May 15 07:56:19 EEST 2020


> On 15/05/2020 07:53 Gregory Sloop <gregs at sloop.net> wrote:
> 
> 
> 
> 
>  
> 
> 
> 	 
> 
>  
>  
>  
>  >> On 15/05/2020 07:10 Plutocrat <plutocrat at gmail.com> wrote:
>  
>  >> 
>  >> On 15/05/2020 10.56, Gregory Sloop wrote:
>  >> > IMAP sync looks better and better. I'm a little puzzled why I don't just give up walking on the broken glass and use it - but it just bugs the heck out of me.
>  
>  >> If you can get the dovecot native sync to work, it seems to be a better option, as it understands all the dovecot index formats etc, and will transfer those correctly. Imapsync doesn't, and when I did that I had a few problems with POP email clients re-downloading their entire Inbox, which produced a few groans. Your mileage may vary.
>  
>  >> Another option for you, if you have the time and energy would be to set up proper replication between the two servers. Then any changes made would be synced in real time, until the cutoff, when you just shut down the old server and the new one is already up to date. But if you can't get a simple sync happening then that might be a bit of over-reach.
>  
>  >> My suspicions on your current situation would center around the complications introduced by docker, and on file/container permissions, environment variables, paths etc.
>  
>  >> How about if you just try a simple doveadm command over ssh from the remote server to make sure that works. eg. from "Sending" server do
>  
>  >> sshroot at po.abc.net\
>  >> docker exec b3093cxxxxxx doveadm useruser at abc.net
>  
>  >> That should execute the doveadm user command on the remote (receiving) server. If that works, then at least you can satisfy yourself that the docker bit is working correctly. Not sure why I'm getting involved in someone else's troubleshooting nightmare! ;-)
>  
>  >> P.
>  
>  AT> You need to have ssh installed. If you want to do sync over ssh.
>  AT> The docker image hasn't got ssh client installed by default.
>  
>  AT> Also seehttps://wiki.dovecot.org/Replicationfor more configuration options.
>  
> SSH *is* installed
>  
>  # ssh root at abc.net \
>  > docker exec b3093c6200a9 ls -al
>  
>  root at abc.net's password:
>  total 124
>  drwxr-xr-x 1 root root 4096 Apr 15 17:30 .
>  drwxr-xr-x 1 root root 4096 Apr 15 17:30 ..
>  -rwxr-xr-x 1 root root 0 Apr 15 17:29 .dockerenv
>  drwxr-xr-x 1 root root 4096 Apr 14 01:23 bin
>  drwxr-xr-x 2 root root 4096 Feb 1 09:09 boot
>  drwxr-xr-x 5 root root 380 May 12 11:25 dev
>  -rwxr-xr-x 1 root root 14951 Apr 14 08:31 docker-entrypoint.sh
>  drwxr-xr-x 1 root root 4096 Apr 15 17:30 etc
>  drwxr-xr-x 2 root root 4096 Feb 1 09:09 home
>  drwxr-xr-x 2 root root 4096 Apr 15 17:30 hooks
>  drwxr-xr-x 1 root root 4096 Apr 14 01:23 lib
>  drwxr-xr-x 2 root root 4096 Mar 26 17:00 lib64
>  drwxr-xr-x 2 root root 4096 Apr 15 17:30 mail_crypt
>  drwxr-xr-x 2 root root 4096 Mar 26 17:00 media
>  drwxr-xr-x 2 root root 4096 Mar 26 17:00 mnt
>  drwxr-xr-x 2 root root 4096 Mar 26 17:00 opt
>  dr-xr-xr-x 232 root root 0 May 12 11:25 proc
>  drwx------ 1 root root 4096 Apr 14 01:23 root
>  drwxr-xr-x 1 root root 4096 May 12 11:25 run
>  drwxr-xr-x 1 root root 4096 Apr 14 01:23 sbin
>  drwxr-xr-x 2 root root 4096 Mar 26 17:00 srv
>  -rw-r--r-- 1 root root 12126 May 14 15:48 supervisord.log
>  dr-xr-xr-x 13 root root 0 May 12 11:25 sys
>  drwxr-xr-x 2 root root 4096 Apr 15 17:21 templates
>  drwxrwxrwt 1 root root 4096 May 14 21:44 tmp
>  drwxr-xr-x 1 root root 4096 Mar 26 17:00 usr
>  drwxr-xr-x 1 root root 4096 Apr 15 17:30 var	
> 
>  Doh.
>  I wasn't thinking clearly.
>  Yeah, I guess I'm not sure if sshd is available in the docker container itself.
>  
>  But that would be *sshd* not the ssh client, right?

You need both. sshd where you try to connect to, and ssh on where you try to connect from. 

Aki


More information about the dovecot mailing list