[Dovecot] convert plugin
Was about to try convert plugin (as opposed to mb2md.pl) and noticed, that it doesn't convert subfolders.
I have following structure:
~/ | mail/ | Archive | Help | Sent | Done/ | Cardiology | Childrens | Orkin
when I use convert-tool -
#convert-tool username /home/username mbox:/home/username/mail/ maildir:/home/username/Maildir/ Error: Mailbox conversion: Couldn't create mailbox Done/Cardiology Error: Internal failure
If I try "on the fly" conversion (by putting convert_mail = mbox:%h/mail & convert_skip_broken_mailboxes=yes in dovecot.conf) I get this in the log - Mar 6 12:23:33 enders2 dovecot: imap-login: Login: user=<username>, method=PLAIN, rip=::ffff:127.0.0.1, lip=::ffff:127.0.0.1, secured Mar 6 12:23:43 enders2 dovecot: IMAP(username): Mailbox conversion: Couldn't create mailbox Done/Cardiology
Both methods convert Archive and Logs mailboxes fine.
Can anybody confirm?
P.S. Linux enders2.tchlab.org 2.6.18-1.2200.fc5smp #1 SMP Sat Oct 14 17:15:35 EDT 2006 i686 i686 i386 GNU/Linux dovecot-1.0.rc22 (I know this is not the latest version, but I didn't see any changes to convert tool/plugin).
FiL
On Tue, 2007-03-06 at 12:36 -0500, FiL @ Kpoxa wrote:
#convert-tool username /home/username mbox:/home/username/mail/ maildir:/home/username/Maildir/ Error: Mailbox conversion: Couldn't create mailbox Done/Cardiology Error: Internal failure
I guess you're using '.' as maildir separator? Maybe the convert plugin should convert the hierarchy separators, but you could also create a namespace which uses '/' as the maildir separator. Probably a good idea to do anyway if you want the updates to be transparent to users.
I'll fix at least the logging so it shows the "Invalid mailbox name" error.
On Tue, 2007-03-06 at 21:59 +0200, Timo Sirainen wrote:
On Tue, 2007-03-06 at 12:36 -0500, FiL @ Kpoxa wrote:
#convert-tool username /home/username mbox:/home/username/mail/ maildir:/home/username/Maildir/ Error: Mailbox conversion: Couldn't create mailbox Done/Cardiology Error: Internal failure
I guess you're using '.' as maildir separator? Maybe the convert plugin should convert the hierarchy separators, but you could also create a namespace which uses '/' as the maildir separator. Probably a good idea to do anyway if you want the updates to be transparent to users.
Actually the namespace doesn't affect it. This patch should fix the problem by changing the separators: http://dovecot.org/list/dovecot-cvs/2007-March/007957.html
Timo Sirainen wrote:
On Tue, 2007-03-06 at 21:59 +0200, Timo Sirainen wrote:
On Tue, 2007-03-06 at 12:36 -0500, FiL @ Kpoxa wrote:
#convert-tool username /home/username mbox:/home/username/mail/ maildir:/home/username/Maildir/ Error: Mailbox conversion: Couldn't create mailbox Done/Cardiology Error: Internal failure
I guess you're using '.' as maildir separator? Maybe the convert plugin should convert the hierarchy separators, but you could also create a namespace which uses '/' as the maildir separator. Probably a good idea to do anyway if you want the updates to be transparent to users.
Actually the namespace doesn't affect it. This patch should fix the problem by changing the separators: http://dovecot.org/list/dovecot-cvs/2007-March/007957.html
Thanks, Timo. I will try it later this week.
FiL
FiL @ Kpoxa wrote:
Timo Sirainen wrote:
Actually the namespace doesn't affect it. This patch should fix the problem by changing the separators: http://dovecot.org/list/dovecot-cvs/2007-March/007957.html
Thanks, Timo. I will try it later this week.
Well... As I can see, now this code is in RC26. It works. BUT only for the first level of subdirectories. When I created second-level sub-directory it failed again. Can you fix it, so it will do the same trick with any number of levels of subdirectories?
Also, I noticed, this in the log - Mar 7 16:34:01 enders2 dovecot: IMAP(username): mkdir_parents(/home/username/mail/.imap/Trash) failed: Permission denied Mar 7 16:34:01 enders2 dovecot: IMAP(username): mkdir_parents(/home/username/mail/.imap/Archive) failed: Permission denied Mar 7 16:34:01 enders2 dovecot: IMAP(username): mkdir_parents(/home/username/mail/.imap/Sent Messages) failed: Permission denied Mar 7 16:34:01 enders2 dovecot: IMAP(username): mkdir_parents(/home/username/mail/.imap/Sent-2003) failed: Permission denied Mar 7 16:34:01 enders2 dovecot: IMAP(username): mkdir_parents(/home/username/mail/.imap/Logs) failed: Permission denied
Would it be better to just skip .imap folder without even trying to convert it?
Thanks,
FiL
participants (2)
-
FiL @ Kpoxa
-
Timo Sirainen