Bug 399849 - Baloo crashed after I delete a folder containing some files and subfolders
Summary: Baloo crashed after I delete a folder containing some files and subfolders
Status: RESOLVED WORKSFORME
Alias: None
Product: frameworks-baloo
Classification: Frameworks and Libraries
Component: Baloo File Daemon (show other bugs)
Version: 5.50.0
Platform: Arch Linux Linux
: NOR crash
Target Milestone: ---
Assignee: baloo-bugs-null
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2018-10-15 18:06 UTC by Patrick Silva
Modified: 2018-12-04 03:44 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
26 backtraces (9.00 KB, application/gzip)
2018-10-18 15:32 UTC, Patrick Silva
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Silva 2018-10-15 18:06:35 UTC
Application: baloo_file (5.50.0)

Qt Version: 5.11.2
Frameworks Version: 5.51.0
Operating System: Linux 4.18.12-arch1-1-ARCH x86_64
Distribution (Platform): Archlinux Packages

-- Information about the crash:
- What I was doing when the application crashed:
I selected a folder containing several files and subfolders and pressed shift+del to delete it.
Plasma shown a crash notification when I clicked the button to confirm the deletion.

The crash can be reproduced sometimes.

-- Backtrace:
Application: Baloo File Indexing Daemon (baloo_file), signal: Segmentation fault
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[Current thread is 1 (Thread 0x7f39bb578800 (LWP 10740))]

Thread 2 (Thread 0x7f39bb291700 (LWP 10753)):
#0  0x00007f39c044dbb1 in poll () from /usr/lib/libc.so.6
#1  0x00007f39be74dee0 in g_main_context_poll (priority=<optimized out>, n_fds=1, fds=0x7f39b4003ce0, timeout=<optimized out>, context=0x7f39b4000bf0) at ../glib/glib/gmain.c:4221
#2  g_main_context_iterate (context=context@entry=0x7f39b4000bf0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3915
#3  0x00007f39be74dfce in g_main_context_iteration (context=0x7f39b4000bf0, may_block=1) at ../glib/glib/gmain.c:3981
#4  0x00007f39c0af9fe4 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#5  0x00007f39c0aa58cc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#6  0x00007f39c08eeeb9 in QThread::exec() () from /usr/lib/libQt5Core.so.5
#7  0x00007f39c0f10ba6 in ?? () from /usr/lib/libQt5DBus.so.5
#8  0x00007f39c08f8f65 in ?? () from /usr/lib/libQt5Core.so.5
#9  0x00007f39bfc80a9d in start_thread () from /usr/lib/libpthread.so.0
#10 0x00007f39c0458a43 in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7f39bb578800 (LWP 10740)):
[KCrash Handler]
#6  0x00007f39c049ba03 in __memcpy_ssse3 () from /usr/lib/libc.so.6
#7  0x00007f39c0e5abff in Baloo::PostingCodec::decode (this=this@entry=0x7ffe23ce2027, arr=...) at /usr/include/qt/QtCore/qarraydata.h:209
#8  0x00007f39c0e48074 in Baloo::PostingDB::get (this=this@entry=0x7ffe23ce2110, term=...) at /usr/src/debug/baloo-5.50.0/src/engine/postingdb.cpp:100
#9  0x00007f39c0e58521 in Baloo::WriteTransaction::commit (this=0x56067af27b20) at /usr/src/debug/baloo-5.50.0/src/engine/writetransaction.cpp:259
#10 0x00007f39c0e4ea33 in Baloo::Transaction::commit (this=this@entry=0x7ffe23ce21c0) at /usr/src/debug/baloo-5.50.0/src/engine/transaction.cpp:269
#11 0x0000560679041b6a in Baloo::MetadataMover::removeFileMetadata (this=0x56067ad03090, file=...) at /usr/src/debug/baloo-5.50.0/src/file/metadatamover.cpp:106
#12 0x00007f39c0ad0bd0 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#13 0x0000560679050106 in Baloo::PendingFileQueue::removeFileIndex (this=this@entry=0x56067acedf10, _t1=...) at /usr/src/debug/build/src/file/baloofilecommon_autogen/EWIEGA46WW/moc_pendingfilequeue.cpp:222
#14 0x000056067903f818 in Baloo::PendingFileQueue::processCache (this=0x56067acedf10) at /usr/src/debug/baloo-5.50.0/src/file/pendingfilequeue.cpp:92
#15 0x00007f39c0ad0bd0 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#16 0x00007f39c0adcbe8 in QTimer::timeout(QTimer::QPrivateSignal) () from /usr/lib/libQt5Core.so.5
#17 0x00007f39c0ad130b in QObject::event(QEvent*) () from /usr/lib/libQt5Core.so.5
#18 0x00007f39c0aa6c17 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#19 0x00007f39c0af939a in QTimerInfoList::activateTimers() () from /usr/lib/libQt5Core.so.5
#20 0x00007f39c0af9c22 in ?? () from /usr/lib/libQt5Core.so.5
#21 0x00007f39be74c3cf in g_main_dispatch (context=0x56067acea060) at ../glib/glib/gmain.c:3182
#22 g_main_context_dispatch (context=context@entry=0x56067acea060) at ../glib/glib/gmain.c:3847
#23 0x00007f39be74df89 in g_main_context_iterate (context=context@entry=0x56067acea060, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3920
#24 0x00007f39be74dfce in g_main_context_iteration (context=0x56067acea060, may_block=1) at ../glib/glib/gmain.c:3981
#25 0x00007f39c0af9fc9 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#26 0x00007f39c0aa58cc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#27 0x00007f39c0aadbc6 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5
#28 0x00005606790273f4 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/baloo-5.50.0/src/file/main.cpp:104
[Inferior 1 (process 10740) detached]

Possible duplicates by query: bug 399692, bug 399481, bug 396973, bug 396323, bug 396218.

Reported using DrKonqi
Comment 1 Patrick Silva 2018-10-16 16:38:24 UTC
backtrace of baloo 5.51

Application: Baloo File Indexing Daemon (baloo_file), signal: Segmentation fault
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[Current thread is 1 (Thread 0x7f40ab547800 (LWP 999))]

Thread 3 (Thread 0x7f40aa74d700 (LWP 1014)):
#0  0x00007f40b04187a4 in read () from /usr/lib/libc.so.6
#1  0x00007f40ae6cb781 in read (__nbytes=<optimized out>, __buf=<optimized out>, __fd=<optimized out>, __fd=<optimized out>, __buf=<optimized out>, __nbytes=<optimized out>) at /usr/include/bits/unistd.h:44
#2  g_wakeup_acknowledge (wakeup=0x7f40a4003db0) at ../glib/glib/gwakeup.c:210
#3  0x00007f40ae71ba50 in g_main_context_check (context=context@entry=0x7f009c000bf0, max_priority=2147483647, fds=fds@entry=0x7f009c0078f0, n_fds=n_fds@entry=1) at ../glib/glib/gmain.c:3698
#4  0x00007f40ae71ce86 in g_main_context_iterate (context=context@entry=0x7f009c000bf0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3917
#5  0x00007f40ae71cfce in g_main_context_iteration (context=0x7f009c000bf0, may_block=1) at ../glib/glib/gmain.c:3981
#6  0x00007f40b0ac8fe4 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#7  0x00007f40b0a748cc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#8  0x00005623167c4026 in Baloo::FileContentIndexer::run (this=0x5623179dc060) at /usr/include/qt/QtCore/qflags.h:120
#9  0x00007f40b08bfe11 in ?? () from /usr/lib/libQt5Core.so.5
#10 0x00007f40b08c7f65 in ?? () from /usr/lib/libQt5Core.so.5
#11 0x00007f40afc4fa9d in start_thread () from /usr/lib/libpthread.so.0
#12 0x00007f40b0427b23 in clone () from /usr/lib/libc.so.6

Thread 2 (Thread 0x7f40ab260700 (LWP 1009)):
#0  0x00007f40b041cc21 in poll () from /usr/lib/libc.so.6
#1  0x00007f40ae71cee0 in g_main_context_poll (priority=<optimized out>, n_fds=1, fds=0x7f40a4003ce0, timeout=<optimized out>, context=0x7f40a4000bf0) at ../glib/glib/gmain.c:4221
#2  g_main_context_iterate (context=context@entry=0x7f40a4000bf0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3915
#3  0x00007f40ae71cfce in g_main_context_iteration (context=0x7f40a4000bf0, may_block=1) at ../glib/glib/gmain.c:3981
#4  0x00007f40b0ac8fe4 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#5  0x00007f40b0a748cc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#6  0x00007f40b08bdeb9 in QThread::exec() () from /usr/lib/libQt5Core.so.5
#7  0x00007f40b0edfba6 in ?? () from /usr/lib/libQt5DBus.so.5
#8  0x00007f40b08c7f65 in ?? () from /usr/lib/libQt5Core.so.5
#9  0x00007f40afc4fa9d in start_thread () from /usr/lib/libpthread.so.0
#10 0x00007f40b0427b23 in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7f40ab547800 (LWP 999)):
[KCrash Handler]
#6  0x00007f40b0e18168 in QVector<QByteArray>::reallocData (this=this@entry=0x7ffd25490608, asize=201326589, aalloc=201326590, options=...) at /usr/include/qt/QtCore/qarraydata.h:218
#7  0x00007f40b0e184be in QVector<QByteArray>::append (this=this@entry=0x7ffd25490608, t=...) at /usr/include/qt/QtCore/qflags.h:120
#8  0x00007f40b0e29646 in QVector<QByteArray>::operator<< (t=..., this=0x7ffd25490608) at /usr/include/qt/QtCore/qvector.h:282
#9  Baloo::DocTermsCodec::decode (this=this@entry=0x7ffd254905ff, full=...) at /usr/src/debug/baloo-5.51.0/src/codecs/doctermscodec.cpp:76
#10 0x00007f40b0e00c96 in Baloo::DocumentDB::get (this=this@entry=0x7ffd25490750, docId=<optimized out>, docId@entry=11832110914471939) at /usr/src/debug/baloo-5.51.0/src/engine/documentdb.cpp:99
#11 0x00007f40b0e26971 in Baloo::WriteTransaction::replaceDocument (this=0x562317aa3ed0, doc=..., operations=...) at /usr/src/debug/baloo-5.51.0/src/engine/writetransaction.cpp:200
#12 0x00007f40b0e1da1a in Baloo::Transaction::replaceDocument (this=this@entry=0x7ffd25490a50, doc=..., operations=..., operations@entry=...) at /usr/src/debug/baloo-5.51.0/src/engine/transaction.cpp:261
#13 0x00005623167cd095 in Baloo::MetadataMover::updateMetadata (this=this@entry=0x5623179e0260, tr=tr@entry=0x7ffd25490a50, from=..., to=...) at /usr/include/qt/QtCore/qrefcount.h:60
#14 0x00005623167cf8ca in Baloo::MetadataMover::moveFileMetadata (this=0x5623179e0260, from=..., to=...) at /usr/src/debug/baloo-5.51.0/src/file/metadatamover.cpp:90
#15 0x00005623167c9294 in Baloo::FileWatch::slotFileMoved (this=0x7ffd25491290, urlFrom=..., urlTo=...) at /usr/src/debug/baloo-5.51.0/src/file/filewatch.cpp:110
#16 0x00007f40b0a9fbd0 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#17 0x00005623167d5c15 in KInotify::moved (_t2=..., _t1=..., this=0x5623179db1d0) at /usr/src/debug/build/src/file/baloofilecommon_autogen/include/moc_kinotify.cpp:343
#18 KInotify::slotEvent (this=0x5623179db1d0, socket=<optimized out>) at /usr/src/debug/baloo-5.51.0/src/file/kinotify.cpp:421
#19 0x00007f40b0a9fbd0 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#20 0x00007f40b0aab6ba in QSocketNotifier::activated(int, QSocketNotifier::QPrivateSignal) () from /usr/lib/libQt5Core.so.5
#21 0x00007f40b0aaba12 in QSocketNotifier::event(QEvent*) () from /usr/lib/libQt5Core.so.5
#22 0x00007f40b0a75c17 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#23 0x00007f40b0ac9c2b in ?? () from /usr/lib/libQt5Core.so.5
#24 0x00007f40ae71b3cf in g_main_dispatch (context=0x5623179cb060) at ../glib/glib/gmain.c:3182
#25 g_main_context_dispatch (context=context@entry=0x5623179cb060) at ../glib/glib/gmain.c:3847
#26 0x00007f40ae71cf89 in g_main_context_iterate (context=context@entry=0x5623179cb060, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3920
#27 0x00007f40ae71cfce in g_main_context_iteration (context=0x5623179cb060, may_block=1) at ../glib/glib/gmain.c:3981
#28 0x00007f40b0ac8fc9 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#29 0x00007f40b0a748cc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#30 0x00007f40b0a7cbc6 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5
#31 0x00005623167b23f4 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/baloo-5.51.0/src/file/main.cpp:104
[Inferior 1 (process 999) detached]
Comment 2 Nate Graham 2018-10-17 14:37:43 UTC
Oh great, a new crash in Baloo::PostingCodec::decode(). :/
Comment 3 Nate Graham 2018-10-17 14:38:22 UTC
Oh whoops never mind, this is the one that's already been fixed!

*** This bug has been marked as a duplicate of bug 367480 ***
Comment 4 Stefan Brüns 2018-10-17 18:18:01 UTC
Hm, not really, 

the first backtrace is from PostingCodec::decode. Unfortunately the backtrace is to incomplete to tell whats going wrong here. It is a bit fishy how this can go wrong, as it just allocates a vector the same size as the raw data from the DB and copies it. Source:

https://cgit.kde.org/baloo.git/tree/src/codecs/postingcodec.cpp?id=2d31a8500edb755dbf253656f41a34c55223438e

The only think I can think of is mdb_get returning something other than MDB_SUCCESS or MDB_NOTFOUND, val.mv_size is uninitialized and we try copy a random amount of data afterwards:

https://cgit.kde.org/baloo.git/tree/src/engine/postingdb.cpp?id=2d31a8500edb755dbf253656f41a34c55223438e#n82

---

The second backtrace has a crash in the doctermscodec:

https://cgit.kde.org/baloo.git/tree/src/codecs/doctermscodec.cpp?id=2d31a8500edb755dbf253656f41a34c55223438e#n76

The crash happens when the docterm array is reallocated to grow. 200 MByte (of d-ptrs) are about 25 million terms. Although thats not impossible, it is also somewhat unlikely.

It may have the same reason as above, unchecked lmdb return code, attempting to decode random data.
Comment 5 Nate Graham 2018-10-18 03:20:40 UTC
Hmm, I thought we fixed the PostingCodec::decode() issue with Bug 367480 in Frameworks 5.51; this is from 5.50, before that fix went in.
Comment 6 Stefan Brüns 2018-10-18 03:35:37 UTC
No, only the *PositionCodec* - unfortunately, 367480 has instances of both.
Comment 7 Stefan Brüns 2018-10-18 03:37:59 UTC
(In reply to Stefan Brüns from comment #6)
> No, only the *PositionCodec* - unfortunately, 367480 has instances of both.

This one here has PostingCodec in KF5.50 and DocTermsCodec in KF5.51
Comment 8 Nate Graham 2018-10-18 03:46:52 UTC
Ahh, thanks for the clarification. It's probably at least partly my fault that 367480 has PostingCodec::decode() in it. I'll be more careful.
Comment 9 Stefan Brüns 2018-10-18 10:54:18 UTC
No worries, occasionally I'm that way, too ...

I fear a lot of the "duplicates" also have backtraces for more than one of the codecs, so it would be impossible to do a clean sort.
Comment 10 Stefan Brüns 2018-10-18 11:02:09 UTC
@ Patrick - can you still reproduce one of the crashes?

What happens when you do
$> balooshow -d 2051 -i 2754878
$> balooshow -d 2051 -i 2754878 -x
Comment 11 Patrick Silva 2018-10-18 12:17:53 UTC
(In reply to Stefan Brüns from comment #10)
> @ Patrick - can you still reproduce one of the crashes?
> 
> What happens when you do
> $> balooshow -d 2051 -i 2754878
> $> balooshow -d 2051 -i 2754878 -x

Crash never was reproducible while I delete a folder containing files/subfolders. It just occured once.

In fact I got several raondom crashed since I installed baloo 5.51.
Here is output of "coredumpctl list|grep baloo"

Tue 2018-10-16 13:05:17 -03    3196  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 13:05:35 -03     581  1000  1000  11 present   /usr/bin/baloo_file
Tue 2018-10-16 13:06:57 -03    1012  1000  1000  11 present   /usr/bin/baloo_file
Tue 2018-10-16 13:24:35 -03     732  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 13:26:15 -03    1015  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 13:32:13 -03     584  1000  1000  11 truncated /usr/bin/baloo_file
Tue 2018-10-16 13:39:11 -03     999  1000  1000  11 truncated /usr/bin/baloo_file
Tue 2018-10-16 14:09:53 -03    6681  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 14:32:39 -03    6555  1000  1000  11 present   /usr/bin/baloo_file
Tue 2018-10-16 14:35:56 -03   12802  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 14:47:51 -03   12786  1000  1000  11 present   /usr/bin/baloo_file
Tue 2018-10-16 19:25:12 -03     729  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 19:43:17 -03     740  1000  1000  11 present   /usr/bin/baloo_file_extractor
Tue 2018-10-16 19:45:04 -03     937  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 06:48:21 -03    1050  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 08:09:20 -03    8711  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 08:25:36 -03    8705  1000  1000  11 present   /usr/bin/baloo_file
Wed 2018-10-17 08:25:44 -03   11285  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 08:25:55 -03   11280  1000  1000  11 present   /usr/bin/baloo_file
Wed 2018-10-17 08:26:15 -03   11370  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 11:01:58 -03    1080  1000  1000  11 present   /usr/lib/baloorunner
Wed 2018-10-17 12:43:12 -03     755  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 12:46:56 -03     759  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 12:48:22 -03    1168  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 16:17:59 -03     747  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 17:42:49 -03     763  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 18:02:30 -03    1313  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 18:18:59 -03    3410  1000  1000  11 present   /usr/bin/baloo_file_extractor
Wed 2018-10-17 18:54:51 -03    1296  1000  1000  11 present   /usr/bin/baloo_file
Wed 2018-10-17 18:55:34 -03    3376  1000  1000  11 present   /usr/bin/baloo_file
Wed 2018-10-17 18:56:08 -03     541  1000  1000  11 present   /usr/bin/baloo_file
Thu 2018-10-18 09:01:14 -03    1611  1000  1000  11 present   /usr/bin/baloo_file_extractor

Not even plasma shown a crash notification after these crashes.

output of your commands:
11832110914471939 2051 2754878 /home/stalker/zip

and

11832110914471939 2051 2754878 /home/stalker/zip
Internal Info
Terms: Mapplication Moctet Mstream 
File Name Terms: Fzip zip 
XAttr Terms:
Comment 12 Patrick Silva 2018-10-18 12:23:03 UTC
Typo:
"In fact I got several raondom crashed..." = In fact I got several random crashes..."
Comment 13 Patrick Silva 2018-10-18 15:32:15 UTC
Created attachment 115726 [details]
26 backtraces

This attachment contains 26 backtraces.
Maybe some of them can help you to find the problem.
Comment 14 Patrick Silva 2018-10-28 12:40:47 UTC
another crash after I delete a file on desktop by pressing shift+del.

Application: Baloo File Indexing Daemon (baloo_file), signal: Segmentation fault
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[Current thread is 1 (Thread 0x7fba143a6800 (LWP 5150))]

Thread 3 (Thread 0x7fba135ac700 (LWP 5164)):
#0  0x00007fba192be7a4 in read () from /usr/lib/libc.so.6
#1  0x00007fba1753f781 in read (__nbytes=<optimized out>, __buf=<optimized out>, __fd=<optimized out>, __fd=<optimized out>, __buf=<optimized out>, __nbytes=<optimized out>) at /usr/include/bits/unistd.h:44
#2  g_wakeup_acknowledge (wakeup=0x7fba0c003db0) at ../glib/glib/gwakeup.c:210
#3  0x00007fba1758fa50 in g_main_context_check (context=context@entry=0x7f7a04000bf0, max_priority=2147483647, fds=fds@entry=0x7f7a040078f0, n_fds=n_fds@entry=1) at ../glib/glib/gmain.c:3698
#4  0x00007fba17590e86 in g_main_context_iterate (context=context@entry=0x7f7a04000bf0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3917
#5  0x00007fba17590fce in g_main_context_iteration (context=0x7f7a04000bf0, may_block=1) at ../glib/glib/gmain.c:3981
#6  0x00007fba1997a604 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#7  0x00007fba199235fc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#8  0x000055b4a4941026 in Baloo::FileContentIndexer::run (this=0x55b4a4c39200) at /usr/include/qt/QtCore/qflags.h:120
#9  0x00007fba1976c9a1 in ?? () from /usr/lib/libQt5Core.so.5
#10 0x00007fba197689cc in ?? () from /usr/lib/libQt5Core.so.5
#11 0x00007fba18aeca9d in start_thread () from /usr/lib/libpthread.so.0
#12 0x00007fba192cdb23 in clone () from /usr/lib/libc.so.6

Thread 2 (Thread 0x7fba140bf700 (LWP 5155)):
#0  0x00007fba192c2c21 in poll () from /usr/lib/libc.so.6
#1  0x00007fba17590ee0 in g_main_context_poll (priority=<optimized out>, n_fds=1, fds=0x7fba0c003ce0, timeout=<optimized out>, context=0x7fba0c000bf0) at ../glib/glib/gmain.c:4221
#2  g_main_context_iterate (context=context@entry=0x7fba0c000bf0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3915
#3  0x00007fba17590fce in g_main_context_iteration (context=0x7fba0c000bf0, may_block=1) at ../glib/glib/gmain.c:3981
#4  0x00007fba1997a604 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#5  0x00007fba199235fc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#6  0x00007fba197675c9 in QThread::exec() () from /usr/lib/libQt5Core.so.5
#7  0x00007fba19db1ba6 in ?? () from /usr/lib/libQt5DBus.so.5
#8  0x00007fba197689cc in ?? () from /usr/lib/libQt5Core.so.5
#9  0x00007fba18aeca9d in start_thread () from /usr/lib/libpthread.so.0
#10 0x00007fba192cdb23 in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7fba143a6800 (LWP 5150)):
[KCrash Handler]
#6  0x00007fba19310ae3 in __memcpy_ssse3 () from /usr/lib/libc.so.6
#7  0x00007fba19cfbccf in Baloo::PostingCodec::decode (this=this@entry=0x7ffd1073ab47, arr=...) at /usr/include/qt/QtCore/qarraydata.h:209
#8  0x00007fba19ce9074 in Baloo::PostingDB::get (this=this@entry=0x7ffd1073ac30, term=...) at /usr/src/debug/baloo-5.51.0/src/engine/postingdb.cpp:100
#9  0x00007fba19cf9581 in Baloo::WriteTransaction::commit (this=0x55b4a4cd3fb0) at /usr/src/debug/baloo-5.51.0/src/engine/writetransaction.cpp:259
#10 0x00007fba19cefa33 in Baloo::Transaction::commit (this=this@entry=0x7ffd1073ace0) at /usr/src/debug/baloo-5.51.0/src/engine/transaction.cpp:269
#11 0x000055b4a4949aea in Baloo::MetadataMover::removeFileMetadata (this=0x55b4a4c408d0, file=...) at /usr/src/debug/baloo-5.51.0/src/file/metadatamover.cpp:106
#12 0x00007fba1994f430 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#13 0x000055b4a4958086 in Baloo::PendingFileQueue::removeFileIndex (this=this@entry=0x55b4a4c2b0b0, _t1=...) at /usr/src/debug/build/src/file/baloofilecommon_autogen/EWIEGA46WW/moc_pendingfilequeue.cpp:222
#14 0x000055b4a49477f0 in Baloo::PendingFileQueue::processCache (this=0x55b4a4c2b0b0) at /usr/src/debug/baloo-5.51.0/src/file/pendingfilequeue.cpp:92
#15 0x00007fba1994f430 in QMetaObject::activate(QObject*, int, int, void**) () from /usr/lib/libQt5Core.so.5
#16 0x00007fba1995b468 in QTimer::timeout(QTimer::QPrivateSignal) () from /usr/lib/libQt5Core.so.5
#17 0x00007fba1994fb6b in QObject::event(QEvent*) () from /usr/lib/libQt5Core.so.5
#18 0x00007fba19924947 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#19 0x00007fba19979995 in QTimerInfoList::activateTimers() () from /usr/lib/libQt5Core.so.5
#20 0x00007fba1997a25a in ?? () from /usr/lib/libQt5Core.so.5
#21 0x00007fba1758f3cf in g_main_dispatch (context=0x55b4a4c28090) at ../glib/glib/gmain.c:3182
#22 g_main_context_dispatch (context=context@entry=0x55b4a4c28090) at ../glib/glib/gmain.c:3847
#23 0x00007fba17590f89 in g_main_context_iterate (context=context@entry=0x55b4a4c28090, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:3920
#24 0x00007fba17590fce in g_main_context_iteration (context=0x55b4a4c28090, may_block=1) at ../glib/glib/gmain.c:3981
#25 0x00007fba1997a5e9 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#26 0x00007fba199235fc in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#27 0x00007fba1992b906 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5
#28 0x000055b4a492f3f4 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/baloo-5.51.0/src/file/main.cpp:104
[Inferior 1 (process 5150) detached]
Comment 15 Stefan Brüns 2018-11-01 19:55:10 UTC
(In reply to Patrick Silva from comment #13)
> Created attachment 115726 [details]
> 26 backtraces
> 
> This attachment contains 26 backtraces.
> Maybe some of them can help you to find the problem.

The backtraces do not contain sufficient data, most importantly the document id. Without it, it is not possible to tell which database entry is responsible for the crash(es).

The only other approach is to run something like 'find <dir> -type f -ls -exec balooshow -x \{\} \;' and see where it crashes.
Comment 16 Patrick Silva 2018-11-02 11:31:13 UTC
I ran 'find /home/myusername -type f -ls -exec balooshow -x \{\} \;' on my system. No crash occured.
Comment 17 Bug Janitor Service 2018-11-19 12:00:26 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 18 Bug Janitor Service 2018-12-04 03:44:56 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!