mbox 2 Maildir

Tamas Hegedus tamas at hegelab.org
Fri Feb 8 00:16:33 EET 2019


Hi,

I have some strange things and at the end I am not sure if the migration 
is (will be) OK.
I have a testuser for testing the mbox 2 Maildir migration. It did not 
received new email during the following steps:

sudo -u testuser doveadm sync maildir:/home/testuser/Maildir
dsync(testuser): Warning: Mailbox changes caused a desync. You may want 
to run dsync again: Remote lost mailbox GUID 
4ca2fa0b9bb536564a470000e1afe915 (maybe it was just deleted?)

doveadm kick testuser

#sudo -u testuser doveadm sync maildir:/home/testuser/Maildir
##dsync(testuser): Error: Both source and destination mail_location 
points to same directory: /home/testuser/Maildir

sudo -u testuser doveadm sync -R mbox:/home/testuser/mail
dsync(testuser): Error: Can't sync mailbox Public folders: Mailbox isn't 
selectable

If I check the folders and mails in Thunderbird, everything seems OK 
('Public folders' seems to be synced, too). However,
du -hsc ./*
320M    ./mail
157M    ./Maildir

I did not find anything that seem to be useful in order to get at a 
conclusion.

Thanks for your help and suggestions,
Tamas

On 2/5/19 10:48 AM, Tamas Hegedus wrote:
> Hi,
>
> I am experimenting with the migration.
> I unset mail_location, thus it is empty and dovecot performs automatic 
> mailbox detection. Therefore I do not need per-user set of mail 
> location. I login as a testuser and do:
> doveadm sync maildir:~/Maildir
>
> It seems for me that in this situation the new Maildir becomes the 
> active mail delivery location at the time of the creation(?) or 
> completing the sync(?).
>
> So if I want to rerun to avoid loosing new messages:
> doveadm sync maildir:~/Maildir
> I got an error that I can not sync to itself.
>
> I guess this would not be a problem and would be rather simply. 
> However, if I issue a revers sync to be sure not loosing new messages:
> doveadm sync -R mail/
> doveadm(hegedus): Fatal: execvp(mail/) failed: Permission denied
> dsync-local(hegedus): Error: read(remote) failed: EOF (version not 
> received)
>
> (I tried to set a+x on my old mbox 'mail' directory and its contents)
>
> I would appreciate any suggestion.
> Thanks,
> Tamas
>
> On 01/30/2019 03:32 PM, Christian Schmidt wrote:
>> Hi,
>>
>> Tamas Hegedus, 29.01.19:
>>> * Configuration uses mail_location = mbox:~/mails
>>> * setup per-user mail location and do for each user individually in 
>>> a serial manner:
>>> -- doveadm sync maildir:~/Maildir; mbox is synced to Maildir, long 
>>> running time
>>> -- doveadm sync maildir:~/Maildir; rerun to do it for new messages 
>>> (fast)
>>> -- add USER to userdb and set extra field to maildir:~/Maildir
>>> users not present in the userdb should default to dovcot default; 
>>> conditionally optional: doveadm auth cache flush
>>
>> IMHO there is no need to create or change special userdb entries. See 
>> https://wiki.dovecot.org/MailLocation:
>> "By default the mail_location setting is empty, which means that 
>> Dovecot attempts to locate automatically where your mails are."
>>
>> Regards,
>> Christian
>>
>
>

-- 
Tamas Hegedus, PhD
Senior Research Fellow
MTA-SE Molecular Biophysics Research Group
Hungarian Academy of Sciences  | phone: (36) 1-459 1500/60233
Semmelweis University          | fax:   (36) 1-266 6656
Tuzolto utca 37-47             | mailto:tamas at hegelab.org
Budapest, 1094, Hungary        | http://www.hegelab.org



More information about the dovecot mailing list