Bug 353559 - Gracefully exit baloo_file
Summary: Gracefully exit baloo_file
Status: RESOLVED FIXED
Alias: None
Product: frameworks-baloo
Classification: Frameworks and Libraries
Component: Baloo File Daemon (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Pinak Ahuja
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-05 09:24 UTC by Vishesh Handa
Modified: 2019-06-10 14:21 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.60
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vishesh Handa 2015-10-05 09:24:57 UTC
baloo_file does not exit gracefully. If it is indexing files, it does not stop indexing them and needs to be forcibly killed.

Eg -

#0  0xb778dbe8 in __kernel_vsyscall ()
#1  0xb6d1e4fb in poll () at ../sysdeps/unix/syscall-template.S:84
#2  0xb577e980 in g_poll () from /lib/i386-linux-gnu/libglib-2.0.so.0
#3  0xb576ff1c in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#4  0xb5770054 in g_main_context_iteration () from /lib/i386-linux-gnu/libglib-2.0.so.0
#5  0xb72757e3 in QEventDispatcherGlib::processEvents (this=0x72c00468, flags=...) at kernel/qeventdispatcher_glib.cpp:418
#6  0xb72182d3 in QEventLoop::processEvents (this=0x7359b198, flags=...) at kernel/qeventloop.cpp:128
#7  0xb7218722 in QEventLoop::exec (this=0x7359b198, flags=...) at kernel/qeventloop.cpp:204
#8  0x0806474e in Baloo::FileContentIndexer::run (this=0x8e651b8) at /home/lacsilva/Development/baloo/src/file/filecontentindexer.cpp:70
#9  0xb7042f31 in QThreadPoolThread::run (this=0x8f6ead0) at thread/qthreadpool.cpp:93
#10 0xb704665b in QThreadPrivate::start (arg=0x8f6ead0) at thread/qthread_unix.cpp:337
#11 0xb64772fc in start_thread (arg=0x7359bb40) at pthread_create.c:334
#12 0xb6d28bbe in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:122

Thread 2 (Thread 0x72bffb40 (LWP 16349)):
#0  0xb778dbe8 in __kernel_vsyscall ()
#1  0xb6d20ce1 in select () at ../sysdeps/unix/syscall-template.S:84
#2  0xb71adfa9 in QProcessManager::run (this=0x8e52cd8) at io/qprocess_unix.cpp:264
#3  0xb704665b in QThreadPrivate::start (arg=0x8e52cd8) at thread/qthread_unix.cpp:337
#4  0xb64772fc in start_thread (arg=0x72bffb40) at pthread_create.c:334
#5  0xb6d28bbe in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:122

Thread 1 (Thread 0xb391f780 (LWP 16335)):
#0  0xb778dbe8 in __kernel_vsyscall ()
#1  0xb647ca6c in pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/i386/i686/../i486/pthread_cond_wait.S:187
#2  0xb6d35cb6 in __pthread_cond_wait (cond=0x8ec8400, mutex=0x8ec83e8) at forward.c:149
#3  0xb7047833 in QWaitConditionPrivate::wait (time=4294967295, this=0x8ec83e8) at thread/qwaitcondition_unix.cpp:136
#4  QWaitCondition::wait (this=0x8ec83cc, mutex=0x8ec83b8, time=4294967295) at thread/qwaitcondition_unix.cpp:208
#5  0xb7041d01 in QThreadPoolPrivate::waitForDone (this=0x8ec8378, msecs=-1) at thread/qthreadpool.cpp:287
#6  0xb7041fa1 in QThreadPool::waitForDone (this=0xbfe3ef64, msecs=-1) at thread/qthreadpool.cpp:610
#7  0xb7041ff7 in QThreadPool::~QThreadPool (this=0xbfe3ef64, __in_chrg=<optimised out>) at thread/qthreadpool.cpp:416
#8  0x0805a346 in Baloo::FileIndexScheduler::~FileIndexScheduler (this=0xbfe3ef48, __in_chrg=<optimised out>) at /home/lacsilva/Development/baloo/src/file/fileindexscheduler.h:39
#9  Baloo::MainHub::~MainHub (this=0xbfe3ef1c, __in_chrg=<optimised out>) at /home/lacsilva/Development/baloo/src/file/mainhub.h:33
#10 main (argc=1, argv=0xbfe3f074) at /home/lacsilva/Development/baloo/src/file/main.cpp:87
Comment 1 Nate Graham 2019-06-10 14:21:31 UTC
Mostly fixed with https://cgit.kde.org/baloo.git/commit/?id=d74d1cbb65db03a03d5fdb91681ad906e8f098f8.

Now the baloo_file processes will kill themselves after they've completed their current tasks.