Bug 282290 - imap resource take a long time to exit and crash
Summary: imap resource take a long time to exit and crash
Status: RESOLVED FIXED
Alias: None
Product: Akonadi
Classification: Frameworks and Libraries
Component: IMAP resource (show other bugs)
Version: 4.8
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Christian Mollekopf
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-18 16:10 UTC by Luis Silva
Modified: 2015-10-11 12:06 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Output from kcrash (2.89 KB, text/plain)
2012-01-07 18:16 UTC, Luis Silva
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Luis Silva 2011-09-18 16:10:21 UTC
Version:           4.8 (using KDE 4.7.1) 
OS:                Linux

The akonadi_imap_resource takes a long time (a minute or more for my gmail account) to shutdown. Staring akonadi from a terminal and then stoping it shows that the imap_resources are crashig on exit. This seems to have no effects on my data bu delays kde on logout or shutdown.

Reproducible: Always

Steps to Reproduce:
Just open a terminal and do:
akonadictl stop

Keep monitoring the akonadi processes with your favorite tool and verify that the imap_resources take ages to dispear after all other resources are already <defunct>.


Expected Results:  
The imap_resource should take only a few seconds to shutdown as other resources do.
Comment 1 David Faure 2012-01-05 11:34:46 UTC
Can you post a backtrace of akonadi_imap_resource?
Comment 2 Luis Silva 2012-01-06 11:23:12 UTC
I can, if you tell me how to do that. I couldn't find a way to do it manually and I am not getting any crash dialog I can follow.
Comment 3 Luis Silva 2012-01-07 18:16:36 UTC
Created attachment 67550 [details]
Output from kcrash
Comment 4 Jekyll Wu 2012-05-30 12:18:35 UTC
paste the backtrace inline for better searching

Application: akonadi_imap_resource (4.8)
KDE Platform Version: 4.7.97 (4.8 RC2 (4.7.97) (Compiled from sources)
Qt Version: 4.7.4
Operating System: Linux 3.0.0-15-generic i686
Distribution: Ubuntu 11.10

-- Information about the crash:
<In detail, tell us what you were doing  when the application crashed.>

The crash can be reproduced every time.

-- Backtrace:
Application: GMail of type IMAP E-Mail Server (akonadi_imap_resource), signal: Segmentation fault
[KCrash Handler]
#7  0x002875a2 in QObject::metaObject (this=0x8481388) at .moc/release-shared/moc_qobject.cpp:90
#8  0x0028c850 in QObject::connect (sender=0x8481388, signal=0x54072a "2timeout()", receiver=0x8481330, method=0x541848 "1onSocketTimeout()", type=Qt::AutoConnection) at kernel/qobject.cpp:2489
#9  0x0051fff0 in startSocketTimer (this=0x8481330) at /home/lacsilva/Development/kdepim.d/kdepimlibs/kimap/session.cpp:459
#10 KIMAP::SessionPrivate::startSocketTimer (this=0x8481330) at /home/lacsilva/Development/kdepim.d/kdepimlibs/kimap/session.cpp:451
#11 0x00520121 in KIMAP::SessionPrivate::restartSocketTimer (this=0x8481330) at /home/lacsilva/Development/kdepim.d/kdepimlibs/kimap/session.cpp:482
#12 0x0052017a in KIMAP::SessionPrivate::sendData (this=0x8481330, data=...) at /home/lacsilva/Development/kdepim.d/kdepimlibs/kimap/session.cpp:316
#13 0x0051179e in KIMAP::IdleJob::stop (this=0x83c10e8) at /home/lacsilva/Development/kdepim.d/kdepimlibs/kimap/idlejob.cpp:87
#14 0x08059fbd in ImapIdleManager::~ImapIdleManager (this=0x85e7718, __in_chrg=<optimized out>) at /home/lacsilva/Development/kdepim.d/kdepim-runtime/resources/imap/imapidlemanager.cpp:53
#15 0x0805a030 in ImapIdleManager::~ImapIdleManager (this=0x85e7718, __in_chrg=<optimized out>) at /home/lacsilva/Development/kdepim.d/kdepim-runtime/resources/imap/imapidlemanager.cpp:58
#16 0x0028a841 in QObjectPrivate::deleteChildren (this=0x84751f8) at kernel/qobject.cpp:1955
#17 0x0028f439 in QObject::~QObject (this=0x8425570, __in_chrg=<optimized out>) at kernel/qobject.cpp:946
#18 0x006a08b7 in Akonadi::AgentBase::~AgentBase (this=0x8425570, __in_chrg=<optimized out>) at /home/lacsilva/Development/kdepim.d/kdepimlibs/akonadi/agentbase.cpp:521
#19 0x00785c06 in Akonadi::ResourceBase::~ResourceBase (this=0x8425570, __in_chrg=<optimized out>) at /home/lacsilva/Development/kdepim.d/kdepimlibs/akonadi/resourcebase.cpp:348
#20 0x0805c450 in ImapResource::~ImapResource (this=0x8425570, __in_chrg=<optimized out>) at /home/lacsilva/Development/kdepim.d/kdepim-runtime/resources/imap/imapresource.cpp:156
#21 0x00786a6f in Akonadi::ResourceBase::init (r=0x8425570) at /home/lacsilva/Development/kdepim.d/kdepimlibs/akonadi/resourcebase.cpp:406
#22 0x0805f787 in Akonadi::ResourceBase::init<ImapResource> (argc=3, argv=0xbfd04db4) at /usr/include/akonadi/resourcebase.h:188
#23 0x08059c7b in main (argc=3, argv=0xbfd04db4) at /home/lacsilva/Development/kdepim.d/kdepim-runtime/resources/imap/imapresource.cpp:600
Comment 5 Luis Silva 2012-12-26 18:09:14 UTC
This problem is still present in master. I cannot find a way to produce a crash report or even a backtrace from this crash but I alwasy get the following message when akonadi closes:

QProcess: Destroyed while process is still running.
ProcessControl: Application /usr/bin/akonadi_imap_resource stopped unexpectedly ( "Process crashed" )
Application '/usr/bin/akonadi_imap_resource' crashed. No restart!
Comment 6 Kevin Ottens 2013-11-16 07:32:32 UTC
The IMAP resource has a new maintainer, reassigning to him.
Comment 7 Christian Mollekopf 2013-11-19 16:20:02 UTC
Does this still apply to 4.11.3>=?
If it does we need a fresh backtrace.
Comment 8 Christian Mollekopf 2013-11-19 16:20:10 UTC
Does this still apply to 4.11.3>=?
If it does we need a fresh backtrace.
Comment 9 Luis Silva 2015-10-11 12:06:57 UTC
This does not happen any more.