[Dovecot] Dovecot 2.0beta3: Crash with mail_log plugin enabled

Thomas Leuxner tlx at leuxner.net
Sun Mar 14 09:26:27 EET 2010


Latest from Mercurial. Dovecot crashes with 'mail_log' and 'notify' plugins enabled when deleting a message:

[08:22] root spectre:~# gdb /usr/lib/dovecot/imap /tmp/core 
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu"...

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/dovecot/libdovecot-storage.so.0...Reading symbols from /usr/lib/debug/usr/lib/dovecot/libdovecot-storage.so.0.0.0...done.
done.
Loaded symbols for /usr/lib/dovecot/libdovecot-storage.so.0
Reading symbols from /usr/lib/dovecot/libdovecot.so.0...Reading symbols from /usr/lib/debug/usr/lib/dovecot/libdovecot.so.0.0.0...done.
done.
Loaded symbols for /usr/lib/dovecot/libdovecot.so.0
Reading symbols from /lib/libdl.so.2...done.
Loaded symbols for /lib/libdl.so.2
Reading symbols from /lib/librt.so.1...done.
Loaded symbols for /lib/librt.so.1
Reading symbols from /lib/libc.so.6...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/ld-linux-x86-64.so.2...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Reading symbols from /lib/libpthread.so.0...done.
Loaded symbols for /lib/libpthread.so.0
Reading symbols from /usr/lib/dovecot/modules/lib01_acl_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib01_acl_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib01_acl_plugin.so
Reading symbols from /usr/lib/dovecot/modules/lib02_imap_acl_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib02_imap_acl_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib02_imap_acl_plugin.so
Reading symbols from /usr/lib/dovecot/modules/lib10_quota_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib10_quota_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib10_quota_plugin.so
Reading symbols from /usr/lib/dovecot/modules/lib11_imap_quota_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib11_imap_quota_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib11_imap_quota_plugin.so
Reading symbols from /usr/lib/dovecot/modules/lib15_notify_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib15_notify_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib15_notify_plugin.so
Reading symbols from /usr/lib/dovecot/modules/lib20_mail_log_plugin.so...Reading symbols from /usr/lib/debug/usr/lib/dovecot/modules/lib20_mail_log_plugin.so...done.
done.
Loaded symbols for /usr/lib/dovecot/modules/lib20_mail_log_plugin.so
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
Core was generated by `dovecot/imap'.
Program terminated with signal 6, Aborted.
[New process 2151]
#0  0x00007f5c79480ed5 in raise () from /lib/libc.so.6
#0  0x00007f5c79480ed5 in raise () from /lib/libc.so.6
No symbol table info available.
#1  0x00007f5c794823f3 in abort () from /lib/libc.so.6
No symbol table info available.
#2  0x00007f5c79be62c5 in default_fatal_finish (type=<value optimized out>, status=0) at failures.c:164
	backtrace = 0x61f660 "/usr/lib/dovecot/libdovecot.so.0 [0x7f5c79be62b2] -> /usr/lib/dovecot/libdovecot.so.0 [0x7f5c79be631a] -> /usr/lib/dovecot/libdovecot.so.0(i_error+0) [0x7f5c79be66c3] -> /usr/lib/dovecot/libdovecot-st"...
#3  0x00007f5c79be631a in i_internal_fatal_handler (type=LOG_TYPE_PANIC, status=0, fmt=<value optimized out>, args=<value optimized out>) at failures.c:592
No locals.
#4  0x00007f5c79be66c3 in i_panic (format=<value optimized out>) at failures.c:230
	args = {{gp_offset = 40, fp_offset = 48, overflow_arg_area = 0x7fffffffd370, reg_save_area = 0x7fffffffd2b0}}
#5  0x00007f5c79e72748 in view_lookup_uid (view=0x6614c0, seq=0, uid_r=0x7fffffffd39c) at mail-index-view.c:210
	__PRETTY_FUNCTION__ = "view_lookup_uid"
#6  0x00007f5c79e589c6 in mail_cache_decision_state_update (view=0x661800, seq=2151, field=12) at mail-cache-decisions.c:82
	cache = (struct mail_cache *) 0x65e790
	hdr = <value optimized out>
	uid = <value optimized out>
	__PRETTY_FUNCTION__ = "mail_cache_decision_state_update"
#7  0x00007f5c79e5a4b0 in mail_cache_lookup_headers (view=0x661800, dest=0x67be28, seq=0, field_idxs=0x7fffffffd56c, fields_count=1) at mail-cache-lookup.c:484
	_data_stack_cur_id = 5
	ret = <value optimized out>
#8  0x00007f5c79e88d22 in index_mail_get_raw_headers (mail=0x67b618, field=0x7f5c78608dc7 "Message-ID", value_r=0x7fffffffd5c8) at index-mail-headers.c:614
	headers = {0x67b618 "\230?e", 0x7f5c79bfda98 "H\201??"}
	value = <value optimized out>
	headers_ctx = <value optimized out>
	data = <value optimized out>
	field_idx = 12
	dest = (string_t *) 0x67be28
	i = <value optimized out>
	len = <value optimized out>
	ret = <value optimized out>
	header_values = {arr = {buffer = 0x661ec8, element_size = 6692576}, v = 0x661ec8, v_modifiable = 0x661ec8}
	__PRETTY_FUNCTION__ = "index_mail_get_raw_headers"
#9  0x00007f5c79e892bf in index_mail_get_first_header (_mail=0x67b618, field=0x7f5c78608dc7 "Message-ID", decode_to_utf8=false, value_r=0x7fffffffd620) at index-mail-headers.c:771
	list = (const char * const *) 0x80
	ret = 8
	i = 0
#10 0x00007f5c786085cc in mail_log_append_mail_header (str=0x61f4d8, mail=0x867, name=0x7f5c78608dd2 "msgid", header=0xffffffffffffffff <Address 0xffffffffffffffff out of bounds>) at mail-log-plugin.c:174
	value = 0x8 <Address 0x8 out of bounds>
#11 0x00007f5c786087be in mail_log_append_mail_message (ctx=0x661ec8, mail=0x67b618, event=MAIL_LOG_EVENT_SAVE, desc=0x61f4b0 "copy from INBOX") at mail-log-plugin.c:219
	_data_stack_cur_id = 4
#12 0x00007f5c7880ba57 in notify_contexts_mail_copy (src=0x6636f8, dst=0x67b618) at notify-plugin.c:69
	ctx = (struct notify_context *) 0x642310
	mail_txn = (struct notify_mail_txn *) 0x0
#13 0x00007f5c7880c1e3 in notify_copy (ctx=0x667ed0, mail=0x6636f8) at notify-storage.c:113
	ret = <value optimized out>
#14 0x00007f5c79e4e29a in mailbox_copy (_ctx=0x7fffffffd7a0, mail=0x6636f8) at mail-storage.c:1330
	ctx = (struct mail_save_context *) 0x667ed0
	box = (struct mailbox *) 0x65cc98
	keywords = (struct mail_keywords *) 0x67b300
	ret = <value optimized out>
#15 0x0000000000409631 in cmd_copy (cmd=0x650f38) at cmd-copy.c:66
	client = (struct client *) 0x6507d8
	dest_ns = <value optimized out>
	dest_storage = <value optimized out>
	destbox = (struct mailbox *) 0x65cc98
	t = (struct mailbox_transaction_context *) 0x661080
	search_args = (struct mail_search_args *) 0x65bc88
	messageset = 0x652888 "4891"
	mailbox = 0x652890 "Trash"
	src_uidset = <value optimized out>
	sync_flags = <value optimized out>
	imap_flags = <value optimized out>
	changes = {pool = 0x0, uid_validity = 9, saved_uids = {arr = {buffer = 0x7f5c795563a0, element_size = 0}, v = 0x7f5c795563a0, v_modifiable = 0x7f5c795563a0}, ignored_uid_changes = 6418664, 
  ignored_modseq_changes = 0}
	copy_count = 1
	msg = <value optimized out>
	ret = 1
	__PRETTY_FUNCTION__ = "cmd_copy"
#16 0x000000000040f9dc in client_command_input (cmd=0x650f38) at imap-client.c:647
	client = (struct client *) 0x6507d8
	command = <value optimized out>
	__PRETTY_FUNCTION__ = "client_command_input"
#17 0x000000000040fa8d in client_command_input (cmd=0x650f38) at imap-client.c:697
	client = (struct client *) 0x6507d8
	command = (struct command *) 0x6
	__PRETTY_FUNCTION__ = "client_command_input"
#18 0x000000000040fc05 in client_handle_input (client=0x6507d8) at imap-client.c:738
	_data_stack_cur_id = 3
	ret = 25
	remove_io = <value optimized out>
	handled_commands = false
	__PRETTY_FUNCTION__ = "client_handle_input"
#19 0x0000000000410642 in client_input (client=0x6507d8) at imap-client.c:789
	cmd = <value optimized out>
	output = (struct ostream *) 0x650db8
	bytes = <value optimized out>
	__PRETTY_FUNCTION__ = "client_input"
#20 0x00007f5c79bf0feb in io_loop_handler_run (ioloop=<value optimized out>) at ioloop-epoll.c:208
	ctx = (struct ioloop_handler_context *) 0x6277d0
	event = (const struct epoll_event *) 0x627840
	list = (struct io_list *) 0x650e90
	io = (struct io_file *) 0x65b820
	tv = {tv_sec = 1799, tv_usec = 999883}
	t_id = 2
	msecs = <value optimized out>
	ret = 1
	call = <value optimized out>
#21 0x00007f5c79bf0168 in io_loop_run (ioloop=0x6275c0) at ioloop.c:350
No locals.
#22 0x00007f5c79be0143 in master_service_run (service=0x627490, callback=0x867) at master-service.c:478
No locals.
#23 0x0000000000418681 in main (argc=1, argv=0x627370) at main.c:313
	service_flags = <value optimized out>
	storage_service_flags = <value optimized out>
	postlogin_socket_path = 0x0
	set_roots = {0x41b980, 0x0}



More information about the dovecot mailing list