virtual mailbox segfault
Tóth Balázs
zsalab at gmail.com
Mon Dec 15 16:41:27 UTC 2014
Hello,
I have a segfault problem, and I can not resolve myself.
The details below (stack trace, config....). Maybe important to reproduce, everithing working well until I connect with SoGo ActiveSync (SoGo web, and other IMAP clients are working well). So maybe the SoGo send something magical command if the user client use the ActiveSyn... (the IMAP debug attached too)
Thanks, Balazs Toth
Program terminated with signal 11, Segmentation fault.
#0 0x000002ba68e83609 in array_count_i (array=0x52d1cf10b8) at ../../../src/lib/array.h:140
warning: Source file is more recent than executable.
140 return array->buffer->used / array->element_size;
(gdb) bt full
#0 0x000002ba68e83609 in array_count_i (array=0x52d1cf10b8) at ../../../src/lib/array.h:140
No locals.
#1 array_get_i (count_r=<synthetic pointer>, array=0x52d1cf10b8) at ../../../src/lib/array.h:188
No locals.
#2 virtual_storage_set_have_guid_flags (mbox=0x52d1cf0de0) at virtual-storage.c:498
i = <optimized out>
count = <optimized out>
status = {messages = 3519949744, recent = 82, unseen = 2, uidvalidity = 0, uidnext = 1856604872, first_unseen_seq = 964, first_recent_uid = 3519949992, last_cached_seq = 82,
highest_modseq = 355707281680, highest_pvt_modseq = 2999686621158, keywords = 0x52d1cf0de0, permanent_flags = 3520008512, permanent_keywords = 0, allow_new_keywords = 1, nonpermanent_modseqs = 0,
no_modseq_tracking = 0, have_guids = 1, have_save_guids = 0, have_only_guid128 = 1}
bboxes = 0x0
opened = <optimized out>
#3 virtual_storage_get_status (box=0x52d1cf0de0, items=<optimized out>, status_r=0x3c46ea98b90) at virtual-storage.c:537
mbox = 0x52d1cf0de0
#4 0x000002ba694a20e4 in fts_mailbox_get_status (box=0x52d1cf0de0, items=0, status_r=0x3c46ea98b90) at fts-storage.c:94
fbox = <optimized out>
#5 0x000002ba6a4e47a4 in acl_mailbox_get_status (box=0x52d1cf0de0, items=0, status_r=0x3c46ea98b90) at acl-mailbox.c:542
abox = <optimized out>
#6 0x000002ba6b409966 in mailbox_get_status (box=0x52d1cf0de0, items=0, status_r=status_r at entry=0x3c46ea98b90) at mail-storage.c:1570
__FUNCTION__ = "mailbox_get_status"
#7 0x00000052d01a191b in imap_status_get (cmd=cmd at entry=0x52d1ce6110, ns=ns at entry=0x52d1ce1ab0, mailbox=mailbox at entry=0x52d1c9e160 "virtual/Expunged", items=items at entry=0x3c46ea98b70,
result_r=result_r at entry=0x3c46ea98b90) at imap-status.c:84
client = 0x52d1ce55b0
box = 0x52d1cf0de0
errstr = <optimized out>
ret = 0
#8 0x00000052d0196b29 in cmd_status (cmd=0x52d1ce6110) at cmd-status.c:40
client = 0x52d1ce55b0
args = 0x52d1ce8968
list_args = 0x52d1ce8b18
items = {status = 0, metadata = MAILBOX_METADATA_GUID}
result = {status = {messages = 0, recent = 0, unseen = 0, uidvalidity = 0, uidnext = 0, first_unseen_seq = 0, first_recent_uid = 0, last_cached_seq = 0, highest_modseq = 0, highest_pvt_modseq = 0,
keywords = 0x0, permanent_flags = 0, permanent_keywords = 0, allow_new_keywords = 0, nonpermanent_modseqs = 0, no_modseq_tracking = 0, have_guids = 0, have_save_guids = 0, have_only_guid128 = 0},
metadata = {guid = "\027\000\000\000\000\000\000\000\000\337\354\000\027\225\023J", virtual_size = 355707281760, cache_fields = 0x52d1cd1470, precache_fields = 3519963648,
backend_ns_prefix = 0x52d1ce6110 "", backend_ns_type = 3519963488}, error = MAIL_ERROR_TEMP, errstr = 0x52d1ca7288 "\240\200\312\321R"}
ns = 0x52d1ce1ab0
mailbox = 0x52d1c9e160 "virtual/Expunged"
orig_mailbox = 0x52d1ce8ac8 "virtual/Expunged"
selected_mailbox = false
#9 0x00000052d019aebc in command_exec (cmd=cmd at entry=0x52d1ce6110) at imap-commands.c:158
hook = 0x52d1ca6fa0
ret = <optimized out>
#10 0x00000052d0199e60 in client_command_input (cmd=cmd at entry=0x52d1ce6110) at imap-client.c:782
client = 0x52d1ce55b0
command = <optimized out>
__FUNCTION__ = "client_command_input"
#11 0x00000052d0199ef4 in client_command_input (cmd=0x52d1ce6110) at imap-client.c:843
client = 0x52d1ce55b0
command = <optimized out>
__FUNCTION__ = "client_command_input"
Dovecot version: 2.2.15
Debian 7.7 (x64)
FS: ext4
dovecot -n:
# 2.2.15: /etc/dovecot/dovecot.conf
# OS: Linux 3.14.24-kvm-guest-intel64-grsec x86_64 Debian 7.7
auth_cache_negative_ttl = 15 mins
auth_cache_size = 16 M
auth_cache_ttl = 8 hours
auth_master_user_separator = *
auth_mechanisms = plain login
auth_verbose = yes
auth_worker_max_count = 32
default_client_limit = 1024
default_process_limit = 64
deliver_log_format = msgid=%m [%f: %s]: %$
dict {
expire = pgsql:/etc/dovecot/sql/expire.conf
}
first_valid_gid = 8
first_valid_uid = 8
info_log_path = /var/log/dovecot/info.log
last_valid_gid = 8
last_valid_uid = 8
log_path = /var/log/dovecot/server.log
log_timestamp = "%Y-%m-%d %H:%M:%S "
login_greeting = Ready
mail_location = maildir:~/mail:INDEX=~/indexes/private
mail_plugins = acl expire fts fts_lucene lazy_expunge quota zlib mail_log notify stats mailbox_alias trash virtual
mail_shared_explicit_inbox = yes
mail_temp_dir = /run/shm/dovecot
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave
namespace {
list = children
location = maildir:/var/mail/virtual/%%d/%%n/mail:INDEX=~/indexes/shared/%%u
prefix = shared/%%u/
separator = /
subscriptions = no
type = shared
}
namespace {
list = children
location = maildir:/var/mail/virtual/%d/PUBLIC:INDEX=~/indexes/public
prefix = public/
separator = /
subscriptions = no
type = public
}
namespace expunged {
hidden = yes
list = no
location = maildir:~/expunged:INDEX=~/indexes/expunged
prefix = expunged/
separator = /
type = private
}
namespace inbox {
inbox = yes
location = maildir:~/mail:INDEX=~/indexes/private
mailbox Archive {
auto = subscribe
special_use = \Archive
}
mailbox Drafts {
auto = subscribe
special_use = \Drafts
}
mailbox Junk {
auto = subscribe
special_use = \Junk
}
mailbox Sent {
auto = subscribe
special_use = \Sent
}
mailbox "Sent Messages" {
special_use = \Sent
}
mailbox Trash {
auto = subscribe
special_use = \Trash
}
mailbox virtual/All {
special_use = \All
}
mailbox virtual/Flagged {
special_use = \Flagged
}
prefix =
separator = /
type = private
}
namespace virtual {
location = virtual:/etc/dovecot/virtual:INDEX=~/indexes/virtual
prefix = virtual/
separator = /
subscriptions = no
type = private
}
passdb {
args = /etc/dovecot/sql/auth.conf
driver = sql
}
passdb {
args = /etc/dovecot/sql/masteruser.conf
driver = sql
master = yes
pass = yes
}
plugin {
acl = vfile:/etc/dovecot/acl
acl_shared_dict = file:/var/mail/virtual/%d/shared-mailboxes.db
antispam_backend = MAILTRAIN
antispam_mail_notspam = --ham
antispam_mail_sendmail = /usr/bin/sa-learn
antispam_mail_sendmail_args = --username=%u
antispam_mail_spam = --spam
antispam_signature_missing = move
antispam_spam = Junk
antispam_trash = Trash
deleted_to_trash_folder = Trash
expire = *
expire_dict = proxy::expire
fts = lucene
lazy_expunge = expunged/
lazy_expunge_only_last_instance = yes
mail_log_events = delete undelete expunge copy mailbox_create mailbox_delete mailbox_rename
mail_log_fields = uid box msgid size from subject
mailbox_alias_new = Sent Messages
mailbox_alias_new2 = Sent Items
mailbox_alias_new3 = sent-mail
mailbox_alias_new4 = Elküldött elemek
mailbox_alias_new5 = Spam
mailbox_alias_new6 = Levélszemét
mailbox_alias_new7 = Deleted Items
mailbox_alias_new8 = Deleted Messages
mailbox_alias_new9 = Törölt elemek
mailbox_alias_old = Sent
mailbox_alias_old2 = Sent
mailbox_alias_old3 = Sent
mailbox_alias_old4 = Sent
mailbox_alias_old5 = Junk
mailbox_alias_old6 = Junk
mailbox_alias_old7 = Trash
mailbox_alias_old8 = Trash
mailbox_alias_old9 = Trash
quota = maildir:User quota
quota_rule = *:storage=16G
quota_rule2 = Trash:storage=+100M
quota_rule3 = Junk:storage=+100M
quota_warning = storage=95%% quota-warning 95 %u
quota_warning2 = storage=80%% quota-warning 80 %u
sieve = ~/.dovecot.sieve
sieve_after = /var/lib/dovecot-sieve/default
sieve_dir = ~/sieve
sieve_max_actions = 64
sieve_max_redirects = 64
sieve_max_script_size = 2M
sieve_quota_max_scripts = 8
stats_command_min_time = 1 mins
stats_domain_min_time = 12 hours
stats_ip_min_time = 12 hours
stats_memory_limit = 64 M
stats_refresh = 5s
stats_session_min_time = 15 mins
stats_track_cmds = yes
stats_user_min_time = 1 hours
trash = /etc/dovecot/dovecot-trash.conf.ext
}
protocols = " imap lmtp sieve pop3"
service auth-worker {
unix_listener auth-worker {
group = mail
mode = 0660
user = dovecot
}
user = mail
}
service auth {
unix_listener auth-userdb {
group = mail
mode = 0660
user = dovecot
}
user = mail
}
service dict {
unix_listener dict {
group = mail
mode = 0660
user = dovecot
}
user = mail
}
service imap-login {
process_min_avail = 8
service_count = 16
}
service lmtp {
process_min_avail = 5
unix_listener lmtp {
group = mail
mode = 0660
user = Debian-exim
}
user = mail
}
service pop3-login {
process_min_avail = 8
service_count = 16
}
service quota-warning {
executable = script /usr/bin/dovecot-quota-warning.sh
user = mail
}
service stats {
fifo_listener stats-mail {
group = mail
mode = 0660
user = dovecot
}
user = mail
}
ssl_cert = </etc/ssl/certs/dovecot.crt
ssl_key = </etc/ssl/private/dovecot.key
userdb {
driver = prefetch
}
userdb {
args = /etc/dovecot/sql/auth.conf
driver = sql
}
protocol lmtp {
mail_plugins = acl expire fts fts_lucene lazy_expunge quota zlib mail_log notify stats mailbox_alias trash virtual sieve
}
protocol imap {
imap_max_line_length = 64 k
mail_max_userip_connections = 16
mail_plugins = acl expire fts fts_lucene lazy_expunge quota zlib mail_log notify stats mailbox_alias trash virtual antispam imap_acl imap_quota imap_stats deleted_to_trash
}
protocol pop3 {
mail_max_userip_connections = 16
mail_plugins = acl expire fts fts_lucene lazy_expunge quota zlib mail_log notify stats mailbox_alias trash virtual
}
-----------------------------------
S[0x22802185b0]: * OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE STARTTLS AUTH=PLAIN AUTH=LOGIN] Ready
C[0x227f9d99b0]: 1 login "test at acme.com" "password"
S[0x22802185b0]: 1 OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS THREAD=ORDEREDSUBJECT MULTIAPPEND URL-PARTIAL CATENATE UNSELECT CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS SPECIAL-USE BINARY MOVE SEARCH=FUZZY QUOTA ACL RIGHTS=texk] Logged in
C[0x227f9d99b0]: 2 LIST "" ""
S[0x22802185b0]: * LIST (\Noselect) "/" ""
S[0x22802185b0]: 2 OK List completed.
C[0x227f9d99b0]: 3 select "INBOX"
S[0x22802185b0]: * FLAGS (\Answered \Flagged \Deleted \Seen \Draft $Forwarded)
S[0x22802185b0]: * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft $Forwarded \*)] Flags permitted.
S[0x22802185b0]: * 2 EXISTS
S[0x22802185b0]: * 0 RECENT
S[0x22802185b0]: * OK [UIDVALIDITY 1398680969] UIDs valid
S[0x22802185b0]: * OK [UIDNEXT 9] Predicted next UID
S[0x22802185b0]: * OK [HIGHESTMODSEQ 14] Highest
S[0x22802185b0]: 3 OK [READ-WRITE] Select completed (0.000 secs).
C[0x227f9d99b0]: 4 LIST "" ""
S[0x22802185b0]: * LIST (\Noselect) "/" ""
S[0x22802185b0]: 4 OK List completed.
C[0x227f9d99b0]: 5 setannotation "virtual/Expunged" "/comment" ("value.priv" "lasvegas_laxius_hu_54b_1a3f460d_53")
S[0x22802185b0]: 5 BAD Error in IMAP command SETANNOTATION: Unknown command.
C[0x227f9d99b0]: 6 status "virtual/Expunged" (x-guid)
More information about the dovecot
mailing list