Bug#876364: dovecot-sieve: Just discovered imap_sieve/sieve_imapsieve is not set up to work with virtual mailboxes.

Apollon Oikonomopoulos apoikos at debian.org
Thu Sep 21 14:47:25 EEST 2017


Control: tags -1 + moreinfo upstream

[Forwarding this to the Dovecot mailing list, just in case someone can help]

Hi,

Thanks for the report! See my comments inline.

On 11:56 Thu 21 Sep     , Thurgood Angelou wrote:
> Package: dovecot-core
> Version: 1:2.2.32-2
>
> I've just discovered a bug where the sieve plugin (especially IMAP) 
> will not work with a virtual mailbox. I recently found this out when 
> testing a virtual mailbox setup and I use imap_sieve for SPAM 
> filtering so to lose that would be painful.
> 
> This is what is reported in dovecot's debug log...
> 
> Sep 21 10:53:01 imap(personal at othersider92.com): Panic: file mail-index-map.c: line 549 (mail_index_map_lookup_seq_range): assertion failed: (first_uid > 0)
> Sep 21 10:53:01 imap(personal at othersider92.com): Error: Raw backtrace: /usr/lib/dovecot/libdovecot.so.0(+0x9f0a2) [0x7f4226fd50a2] -> /usr/lib/dovecot/libdovecot.so.0(+0x9f19a) [0x7f4226fd519a] -> /usr/lib/dovecot/libdovecot.so.0(i_fatal+0) [0x7f4226f65cf8] -> /usr/lib/dovecot/libdovecot-storage.so.0(mail_index_map_lookup_seq_range+0x120) [0x7f422733dae0] -> /usr/lib/dovecot/libdovecot-storage.so.0(+0xe8d1d) [0x7f422734cd1d] -> /usr/lib/dovecot/libdovecot-storage.so.0(mail_index_lookup_seq+0xf) [0x7f4227350e9f] -> /usr/lib/dovecot/modules/lib20_virtual_plugin.so(+0x82aa) [0x7f422678a2aa] -> /usr/lib/dovecot/modules/lib95_imap_sieve_plugin.so(+0x708c) [0x7f422657d08c] -> /usr/lib/dovecot/libdovecot-storage.so.0(mailbox_transaction_commit_get_changes+0x52) [0x7f42272adca2] -> dovecot/imap(+0x10084) [0x556502adb084] -> dovecot/imap(command_exec+0x5c) [0x556502ae7d9c] -> dovecot/imap(+0x1b322) [0x556502ae6322] -> dovecot/imap(+0x1b3bc) [0x556502ae63bc] -> dovecot/imap(client_handle_input
>  +0x18d) [0x556502ae677d] -> dovecot/imap(client_input+0xac) [0x556502ae6ccc] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_call_io+0x52) [0x7f4226fea742] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run_internal+0x12e) [0x7f4226febd8e] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run+0x36) [0x7f4226fea7d6] -> /usr/lib/dovecot/libdovecot.so.0(io_loop_run+0x38) [0x7f4226fea988] -> /usr/lib/dovecot/libdovecot.so.0(master_service_run+0x13) [0x7f4226f70353] -> dovecot/imap(main+0x329) [0x556502ad9139] -> /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf1) [0x7f4226bb92e1] -> dovecot/imap(_start+0x2a) [0x556502ad92ca]

After mixing in the debug symbols, this backtrace becomes:

/usr/lib/dovecot/libdovecot.so.0(+0x9f0a2) [0x7f4226fd50a2]
    default_fatal_finish at ./src/lib/failures.c:195
/usr/lib/dovecot/libdovecot.so.0(+0x9f19a) [0x7f4226fd519a]
    ?? at ./src/lib/failures.c:670
/usr/lib/dovecot/libdovecot.so.0(i_fatal+0) [0x7f4226f65cf8]
    i_fatal at ./src/lib/failures.c:280
/usr/lib/dovecot/libdovecot-storage.so.0(mail_index_map_lookup_seq_range+0x120) [0x7f422733dae0]
    mail_index_map_lookup_seq_range at ./src/lib-index/mail-index-map.c:550
/usr/lib/dovecot/libdovecot-storage.so.0(+0xe8d1d) [0x7f422734cd1d]
    tview_lookup_seq_range at ./src/lib-index/mail-index-transaction-view.c:178
/usr/lib/dovecot/libdovecot-storage.so.0(mail_index_lookup_seq+0xf) [0x7f4227350e9f]
    mail_index_lookup_seq at ./src/lib-index/mail-index-view.c:522
/usr/lib/dovecot/modules/lib20_virtual_plugin.so(+0x82aa) [0x7f422678a2aa]
    virtual_mail_set_uid at ./src/plugins/virtual/virtual-mail.c:213                                              
/usr/lib/dovecot/modules/lib95_imap_sieve_plugin.so(+0x708c) [0x7f422657d08c]
    imap_sieve_mailbox_transaction_run at ./pigeonhole/src/plugins/imapsieve/imap-sieve-storage.c:752 (inlined by: imap_sieve_mailbox_transaction_commit at ./pigeonhole/src/plugins/imapsieve/imap-sieve-storage.c:807)
/usr/lib/dovecot/libdovecot-storage.so.0(mailbox_transaction_commit_get_changes+0x52) [0x7f42272adca2]
    mailbox_transaction_commit_get_changes at ./src/lib-storage/mail-storage.c:2083
dovecot/imap(+0x10084) [0x556502adb084]
    cmd_copy_full at ./src/imap/cmd-copy.c:146
dovecot/imap(command_exec+0x5c) [0x556502ae7d9c]
    command_exec at ./src/imap/imap-commands.c:200
dovecot/imap(+0x1b322) [0x556502ae6322]
    client_command_input at ./src/imap/imap-client.c:1088
dovecot/imap(+0x1b3bc) [0x556502ae63bc]
    client_command_input at ./src/imap/imap-client.c:1150
dovecot/imap(client_handle_input+0x18d) [0x556502ae677d]
    client_handle_input at ./src/imap/imap-client.c:1203
dovecot/imap(client_input+0xac) [0x556502ae6ccc]
    client_input at ./src/imap/imap-client.c:1249
/usr/lib/dovecot/libdovecot.so.0(io_loop_call_io+0x52) [0x7f4226fea742]
    io_loop_call_io at ./src/lib/ioloop.c:600
/usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run_internal+0x12e) [0x7f4226febd8e]
    io_loop_handler_run_internal at ./src/lib/ioloop-epoll.c:223
/usr/lib/dovecot/libdovecot.so.0(io_loop_handler_run+0x36) [0x7f4226fea7d6]
    io_loop_handler_run at ./src/lib/ioloop.c:648
/usr/lib/dovecot/libdovecot.so.0(io_loop_run+0x38) [0x7f4226fea988]
    io_loop_run at ./src/lib/ioloop.c:622
/usr/lib/dovecot/libdovecot.so.0(master_service_run+0x13) [0x7f4226f70353]
    master_service_run at ./src/lib-master/master-service.c:667
dovecot/imap(main+0x329) [0x556502ad9139]
    main at ./src/imap/main.c:491                                                         
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf1) [0x7f4226bb92e1]
    __libc_start_main at ../csu/libc-start.c:325
dovecot/imap(_start+0x2a) [0x556502ad92ca]
    start at ??:0                                             

> -- System Information:
> Debian Release: 8.2
>   APT prefers oldstable-updates
>   APT policy: (500, 'oldstable-updates'), (500, 'unstable'), (500, 'testing'), (500, 'oldstable')
> Architecture: amd64 (x86_64)
> 
> Kernel: Linux 3.16.0-4-amd64 (SMP w/2 CPU cores)
> Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE=en_GB:en (charmap=UTF-8)
> Shell: /bin/sh linked to /bin/dash
> Init: systemd (via /run/systemd/system)
> 
> Versions of packages dovecot-sieve depends on:
> ii  dovecot-core  1:2.2.32-2
> ii  libc6         2.24-17
> ii  ucf           3.0030
> 
> dovecot-sieve recommends no packages.
> 
> dovecot-sieve suggests no packages.
> 
> Versions of packages dovecot-sieve is related to:
> ii  dovecot-core [dovecot-common]  1:2.2.32-2
> pn  dovecot-dbg                    <none>
> pn  dovecot-dev                    <none>
> ii  dovecot-gssapi                 1:2.2.32-2
> ii  dovecot-imapd                  1:2.2.32-2
> ii  dovecot-ldap                   1:2.2.32-2
> ii  dovecot-lmtpd                  1:2.2.32-2
> ii  dovecot-managesieved           1:2.2.32-2
> ii  dovecot-mysql                  1:2.2.32-2
> pn  dovecot-pgsql                  <none>
> pn  dovecot-pop3d                  <none>
> ii  dovecot-sieve                  1:2.2.32-2
> pn  dovecot-sqlite                 <none>

Could you also include the output of doveconf -n?

Regards,
Apollon


More information about the dovecot mailing list