Discussion:
"doveadm backup/sync" are badly documented
Jesus Cea
2014-09-28 21:52:35 UTC
Permalink
Most documents around there talk abour "dsync", but the modern way is
"doveadm backup". This command is not documented in the wiki and there
are a few details missing, like how to use it thru SSH.

I am currently doing some tests about how to backup my mdbox. I can do
tests in local using:

$ doveadm backup -u jcea -m proveedores/dovecot mdbox:/tmp/aa/

This will "backup" this mailing list mailbox to "/tmp/aa". Good. Lets
try thru SSH:

$ doveadm backup -u jcea -m proveedores/dovecot ssh 127.0.0.1 dsync -u
jcea mdbox:/tmp/aa/
jcea at 127.0.0.1's password:
Fatal: Invalid parameter: mdbox:/tmp/aa/
dsync-local(jcea): Error: read(remote) failed: EOF (version not received)

How shoudl I do it?.

$ doveadm backup -h
backup: invalid option -- 'h'
doveadm backup [-u <user>|-A] [-S <socket_path>] [-dfR] [-l <secs>] [-r
<rawlog path>] [-m <mailbox>] [-n <namespace> | -N] [-x <exclude>] [-s
<state>] <dest>

I can't find any explanation at all about the different parameters of
"doveadm backup".

Same thing with "doveadm sync".
--
Jes?s Cea Avi?n _/_/ _/_/_/ _/_/_/
jcea at jcea.es - http://www.jcea.es/ _/_/ _/_/ _/_/ _/_/ _/_/
Twitter: @jcea _/_/ _/_/ _/_/_/_/_/
jabber / xmpp:jcea at jabber.org _/_/ _/_/ _/_/ _/_/ _/_/
"Things are not so easy" _/_/ _/_/ _/_/ _/_/ _/_/ _/_/
"My name is Dump, Core Dump" _/_/_/ _/_/_/ _/_/ _/_/
"El amor es poner tu felicidad en la felicidad de otro" - Leibniz

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://dovecot.org/pipermail/dovecot/attachments/20140928/995c56c2/attachment.sig>
Jesus Cea
2014-09-29 00:15:23 UTC
Permalink
On 28/09/14 23:52, Jesus Cea wrote:
[..]
Post by Jesus Cea
This will "backup" this mailing list mailbox to "/tmp/aa". Good. Lets
$ doveadm backup -u jcea -m proveedores/dovecot ssh 127.0.0.1 dsync -u
jcea mdbox:/tmp/aa/
Fatal: Invalid parameter: mdbox:/tmp/aa/
dsync-local(jcea): Error: read(remote) failed: EOF (version not received)
How shoudl I do it?.
Trying a few things I got here, that works:

$ doveadm -o mail_fsync=never -o mdbox_rotate_interval=99d -o
mdbox_rotate_size=10M -o mail_attachment_dir=/tmp/aa/attachments -o
mail_attachment_min_size=64k -o mail_attachment_hash=%{sha256} -o
mail_location=mdbox:/tmp/aa/:DIRNAME=XxX backup -m 'varios/nosotros' -R
ssh 127.0.0.1 doveadm dsync-server

Two things:

1. I am connecting to myself thru SSH. I want to do a copy of my mdbox
with a different configuration. I was not able to transfer that
configuration change to thru SSH, so I just reverse the data flow
direction (The "-R"): just connect to the regular mailbox_location and
bring data here to be stored with a different configuration. This was a
kind of enlightment.

2. You must do "ssh 127.0.0.1 doveadm dsync-server" instead of simply
"ssh 127.0.0.1" because you would get this error:

bash: dsync-server: command not found
dsync-local(jcea): Error: read(remote) failed: EOF (version not received)
dsync-local(jcea): Error: Remote command returned error 127: ssh
127.0.0.1 dsync-server

I guess dovecot is sending the legacy "dsync-server" instead of the
current "doveadm dsync-server".

LOOKS LIKE THAT IS A BUG!!.
Post by Jesus Cea
$ doveadm backup -h
backup: invalid option -- 'h'
doveadm backup [-u <user>|-A] [-S <socket_path>] [-dfR] [-l <secs>] [-r
<rawlog path>] [-m <mailbox>] [-n <namespace> | -N] [-x <exclude>] [-s
<state>] <dest>
I can't find any explanation at all about the different parameters of
"doveadm backup".
Please, document.
Post by Jesus Cea
Same thing with "doveadm sync".
--
Jes?s Cea Avi?n _/_/ _/_/_/ _/_/_/
jcea at jcea.es - http://www.jcea.es/ _/_/ _/_/ _/_/ _/_/ _/_/
Twitter: @jcea _/_/ _/_/ _/_/_/_/_/
jabber / xmpp:jcea at jabber.org _/_/ _/_/ _/_/ _/_/ _/_/
"Things are not so easy" _/_/ _/_/ _/_/ _/_/ _/_/ _/_/
"My name is Dump, Core Dump" _/_/_/ _/_/_/ _/_/ _/_/
"El amor es poner tu felicidad en la felicidad de otro" - Leibniz

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://dovecot.org/pipermail/dovecot/attachments/20140929/b977ac99/attachment-0001.sig>
Pascal Volk
2014-09-29 18:45:44 UTC
Permalink
Post by Jesus Cea
?
Post by Jesus Cea
$ doveadm backup -h
backup: invalid option -- 'h'
doveadm backup [-u <user>|-A] [-S <socket_path>] [-dfR] [-l <secs>] [-r
<rawlog path>] [-m <mailbox>] [-n <namespace> | -N] [-x <exclude>] [-s
<state>] <dest>
I can't find any explanation at all about the different parameters of
"doveadm backup".
Please, document.
?
That's my task. I hope I'll find the time to write the fine manual until
this weekend.


Regards,
Pascal
--
The trapper recommends today: beeffeed.1427220 at localdomain.org
Loading...