[Dovecot] tests with metadata module
--Repost after subscription as list member ---
I made some tests with metadata support in dovecot 2.2.10. Previously I had dovecot 2.2.4 with external metadata plugin who work well.
I use dovecot with roundcube and roundcube plugins from kolab project . First, the feature activation was tricky and rather undocumented. I spent about half hour googling, after that I set:
imap_metadata = yes and mail_attribute_dict = file:%h/shared_metadata
I think you cold put those lines in the 20-imap.conf example file commented; that way will be easy for us to activate.
Because I changed the location of shared_metadata, all folders was unannotated . I went in folder manager in roundcube and set folder "calendar" as calendar type and so on. That worked and i have:
cat shared_metadata: shared/c4268a04da44bb527c5b0000193e0904/vendor/kolab/folder-type event shared/cd5792367fc9cd5196170000193e0904/vendor/kolab/folder-type event shared/33f55d2e8912195209290000193e0904/vendor/kolab/folder-type event shared/32f55d2e8912195209290000193e0904/vendor/kolab/folder-type contact
However, it looks like the metadata is not properly read after. Calendar and Contacts folders don't appear in roundcube. I have this crash in dovecot's log:
Error: Raw backtrace: /usr/lib/dovecot/libdovecot.so.0(+0x67d81) [0xb7625d81] -> /usr/lib/dovecot/libdovecot.so.0(+0x67e11) [0xb7625e11] -> /usr/lib/dovecot/libdovecot.so.0(i_fatal+0) [0xb75d6af9] -> dovecot/imap() [0x805d3b2] -> dovecot/imap() [0x805d5bc] -> dovecot/imap() [0x805d6c9] -> dovecot/imap(client_handle_input+0x56) [0x805d836] -> dovecot/imap(client_input+0x72) [0x805dcc2] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_call_io+0x38) [0xb7638d98] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run+0x10e) [0xb7639d6e] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_run+0x48) [0xb7638818] -> /usr/lib/dovecot/libdovecot.so.0(master_service_run+0x28) [0xb75dcb68] -> dovecot/imap(main+0x284) [0x8050f34] -> /lib/libc.so.6(__libc_start_main+0xf5) [0xb743f5a5] -> dovecot/imap() [0x80510a5] Dec 26 09:28:49 imap(mihai.badici): Fatal: master: service(imap): child 4919 killed with signal 6 (core dumps disabled)
I logged imap sessions in roundcube and I have:
A0003 GETMETADATA "*" (/private/vendor/kolab/folder-type /shared/vendor/kolab/folder-type)
On a similar server with the "old" metadata plugin, I have here listed all folders with coresponding annotations.
How I can debug further? This is a test server so I can stress it.
-- Mihai Bădici http://mihai.badici.ro
On Thursday 26 December 2013 12:23:18 you wrote:
--Repost after subscription as list member ---
I made some tests with metadata support in dovecot 2.2.10. Previously I had dovecot 2.2.4 with external metadata plugin who work well.
I use dovecot with roundcube and roundcube plugins from kolab project . First, the feature activation was tricky and rather undocumented. I spent about half hour googling, after that I set:
imap_metadata = yes and mail_attribute_dict = file:%h/shared_metadata
It worked after I changed here : file:%s/shared_metadata
A new folder "imap" was created and the "shared_metadata" file is in that
folder. With previous settings that file was in the mailbox root directory
and was not properly readed.
I think you cold put those lines in the 20-imap.conf example file commented; that way will be easy for us to activate.
Because I changed the location of shared_metadata, all folders was unannotated . I went in folder manager in roundcube and set folder "calendar" as calendar type and so on. That worked and i have:
cat shared_metadata: shared/c4268a04da44bb527c5b0000193e0904/vendor/kolab/folder-type event shared/cd5792367fc9cd5196170000193e0904/vendor/kolab/folder-type event shared/33f55d2e8912195209290000193e0904/vendor/kolab/folder-type event shared/32f55d2e8912195209290000193e0904/vendor/kolab/folder-type contact
However, it looks like the metadata is not properly read after. Calendar and Contacts folders don't appear in roundcube. I have this crash in dovecot's log:
Error: Raw backtrace: /usr/lib/dovecot/libdovecot.so.0(+0x67d81) [0xb7625d81] -> /usr/lib/dovecot/libdovecot.so.0(+0x67e11) [0xb7625e11] -> /usr/lib/dovecot/libdovecot.so.0(i_fatal+0) [0xb75d6af9] -> dovecot/imap() [0x805d3b2] -> dovecot/imap() [0x805d5bc] -> dovecot/imap() [0x805d6c9] -> dovecot/imap(client_handle_input+0x56) [0x805d836] -> dovecot/imap(client_input+0x72) [0x805dcc2] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_call_io+0x38) [0xb7638d98] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run+0x10e) [0xb7639d6e] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_run+0x48) [0xb7638818] -> /usr/lib/dovecot/libdovecot.so.0(master_service_run+0x28) [0xb75dcb68] -> dovecot/imap(main+0x284) [0x8050f34] -> /lib/libc.so.6(__libc_start_main+0xf5) [0xb743f5a5] -> dovecot/imap() [0x80510a5] Dec 26 09:28:49 imap(mihai.badici): Fatal: master: service(imap): child 4919 killed with signal 6 (core dumps disabled)
I logged imap sessions in roundcube and I have:
A0003 GETMETADATA "*" (/private/vendor/kolab/folder-type /shared/vendor/kolab/folder-type)
On a similar server with the "old" metadata plugin, I have here listed all folders with coresponding annotations.
How I can debug further? This is a test server so I can stress it.
-- Mihai Bădici http://mihai.badici.ro
On Sunday 29 December 2013 11:52:23 Mihai Badici wrote:
On Thursday 26 December 2013 12:23:18 you wrote:
--Repost after subscription as list member ---
I made some tests with metadata support in dovecot 2.2.10. Previously I had dovecot 2.2.4 with external metadata plugin who work well.
I use dovecot with roundcube and roundcube plugins from kolab project . First, the feature activation was tricky and rather undocumented. I spent about half hour googling, after that I set:
imap_metadata = yes and mail_attribute_dict = file:%h/shared_metadata
It worked after I changed here : file:%s/shared_metadata I made some investigation and I found Roundcube perform a GETMETADATA "*" (/private/vendor/kolab/folder-type)
to list all special folders. In cmd-getmetadata.c there is a "if" (line 455) who is intended, I think, to avoid the use of wildcards in mailbox name, but at the end the result is an attempt to open a NULL mailbox name who produce the crash. When I remove this condition and recompile dovecot, there are no crashes.
It's not clear for me if GETMETADATA "*" is still legal (there is a reference to rfc 5464 in the code) ; but in both cases there is a bug in the code.
On 12/30/2013 03:25 PM, Mihai Badici wrote:
I made some investigation and I found Roundcube perform a GETMETADATA "*" (/private/vendor/kolab/folder-type) to list all special folders.
This is indeed not specified in RFC5464, but it was in ANNOTATEMORE extension draft. This is very handy and it is supported by Cyrus. Timo fixed this in http://hg.dovecot.org/dovecot-2.2/rev/0c3071ebe44b one day before 2.2.10 release. Didn't it make to the release? -- Aleksander 'A.L.E.C' Machniak LAN Management System Developer [http://lms.org.pl] Roundcube Webmail Developer [http://roundcube.net] --------------------------------------------------- PGP: 19359DC1 @@ GG: 2275252 @@ WWW: http://alec.pl
Zitat von "A.L.E.C" <alec@alec.pl>:
Timo fixed this in http://hg.dovecot.org/dovecot-2.2/rev/0c3071ebe44b one day before 2.2.10 release. Didn't it make to the release? yes
On Monday 30 December 2013 16:48:58 A.L.E.C wrote:
On 12/30/2013 03:25 PM, Mihai Badici wrote:
I made some investigation and I found Roundcube perform a GETMETADATA "*" (/private/vendor/kolab/folder-type) to list all special folders.
This is indeed not specified in RFC5464, but it was in ANNOTATEMORE extension draft. This is very handy and it is supported by Cyrus.
Timo fixed this in http://hg.dovecot.org/dovecot-2.2/rev/0c3071ebe44b one day before 2.2.10 release. Didn't it make to the release?
I will check further. Dovecot crashes only in some particular conditions but it looks like is related with this "*" . There are values for " mail_location" and "mail_attribute_dict" who crash dovecot. With:
mail_location = maildir:~/MAILDIR and
mail_attribute_dict= file:%u/shared_metadata
dovecot works well.
So I think the fix is applied but there is a side effect remaining.
-- Mihai Bădici http://mihai.badici.ro
On Monday 30 December 2013 16:48:58 A.L.E.C wrote:
On 12/30/2013 03:25 PM, Mihai Badici wrote:
I made some investigation and I found Roundcube perform a GETMETADATA "*" (/private/vendor/kolab/folder-type) to list all special folders.
This is indeed not specified in RFC5464, but it was in ANNOTATEMORE extension draft. This is very handy and it is supported by Cyrus.
Timo fixed this in http://hg.dovecot.org/dovecot-2.2/rev/0c3071ebe44b one day before 2.2.10 release. Didn't it make to the release?
This issue strike again I think. I upgraded to dovecot 2.2.12 ( from 2.2.10) and when trying to access calendar I have this error in roundcube:
Invalid argument supplied for foreach() in /usr/share/roundcubemail-1.0/plugins/libkolab/lib/kolab_storage.php on line 1040
When I look at the code, I find the argument came from this call: $folders = self::$imap->get_metadata('*', array(kolab_storage::CTYPE_KEY_PRIVATE));
which means the getmetadata with wildcard was not working again ....
-- Mihai Bădici http://mihai.badici.ro
participants (3)
-
A.L.E.C
-
Andreas Schulze
-
Mihai Badici