Bug 376822 - empty trash or all trash on imap account akonadi doesn't continue
Summary: empty trash or all trash on imap account akonadi doesn't continue
Status: RESOLVED FIXED
Alias: None
Product: Akonadi
Classification: Frameworks and Libraries
Component: server (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: HI crash
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2017-02-22 20:05 UTC by Bruno Friedmann
Modified: 2020-12-17 10:38 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bruno Friedmann 2017-02-22 20:05:51 UTC
Application: akonadiserver (5.4.2)

Qt Version: 5.7.1
Frameworks Version: 5.30.0
Operating System: Linux 4.9.10-1-default x86_64
Distribution: "openSUSE Tumbleweed"

-- Information about the crash:
- What I was doing when the application crashed: select menu empty all trash on imap mail account.
Several hours later nothing changed on the account.
close kmail & korganizer.
do a akonadictl stop
crash occur at that time

from .xsession-error log 

org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_newmailnotifier_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
org.kde.pim.akonadicontrol: ProcessControl: Application "/usr/bin/akonadi_archivemail_agent" stopped unexpectedly ( "Process crashed" )
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_archivemail_agent' crashed. No restart!
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_indexing_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_davgroupware_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_akonotes_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_sendlater_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_notes_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_ical_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_maildispatcher_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_birthdays_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_davgroupware_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_followupreminder_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_mailfilter_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_migration_agent' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_maildir_resource' exited normally...
org.kde.pim.akonadicontrol: Application '/usr/bin/akonadi_imap_resource' exited normally...
KCrash: Application 'akonadiserver' crashing...
KCrash: Attempting to start /usr/lib64/libexec/drkonqi from kdeinit
sock_file=/run/user/1502/kdeinit5__0
QSocketNotifier: Invalid socket 60 and type 'Read', disabling...
QSocketNotifier: Invalid socket 195 and type 'Read', disabling...
QSocketNotifier: Invalid socket 27 and type 'Read', disabling...
QSocketNotifier: Invalid socket 196 and type 'Read', disabling...
QSocketNotifier: Invalid socket 200 and type 'Read', disabling...
QSocketNotifier: Invalid socket 6 and type 'Read', disabling...
QSocketNotifier: Invalid socket 19 and type 'Read', disabling...
QSocketNotifier: Invalid socket 17 and type 'Read', disabling...
QSocketNotifier: Invalid socket 143 and type 'Read', disabling...
QSocketNotifier: Invalid socket 123 and type 'Read', disabling...
QSocketNotifier: Invalid socket 69 and type 'Read', disabling...
QSocketNotifier: Invalid socket 189 and type 'Read', disabling...
QSocketNotifier: Invalid socket 187 and type 'Read', disabling...
terminate called without an active exception
Unable to start Dr. Konqi
Re-raising signal for core dump handling.
org.kde.pim.akonadicontrol: ProcessControl: Application "akonadiserver" stopped unexpectedly ( "Process crashed" )
org.kde.pim.akonadicontrol: Application 'akonadiserver' crashed. No restart!

The crash can be reproduced every time.

-- Backtrace:
Application: Akonadi Server (akonadiserver), signal: Segmentation fault
Using host libthread_db library "/lib64/libthread_db.so.1".
pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
[Current thread is 1 (Thread 0x7f16d74728c0 (LWP 25721))]

Thread 19 (Thread 0x7f1672ffd700 (LWP 24884)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=30000, this=0x7f16bc045520) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=30000, this=0x7f16bc045520) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x7f16bc03ce20, mutex=mutex@entry=0x7f16bc0035a0, time=30000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5af8ae2 in QThreadPoolThread::run (this=0x7f16bc03ce10) at thread/qthreadpool.cpp:133
#5  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16bc03ce10) at thread/qthread_unix.cpp:368
#6  0x00007f16d401e454 in start_thread (arg=0x7f1672ffd700) at pthread_create.c:333
#7  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 18 (Thread 0x7f16727fc700 (LWP 24883)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=30000, this=0x7f16bc0459d0) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=30000, this=0x7f16bc0459d0) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x7f16bc045810, mutex=mutex@entry=0x7f16bc0035a0, time=30000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5af8ae2 in QThreadPoolThread::run (this=0x7f16bc045800) at thread/qthreadpool.cpp:133
#5  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16bc045800) at thread/qthread_unix.cpp:368
#6  0x00007f16d401e454 in start_thread (arg=0x7f16727fc700) at pthread_create.c:333
#7  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 17 (Thread 0x7f16717fa700 (LWP 24882)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=30000, this=0x7f16bc04e6b0) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=30000, this=0x7f16bc04e6b0) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x7f16bc04e4f0, mutex=mutex@entry=0x7f16bc0035a0, time=30000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5af8ae2 in QThreadPoolThread::run (this=0x7f16bc04e4e0) at thread/qthreadpool.cpp:133
#5  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16bc04e4e0) at thread/qthread_unix.cpp:368
#6  0x00007f16d401e454 in start_thread (arg=0x7f16717fa700) at pthread_create.c:333
#7  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 16 (Thread 0x7f1670ff9700 (LWP 24881)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=30000, this=0x7f16bc04e2b0) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=30000, this=0x7f16bc04e2b0) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x7f16bc045c70, mutex=mutex@entry=0x7f16bc0035a0, time=30000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5af8ae2 in QThreadPoolThread::run (this=0x7f16bc045c60) at thread/qthreadpool.cpp:133
#5  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16bc045c60) at thread/qthread_unix.cpp:368
#6  0x00007f16d401e454 in start_thread (arg=0x7f1670ff9700) at pthread_create.c:333
#7  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 15 (Thread 0x7f1671ffb700 (LWP 24880)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=30000, this=0x7f16bc04eb30) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=30000, this=0x7f16bc04eb30) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x7f16bc04e970, mutex=mutex@entry=0x7f16bc0035a0, time=30000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5af8ae2 in QThreadPoolThread::run (this=0x7f16bc04e960) at thread/qthreadpool.cpp:133
#5  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16bc04e960) at thread/qthread_unix.cpp:368
#6  0x00007f16d401e454 in start_thread (arg=0x7f1671ffb700) at pthread_create.c:333
#7  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 14 (Thread 0x7f1610ff9700 (LWP 1348)):
#0  0x00007f16d51e966d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f16d1e01896 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f15fc0008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#4  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f1610ff8d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#5  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#6  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26f6400) at thread/qthread_unix.cpp:368
#7  0x00007f16d401e454 in start_thread (arg=0x7f1610ff9700) at pthread_create.c:333
#8  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 13 (Thread 0x7f16117fa700 (LWP 28726)):
#0  0x00007f16d1e46f49 in g_mutex_lock () from /usr/lib64/libglib-2.0.so.0
#1  0x00007f16d1e00c57 in g_main_context_prepare () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e017bb in ?? () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#4  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f15e80008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#5  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16117f9d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#7  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x271da70) at thread/qthread_unix.cpp:368
#8  0x00007f16d401e454 in start_thread (arg=0x7f16117fa700) at pthread_create.c:333
#9  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 12 (Thread 0x7f16137fe700 (LWP 26734)):
#0  0x00007f16d51e966d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f16d1e01896 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16040008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#4  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16137fdd00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#5  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#6  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26e0e90) at thread/qthread_unix.cpp:368
#7  0x00007f16d401e454 in start_thread (arg=0x7f16137fe700) at pthread_create.c:333
#8  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 11 (Thread 0x7f1613fff700 (LWP 26733)):
#0  0x00007f16d1e46f64 in g_mutex_unlock () from /usr/lib64/libglib-2.0.so.0
#1  0x00007f16d1e00d70 in g_main_context_prepare () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e017bb in ?? () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#4  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f160c0008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#5  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f1613ffdd10, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x000000000057c1c0 in Akonadi::Server::ItemRetriever::exec (this=this@entry=0x7f1613ffe370) at /usr/src/debug/akonadi-16.12.2/src/server/storage/itemretriever.cpp:355
#7  0x0000000000542c91 in Akonadi::Server::FetchHelper::fetchItems (this=this@entry=0x7f1613ffe540) at /usr/src/debug/akonadi-16.12.2/src/server/handler/fetchhelper.cpp:337
#8  0x000000000053ff4b in Akonadi::Server::Fetch::parseStream (this=0x7f160c00c030) at /usr/src/debug/akonadi-16.12.2/src/server/handler/fetch.cpp:47
#9  0x000000000042e6a4 in Akonadi::Server::Connection::slotNewData (this=0x26d18c0) at /usr/src/debug/akonadi-16.12.2/src/server/connection.cpp:247
#10 0x00007f16d5cf7a7e in QtPrivate::QSlotObjectBase::call (a=0x7f1613ffe8d0, r=0x26d18c0, this=<optimized out>) at ../../src/corelib/kernel/qobject_impl.h:101
#11 QMetaObject::activate (sender=0x7f160c0030d0, signalOffset=<optimized out>, local_signal_index=<optimized out>, argv=<optimized out>) at kernel/qobject.cpp:3723
#12 0x00007f16d5cf7709 in QMetaObject::activate (sender=sender@entry=0x7f160c0031c8, signalOffset=<optimized out>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0) at kernel/qobject.cpp:3740
#13 0x00007f16d5cf8027 in QMetaObject::activate (sender=sender@entry=0x7f160c0031c8, m=m@entry=0x7f16d610fec0 <QIODevice::staticMetaObject>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0) at kernel/qobject.cpp:3602
#14 0x00007f16d5d6da00 in QIODevice::readyRead (this=this@entry=0x7f160c0031c8) at .moc/moc_qiodevice.cpp:184
#15 0x00007f16d6902265 in QAbstractSocketPrivate::emitReadyRead (this=this@entry=0x7f160c003220) at socket/qabstractsocket.cpp:1303
#16 0x00007f16d690231c in QAbstractSocketPrivate::canReadNotification (this=0x7f160c003220) at socket/qabstractsocket.cpp:724
#17 0x00007f16d690d121 in QReadNotifier::event (this=<optimized out>, e=<optimized out>) at socket/qnativesocketengine.cpp:1209
#18 0x00007f16d5ccbaeb in doNotify (event=0x7f1613ffeae0, receiver=0x7f160c003460) at kernel/qcoreapplication.cpp:1063
#19 QCoreApplication::notify (event=<optimized out>, receiver=<optimized out>, this=<optimized out>) at kernel/qcoreapplication.cpp:1049
#20 QCoreApplication::notifyInternal2 (receiver=0x7f160c003460, event=event@entry=0x7f1613ffeae0) at kernel/qcoreapplication.cpp:988
#21 0x00007f16d5d2061d in QCoreApplication::sendEvent (event=0x7f1613ffeae0, receiver=<optimized out>) at ../../src/corelib/kernel/qcoreapplication.h:231
#22 socketNotifierSourceDispatch (source=0x7f160c002e00) at kernel/qeventdispatcher_glib.cpp:106
#23 0x00007f16d1e01697 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#24 0x00007f16d1e01900 in ?? () from /usr/lib64/libglib-2.0.so.0
#25 0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#26 0x00007f16d5d2016f in QEventDispatcherGlib::processEvents (this=0x7f160c0008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#27 0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f1613ffed00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#28 0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#29 0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26d9d70) at thread/qthread_unix.cpp:368
#30 0x00007f16d401e454 in start_thread (arg=0x7f1613fff700) at pthread_create.c:333
#31 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 10 (Thread 0x7f1631ffb700 (LWP 25891)):
[KCrash Handler]
#6  QPSQLDriverPrivate::exec (this=0x0, stmt=...) at ../../../sql/drivers/psql/qsql_psql.cpp:224
#7  0x00007f16cbc72f0a in QPSQLResultPrivate::deallocatePreparedStmt (this=this@entry=0x7f16200b35c0) at ../../../sql/drivers/psql/qsql_psql.cpp:335
#8  0x00007f16cbc7336d in QPSQLResult::~QPSQLResult (this=0x7f16200be790, __in_chrg=<optimized out>) at ../../../sql/drivers/psql/qsql_psql.cpp:356
#9  0x00007f16cbc73389 in QPSQLResult::~QPSQLResult (this=0x7f16200be790, __in_chrg=<optimized out>) at ../../../sql/drivers/psql/qsql_psql.cpp:357
#10 0x00007f16d65f6842 in QSqlQueryPrivate::~QSqlQueryPrivate (this=0x7f16200f5860, __in_chrg=<optimized out>) at kernel/qsqlquery.cpp:94
#11 0x00007f16d65f6bda in QSqlQuery::~QSqlQuery (this=<optimized out>, __in_chrg=<optimized out>) at kernel/qsqlquery.cpp:245
#12 0x000000000057b405 in Akonadi::Server::ItemRetriever::exec (this=this@entry=0x7f1631ffa370) at /usr/src/debug/akonadi-16.12.2/src/server/storage/itemretriever.cpp:213
#13 0x0000000000542c91 in Akonadi::Server::FetchHelper::fetchItems (this=this@entry=0x7f1631ffa540) at /usr/src/debug/akonadi-16.12.2/src/server/handler/fetchhelper.cpp:337
#14 0x000000000053ff4b in Akonadi::Server::Fetch::parseStream (this=0x7f16200a7e60) at /usr/src/debug/akonadi-16.12.2/src/server/handler/fetch.cpp:47
#15 0x000000000042e6a4 in Akonadi::Server::Connection::slotNewData (this=0x271c170) at /usr/src/debug/akonadi-16.12.2/src/server/connection.cpp:247
#16 0x00007f16d5cf7a7e in QtPrivate::QSlotObjectBase::call (a=0x7f1631ffa8d0, r=0x271c170, this=<optimized out>) at ../../src/corelib/kernel/qobject_impl.h:101
#17 QMetaObject::activate (sender=0x7f16200032d0, signalOffset=<optimized out>, local_signal_index=<optimized out>, argv=<optimized out>) at kernel/qobject.cpp:3723
#18 0x00007f16d5cf7709 in QMetaObject::activate (sender=sender@entry=0x7f16200033c8, signalOffset=<optimized out>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0) at kernel/qobject.cpp:3740
#19 0x00007f16d5cf8027 in QMetaObject::activate (sender=sender@entry=0x7f16200033c8, m=m@entry=0x7f16d610fec0 <QIODevice::staticMetaObject>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0) at kernel/qobject.cpp:3602
#20 0x00007f16d5d6da00 in QIODevice::readyRead (this=this@entry=0x7f16200033c8) at .moc/moc_qiodevice.cpp:184
#21 0x00007f16d6902265 in QAbstractSocketPrivate::emitReadyRead (this=this@entry=0x7f1620003420) at socket/qabstractsocket.cpp:1303
#22 0x00007f16d690231c in QAbstractSocketPrivate::canReadNotification (this=0x7f1620003420) at socket/qabstractsocket.cpp:724
#23 0x00007f16d690d121 in QReadNotifier::event (this=<optimized out>, e=<optimized out>) at socket/qnativesocketengine.cpp:1209
#24 0x00007f16d5ccbaeb in doNotify (event=0x7f1631ffaae0, receiver=0x7f1620003660) at kernel/qcoreapplication.cpp:1063
#25 QCoreApplication::notify (event=<optimized out>, receiver=<optimized out>, this=<optimized out>) at kernel/qcoreapplication.cpp:1049
#26 QCoreApplication::notifyInternal2 (receiver=0x7f1620003660, event=event@entry=0x7f1631ffaae0) at kernel/qcoreapplication.cpp:988
#27 0x00007f16d5d2061d in QCoreApplication::sendEvent (event=0x7f1631ffaae0, receiver=<optimized out>) at ../../src/corelib/kernel/qcoreapplication.h:231
#28 socketNotifierSourceDispatch (source=0x7f1620003000) at kernel/qeventdispatcher_glib.cpp:106
#29 0x00007f16d1e01697 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#30 0x00007f16d1e01900 in ?? () from /usr/lib64/libglib-2.0.so.0
#31 0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#32 0x00007f16d5d2016f in QEventDispatcherGlib::processEvents (this=0x7f16200008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#33 0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f1631ffad00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#34 0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#35 0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x272dfc0) at thread/qthread_unix.cpp:368
#36 0x00007f16d401e454 in start_thread (arg=0x7f1631ffb700) at pthread_create.c:333
#37 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 9 (Thread 0x7f16baffd700 (LWP 25731)):
#0  0x00007f16d1e46f64 in g_mutex_unlock () from /usr/lib64/libglib-2.0.so.0
#1  0x00007f16d1e017ae in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16a80008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#4  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16baffcd00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#5  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#6  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26d0d30) at thread/qthread_unix.cpp:368
#7  0x00007f16d401e454 in start_thread (arg=0x7f16baffd700) at pthread_create.c:333
#8  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 8 (Thread 0x7f16bb7fe700 (LWP 25730)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185
#1  0x00007f16d5afd37b in QWaitConditionPrivate::wait (time=18446744073709551615, this=0x26e2f30) at thread/qwaitcondition_unix.cpp:143
#2  QWaitCondition::wait (this=this@entry=0x26e2a58, mutex=mutex@entry=0x26e2a60, time=time@entry=18446744073709551615) at thread/qwaitcondition_unix.cpp:215
#3  0x000000000044077e in Akonadi::Server::SearchTaskManager::searchLoop (this=0x26e2a30) at /usr/src/debug/akonadi-16.12.2/src/server/search/searchtaskmanager.cpp:222
#4  0x00007f16d5d03e26 in QtPrivate::QSlotObjectBase::call (a=0x7f16bb7fd990, r=<optimized out>, this=<optimized out>) at ../../src/corelib/kernel/qobject_impl.h:101
#5  QSingleShotTimer::timerEvent (this=0x26b3a50) at kernel/qtimer.cpp:317
#6  0x00007f16d5cf8573 in QObject::event (this=0x26b3a50, e=<optimized out>) at kernel/qobject.cpp:1285
#7  0x00007f16d5ccbaeb in doNotify (event=0x7f16bb7fdab0, receiver=0x26b3a50) at kernel/qcoreapplication.cpp:1063
#8  QCoreApplication::notify (event=<optimized out>, receiver=<optimized out>, this=<optimized out>) at kernel/qcoreapplication.cpp:1049
#9  QCoreApplication::notifyInternal2 (receiver=0x26b3a50, event=event@entry=0x7f16bb7fdab0) at kernel/qcoreapplication.cpp:988
#10 0x00007f16d5d1f10e in QCoreApplication::sendEvent (event=0x7f16bb7fdab0, receiver=<optimized out>) at ../../src/corelib/kernel/qcoreapplication.h:231
#11 QTimerInfoList::activateTimers (this=0x7f16a4002cd0) at kernel/qtimerinfo_unix.cpp:644
#12 0x00007f16d5d1f631 in timerSourceDispatch (source=<optimized out>) at kernel/qeventdispatcher_glib.cpp:182
#13 0x00007f16d1e01697 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#14 0x00007f16d1e01900 in ?? () from /usr/lib64/libglib-2.0.so.0
#15 0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#16 0x00007f16d5d2016f in QEventDispatcherGlib::processEvents (this=0x7f16a40008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#17 0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16bb7fdd00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#18 0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#19 0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26e2b10) at thread/qthread_unix.cpp:368
#20 0x00007f16d401e454 in start_thread (arg=0x7f16bb7fe700) at pthread_create.c:333
#21 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 7 (Thread 0x7f16bbfff700 (LWP 25729)):
#0  0x00007f16d1e46f49 in g_mutex_lock () from /usr/lib64/libglib-2.0.so.0
#1  0x00007f16d1e00d89 in g_main_context_prepare () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e017bb in ?? () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#4  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16b00008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#5  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16bbffed00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#7  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26f6e60) at thread/qthread_unix.cpp:368
#8  0x00007f16d401e454 in start_thread (arg=0x7f16bbfff700) at pthread_create.c:333
#9  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 6 (Thread 0x7f16c8df5700 (LWP 25728)):
#0  QListData::end (this=<optimized out>) at ../../src/corelib/tools/qlist.h:117
#1  QList<QTimerInfo*>::constEnd (this=<optimized out>) at ../../src/corelib/tools/qlist.h:325
#2  QTimerInfoList::timerWait (this=0x7f16b40030d0, tm=...) at kernel/qtimerinfo_unix.cpp:393
#3  0x00007f16d5d1f75e in timerSourcePrepareHelper (timeout=0x7f16c8df4b34, src=<optimized out>) at kernel/qeventdispatcher_glib.cpp:132
#4  timerSourcePrepare (source=<optimized out>, timeout=0x7f16c8df4b34) at kernel/qeventdispatcher_glib.cpp:165
#5  0x00007f16d1e00d7d in g_main_context_prepare () from /usr/lib64/libglib-2.0.so.0
#6  0x00007f16d1e017bb in ?? () from /usr/lib64/libglib-2.0.so.0
#7  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#8  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16b40008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#9  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16c8df4d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#10 0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#11 0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26f6950) at thread/qthread_unix.cpp:368
#12 0x00007f16d401e454 in start_thread (arg=0x7f16c8df5700) at pthread_create.c:333
#13 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 5 (Thread 0x7f16c95f6700 (LWP 25727)):
#0  0x00007f16d5af3629 in std::__atomic_base<QMutexData*>::compare_exchange_strong (__m2=<optimized out>, __m1=std::memory_order_acquire, __p2=<optimized out>, __p1=@0x7f16c95f5ac8: 0x0, this=0x26f6660) at /usr/include/c++/6/bits/atomic_base.h:752
#1  std::atomic<QMutexData*>::compare_exchange_strong (__m=std::memory_order_acquire, __p2=<optimized out>, __p1=@0x7f16c95f5ac8: 0x0, this=0x26f6660) at /usr/include/c++/6/atomic:475
#2  QAtomicOps<QMutexData*>::testAndSetAcquire<QMutexData*> (currentValue=<synthetic pointer>, newValue=<optimized out>, expectedValue=0x0, _q_value=...) at ../../src/corelib/arch/qatomic_cxx11.h:290
#3  QBasicAtomicPointer<QMutexData>::testAndSetAcquire (currentValue=<synthetic pointer>, newValue=<optimized out>, expectedValue=0x0, this=0x26f6660) at ../../src/corelib/thread/qbasicatomic.h:259
#4  QBasicMutex::fastTryLock (current=<synthetic pointer>, this=0x26f6660) at thread/qmutex.h:89
#5  QMutex::lock (this=this@entry=0x26f6660) at thread/qmutex.cpp:225
#6  0x00007f16d5d1fa69 in QMutexLocker::QMutexLocker (m=0x26f6660, this=<synthetic pointer>) at ../../src/corelib/thread/qmutex.h:137
#7  QThreadData::canWaitLocked (this=0x26f6630) at ../../src/corelib/thread/qthread_p.h:253
#8  postEventSourcePrepare (timeout=<synthetic pointer>, s=0x7f16ac0012d0) at kernel/qeventdispatcher_glib.cpp:259
#9  postEventSourceCheck (source=0x7f16ac0012d0) at kernel/qeventdispatcher_glib.cpp:269
#10 0x00007f16d1e01299 in g_main_context_check () from /usr/lib64/libglib-2.0.so.0
#11 0x00007f16d1e01834 in ?? () from /usr/lib64/libglib-2.0.so.0
#12 0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#13 0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16ac0008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#14 0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16c95f5d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#15 0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#16 0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26f64f0) at thread/qthread_unix.cpp:368
#17 0x00007f16d401e454 in start_thread (arg=0x7f16c95f6700) at pthread_create.c:333
#18 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 4 (Thread 0x7f16c9df7700 (LWP 25726)):
#0  0x00007f16d51e966d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f16d1e01896 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16c00008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#4  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16c9df6d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#5  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#6  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26df500) at thread/qthread_unix.cpp:368
#7  0x00007f16d401e454 in start_thread (arg=0x7f16c9df7700) at pthread_create.c:333
#8  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 3 (Thread 0x7f16ca5f8700 (LWP 25724)):
#0  0x00007f16d1e46f49 in g_mutex_lock () from /usr/lib64/libglib-2.0.so.0
#1  0x00007f16d1e00d89 in g_main_context_prepare () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e017bb in ?? () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#4  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16bc0008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#5  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16ca5f7d00, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#7  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x26d4ae0) at thread/qthread_unix.cpp:368
#8  0x00007f16d401e454 in start_thread (arg=0x7f16ca5f8700) at pthread_create.c:333
#9  0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 2 (Thread 0x7f16cc67e700 (LWP 25722)):
#0  0x00007f16d51e56dd in read () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f16d1e45ba0 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007f16d1e0135e in g_main_context_check () from /usr/lib64/libglib-2.0.so.0
#3  0x00007f16d1e01834 in ?? () from /usr/lib64/libglib-2.0.so.0
#4  0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#5  0x00007f16d5d2018b in QEventDispatcherGlib::processEvents (this=0x7f16c40008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#6  0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7f16cc67dcd0, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#7  0x00007f16d5af7813 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:507
#8  0x00007f16d636f385 in ?? () from /usr/lib64/libQt5DBus.so.5
#9  0x00007f16d5afc4c8 in QThreadPrivate::start (arg=0x7f16d65e0d20) at thread/qthread_unix.cpp:368
#10 0x00007f16d401e454 in start_thread (arg=0x7f16cc67e700) at pthread_create.c:333
#11 0x00007f16d51f237f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:105

Thread 1 (Thread 0x7f16d74728c0 (LWP 25721)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f16d5afd2b6 in QWaitConditionPrivate::wait_relative (time=10000, this=0x271d6f0) at thread/qwaitcondition_unix.cpp:133
#2  QWaitConditionPrivate::wait (time=10000, this=0x271d6f0) at thread/qwaitcondition_unix.cpp:141
#3  QWaitCondition::wait (this=this@entry=0x271be80, mutex=mutex@entry=0x271be60, time=time@entry=10000) at thread/qwaitcondition_unix.cpp:215
#4  0x00007f16d5afc06e in QThread::wait (this=<optimized out>, time=time@entry=10000) at thread/qthread_unix.cpp:698
#5  0x00000000005280ef in Akonadi::Server::AkThread::quitThread (this=this@entry=0x271c170) at /usr/src/debug/akonadi-16.12.2/src/server/akthread.cpp:62
#6  0x000000000042da5c in Akonadi::Server::Connection::~Connection (this=0x271c170, __in_chrg=<optimized out>) at /usr/src/debug/akonadi-16.12.2/src/server/connection.cpp:149
#7  0x000000000042dba9 in Akonadi::Server::Connection::~Connection (this=0x271c170, __in_chrg=<optimized out>) at /usr/src/debug/akonadi-16.12.2/src/server/connection.cpp:154
#8  0x000000000042abfe in qDeleteAll<QTypedArrayData<Akonadi::Server::Connection*>::const_iterator> (end=..., begin=...) at /usr/include/qt5/QtCore/qalgorithms.h:323
#9  qDeleteAll<QVector<Akonadi::Server::Connection*> > (c=...) at /usr/include/qt5/QtCore/qalgorithms.h:331
#10 Akonadi::Server::AkonadiServer::quit (this=0x26b0c90) at /usr/src/debug/akonadi-16.12.2/src/server/akonadi.cpp:304
#11 0x000000000051952e in ServerAdaptor::quit (this=<optimized out>) at /usr/src/debug/akonadi-16.12.2/build/src/server/serveradaptor.cpp:39
#12 ServerAdaptor::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>) at /usr/src/debug/akonadi-16.12.2/build/src/server/serveradaptor.moc:86
#13 0x00000000005196a3 in ServerAdaptor::qt_metacall (this=0x2721730, _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0x7ffc82cb0480) at /usr/src/debug/akonadi-16.12.2/build/src/server/serveradaptor.moc:120
#14 0x00007f16d6378f40 in ?? () from /usr/lib64/libQt5DBus.so.5
#15 0x00007f16d637d2bd in ?? () from /usr/lib64/libQt5DBus.so.5
#16 0x00007f16d637db64 in ?? () from /usr/lib64/libQt5DBus.so.5
#17 0x00007f16d638036e in ?? () from /usr/lib64/libQt5DBus.so.5
#18 0x00007f16d5cf85b9 in QObject::event (this=0x26b0c90, e=<optimized out>) at kernel/qobject.cpp:1263
#19 0x00007f16d5ccbaeb in doNotify (event=0x7f16c4015750, receiver=0x26b0c90) at kernel/qcoreapplication.cpp:1063
#20 QCoreApplication::notify (event=<optimized out>, receiver=<optimized out>, this=<optimized out>) at kernel/qcoreapplication.cpp:1049
#21 QCoreApplication::notifyInternal2 (receiver=0x26b0c90, event=event@entry=0x7f16c4015750) at kernel/qcoreapplication.cpp:988
#22 0x00007f16d5cce28d in QCoreApplication::sendEvent (event=0x7f16c4015750, receiver=<optimized out>) at kernel/qcoreapplication.h:231
#23 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0, data=0x2688cd0) at kernel/qcoreapplication.cpp:1649
#24 0x00007f16d5cce6f8 in QCoreApplication::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0) at kernel/qcoreapplication.cpp:1503
#25 0x00007f16d5d1fd63 in postEventSourceDispatch (s=0x2694c40) at kernel/qeventdispatcher_glib.cpp:276
#26 0x00007f16d1e01697 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#27 0x00007f16d1e01900 in ?? () from /usr/lib64/libglib-2.0.so.0
#28 0x00007f16d1e019ac in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#29 0x00007f16d5d2016f in QEventDispatcherGlib::processEvents (this=0x268f270, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#30 0x00007f16d5cc9aea in QEventLoop::exec (this=this@entry=0x7ffc82cb0a60, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#31 0x00007f16d5cd225c in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1261
#32 0x00000000005849f5 in AkApplicationBase::exec (this=this@entry=0x7ffc82cb0bc0) at /usr/src/debug/akonadi-16.12.2/src/shared/akapplication.cpp:125
#33 0x0000000000426404 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/akonadi-16.12.2/src/server/main.cpp:81

Reported using DrKonqi
Comment 1 Daniel Vrátil 2017-02-23 18:18:38 UTC
ItemRetriever now uses QEventLoop to wait for request to be processed. If Akonadi Server is shut down during that, the QEventLoop will cause Connection::quit() to be executed, destroying the QSqlDriver and deleting the thread. When the QEventLoop finishes and ItemRetriever::exec() returns, the QSqlQuery() tries to dereference the already-destroyed QSqlDriver.

We need a mechanism to either prevent Connection::quit() from being executed while an event loop is running on the Connection, or we need a way to quickly abort ItemRetriever::exec() from Connection::quit() before destroying the SQL connection and the thread.
Comment 2 Christoph Feck 2017-06-26 12:35:50 UTC
Wasn't this connection shutdown already fixed?
Comment 3 Justin Zobel 2020-12-17 05:29:23 UTC
Thank you for the crash report.

As it has been a while since this was reported, can you please test and confirm if this issue is still occurring or if this bug report can be marked as resolved.

I have set the bug status to "needsinfo" pending your response, please change back to "reported" or "resolved/worksforme" when you respond, thank you.
Comment 4 Bruno Friedmann 2020-12-17 10:38:46 UTC
Work wtih
Linux 5.9.12-1-default x86_64 GNU/Linux, nvidia: 450.80.02
Qt: 5.15.2, KDE Frameworks: 5.76.0, Plasma: 5.20.4, kmail2 5.15.3 (20.08.3)