[Dovecot] Segfault in imap process
I'm running the CVS version from May 9. I've seen these errors in the log file before (every time I open my mailbox), but this is the first time it crashed.
Todd
dovecot: May 11 15:00:18 Error: 8438 IMAP(todd.bluegenesis.com): Corrupted index cache file /mailhome/new/t/b/todd.bluegenesis.com/.imap/INBOX/dovecot.index.cache: Duplicated field in header: hdr.RESENT-TO dovecot: May 11 15:02:00 Error: child 8438 (imap) killed with signal 11
Core was generated by `imap'. Program terminated with signal 11, Segmentation fault.
(gdb) bt full #0 0x08074d10 in index_mail_get_flags (_mail=0x80c86d0) at index-mail.c:162 data = (struct index_mail_data *) 0x80c8734 #1 0x0808c86d in mail_get_flags (mail=0xb7c71834) at mail.c:32 No locals. #2 0x0805a6a5 in fetch_flags (ctx=0x80bee70, mail=0x80c86d0, context=0x0) at imap-fetch.c:444 flags = Variable "flags" is not available. (gdb) bt #0 0x08074d10 in index_mail_get_flags (_mail=0x80c86d0) at index-mail.c:162 #1 0x0808c86d in mail_get_flags (mail=0xb7c71834) at mail.c:32 #2 0x0805a6a5 in fetch_flags (ctx=0x80bee70, mail=0x80c86d0, context=0x0) at imap-fetch.c:444 #3 0x0805abdc in imap_fetch (ctx=0x80bee70) at imap-fetch.c:264 #4 0x0805676b in cmd_fetch (cmd=0x80bcb98) at cmd-fetch.c:165 #5 0x08059635 in _client_input (context=0x80bcb58) at client.c:334 #6 0x0809e1da in io_loop_handler_run (ioloop=0x80bb9b0) at ioloop-poll.c:184 #7 0x0809d8f9 in io_loop_run (ioloop=0x80bb9b0) at ioloop.c:218 #8 0x08060537 in main (argc=1, argv=0xbffffa84, envp=0xbffffa8c) at main.c:228
(gdb) frame #0 0x08074d10 in index_mail_get_flags (_mail=0x80c86d0) at index-mail.c:162 162 data->flags = data->rec->flags & MAIL_FLAGS_MASK; (gdb) p data->rec $3 = (const struct mail_index_record *) 0xb7c71834 (gdb) p data->rec->flags Cannot access memory at address 0xb7c71838
On Wed, 2005-05-11 at 18:32 -0400, Todd Burroughs wrote:
I'm running the CVS version from May 9. I've seen these errors in the log file before (every time I open my mailbox), but this is the first time it crashed.
dovecot: May 11 15:00:18 Error: 8438 IMAP(todd.bluegenesis.com): Corrupted index cache file /mailhome/new/t/b/todd.bluegenesis.com/.imap/INBOX/dovecot.index.cache: Duplicated field in header: hdr.RESENT-TO
You were using mmap_disable=yes, right? May 10 a few fixes were done to it, hopefully fixing this problem too.
(gdb) p data->rec $3 = (const struct mail_index_record *) 0xb7c71834 (gdb) p data->rec->flags Cannot access memory at address 0xb7c71838
You still have the core file? Does "p *data" look like it even contains valid data?
On Fri, 13 May 2005, Timo Sirainen wrote:
On Wed, 2005-05-11 at 18:32 -0400, Todd Burroughs wrote:
I'm running the CVS version from May 9. I've seen these errors in the log file before (every time I open my mailbox), but this is the first time it crashed.
dovecot: May 11 15:00:18 Error: 8438 IMAP(todd.bluegenesis.com): Corrupted index cache file /mailhome/new/t/b/todd.bluegenesis.com/.imap/INBOX/dovecot.index.cache: Duplicated field in header: hdr.RESENT-TO
You were using mmap_disable=yes, right? May 10 a few fixes were done to it, hopefully fixing this problem too.
mmap_disable=yes is set. I'll try the newest from CVS and see what happens. This problem seems rare, since I get the "Duplicated field in header: hdr.RESENT-TO" error all the time, but usually nothing happens.
(gdb) p data->rec $3 = (const struct mail_index_record *) 0xb7c71834 (gdb) p data->rec->flags Cannot access memory at address 0xb7c71838
You still have the core file? Does "p *data" look like it even contains valid data?
Looks like it:
(gdb) p *data $1 = {flags = 0, date = 0, received_date = 1115833693, virtual_size = 4912, physical_size = 4887, sent_date = {time = -1, timezone = 0}, parse_line = { field_idx = 4294967295, start_pos = 170, end_pos = 208, line_num = 39, cache = 1}, parse_line_num = 67, parts = 0x80cadf0, envelope = 0x0, body = 0x0, bodystructure = 0x0, uid_string = 0x0, envelope_data = 0x0, seq = 8820, rec = 0xb7c71834, cache_flags = 0, stream = 0x80d017c, filter_stream = 0x0, hdr_size = {physical_size = 3442, virtual_size = 3442, lines = 66}, body_size = {physical_size = 1445, virtual_size = 1470, lines = 25}, parser_ctx = 0x0, parsing_count = 0, keywords = { buffer = 0x0, element_size = 0}, parse_header = 0, save_envelope = 0, save_sent_date = 0, save_bodystructure_header = 0, save_bodystructure_body = 0, parsed_bodystructure = 0, hdr_size_set = 1, body_size_set = 1, open_mail = 0}
On Fri, 13 May 2005, Timo Sirainen wrote:
On Wed, 2005-05-11 at 18:32 -0400, Todd Burroughs wrote:
I'm running the CVS version from May 9. I've seen these errors in the log file before (every time I open my mailbox), but this is the first time it crashed.
dovecot: May 11 15:00:18 Error: 8438 IMAP(todd.bluegenesis.com): Corrupted index cache file /mailhome/new/t/b/todd.bluegenesis.com/.imap/INBOX/dovecot.index.cache: Duplicated field in header: hdr.RESENT-TO
You were using mmap_disable=yes, right? May 10 a few fixes were done to it, hopefully fixing this problem too.
It happened again with the May 10 fixes...
Looks like exactly the same issue.
Todd
On Sat, 2005-05-14 at 17:55 -0400, Todd Burroughs wrote:
dovecot: May 11 15:00:18 Error: 8438 IMAP(todd.bluegenesis.com): Corrupted index cache file /mailhome/new/t/b/todd.bluegenesis.com/.imap/INBOX/dovecot.index.cache: Duplicated field in header: hdr.RESENT-TO
You were using mmap_disable=yes, right? May 10 a few fixes were done to it, hopefully fixing this problem too.
It happened again with the May 10 fixes...
Looks like exactly the same issue.
I did more fixes to it today :)
participants (2)
-
Timo Sirainen
-
Todd Burroughs