Hi everyone,

   When I'm running a force-resync on my mailbox, it crashes. Unfortunately,
   after the crash, it left multiple new FTS mailboxes.

   Command:

   doveadm -D force-resync -u [1][email protected] '*'

   Error message:

   doveadm: Debug: Mailbox INBOX/fts-flatcurve/current.1756202040958990:
   Mailbox opened
   doveadm: Error: Mailbox INBOX: FTS optimize failed
   doveadm: Error: cmd force-resync: Forcing a resync on mailbox INBOX
   failed: FTS optimize failed
   doveadm: Panic: file mail-user.c: line 185 (mail_user_deinit): assertion
   failed: ((*user)->refcount == 1)
   doveadm: Error: Raw backtrace: #0 fatal_handler_real[0x7f7fcd996190] -> #1
   default_fatal_handler[0x7f7fcd996260] -> #2 i_panic[0x7f7fcd8b5407] -> #3
   mail_user_deinit.cold[0x7f7fcdc5720e] -> #4
   doveadm_mail_next_user[0x55b93b0c16b0] -> #5
   doveadm_cmd_ver2_to_mail_cmd_wrapper[0x55b93b0c33d0] -> #6
   doveadm_cmdline_run[0x55b93b0d76e0] -> #7
   doveadm_cmdline_try_run[0x55b93b0d7ee0] -> #8 main[0x55b93b0b0d10] -> #9
   __libc_start_call_main[0x7f7fcd50827e] -> #10
   __libc_start_main_alias_2[0x7f7fcd50833e] -> #11 _start[0x55b93b0b1320]

   Backtrace:

   #0  __pthread_kill_implementation (threadid=<optimized out>,
   signo=signo@entry=6, no_tid=no_tid@entry=0) at pthread_kill.c:44
   #1  0x00007f7fcd57ae33 in __pthread_kill_internal (threadid=<optimized
   out>, signo=6) at pthread_kill.c:89
   #2  0x00007f7fcd51f7b6 in __GI_raise (sig=sig@entry=6) at
   ../sysdeps/posix/raise.c:26
   #3  0x00007f7fcd50634b in __GI_abort () at abort.c:77
   #4  0x00007f7fcd8b5575 in default_fatal_finish (type=LOG_TYPE_PANIC,
   status=0) at ../lib/failures.c:461
   #5  fatal_handler_real (ctx=<optimized out>, format=<optimized out>,
   args=<optimized out>) at ../lib/failures.c:473
   #6  0x00007f7fcd996283 in default_fatal_handler (ctx=<optimized out>,
   format=<optimized out>, args=<optimized out>) at ../lib/failures.c:481
   #7  0x00007f7fcd8b54d7 in i_panic (format=format@entry=0x7f7fcdd3eac8
   "file %s: line %d (%s): assertion failed: (%s)") at ../lib/failures.c:526
   #8  0x00007f7fcdc57237 in mail_user_deinit (user=<optimized out>) at
   /usr/src/debug/dovecot-2.4.2/src/lib-storage/mail-user.c:185
   #9  mail_user_deinit (user=<optimized out>) at
   /usr/src/debug/dovecot-2.4.2/src/lib-storage/mail-user.c:183
   #10 0x000055b93b0c18f2 in doveadm_mail_next_user (ctx=0x55b93ed9dfb8,
   error_r=<optimized out>) at
   /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm-mail.c:505
   #11 0x000055b93b0c35e7 in doveadm_mail_cmd_exec (ctx=0x55b93ed9dfb8,
   wildcard_user=0x0) at
   /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm-mail.c:705
   #12 doveadm_cmd_ver2_to_mail_cmd_wrapper (cctx=<optimized out>) at
   /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm-mail.c:1034
   #13 0x000055b93b0d7dd7 in doveadm_cmdline_run (argc=<optimized out>,
   argv=0x55b93ed69840, cctx=cctx@entry=0x55b93ed90fa8) at
   /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm-cmd-parse.c:451
   #14 0x000055b93b0d7f8c in doveadm_cmdline_try_run
   (cmd_name=cmd_name@entry=0x55b93ed6987c "force-resync", argc=<optimized
   out>, argv=<optimized out>, cctx=cctx@entry=0x55b93ed90fa8)
      at /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm-cmd.c:160
   #15 0x000055b93b0b101d in main (argc=<optimized out>, argv=<optimized
   out>) at /usr/src/debug/dovecot-2.4.2/src/doveadm/doveadm.c:406
   Unfortunately, this interrupted run left many new mailboxes in place:

   $ doveadm mailbox list -u [2][email protected]
   Junk
   Drafts
   Drafts/fts-flatcurve
   Drafts/fts-flatcurve/current.1756201209435330
   Drafts/fts-flatcurve/index.5092
   Trash
   Trash/fts-flatcurve
   Trash/fts-flatcurve/current.1756242793225435
   Trash/fts-flatcurve/index.5401
   Trash/Junk
   Trash/Junk/fts-flatcurve
   Trash/Junk/fts-flatcurve/index.6279
   Trash/Junk/fts-flatcurve/current.1756366793619309

   Interestingly, a short ago I deleted the Junk mailbox with "doveadm
   mailbox delete -e Junk". Trash/Junk was never a thing.

   Version: 2.4.2

   In case FTS config is useful:

   mail_plugins {
       fts = yes
       fts_flatcurve = yes
       quota = yes
       virtual = yes
   }

   fts flatcurve {
     substring_search = yes
   }

   fts_autoindex = yes

   language en {
     default = yes
   }
   language de {
   }
   language_tokenizers = generic email-address

   Akos

References

   Visible links
   1. mailto:[email protected]
   2. mailto:[email protected]
_______________________________________________
dovecot mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to