Bug 333772 - Baloo crash on start - FileIndexingQueue::fillQueue
Summary: Baloo crash on start - FileIndexingQueue::fillQueue
Status: RESOLVED FIXED
Alias: None
Product: Baloo
Classification: Frameworks and Libraries
Component: Baloo File Daemon (show other bugs)
Version: unspecified
Platform: Kubuntu Linux
: NOR crash
Target Milestone: ---
Assignee: Vishesh Handa
URL:
Keywords: drkonqi
: 333822 333908 334005 334229 334720 334831 339473 340197 340893 341167 342211 342304 344016 344086 344360 344496 345120 345444 345466 348770 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-04-23 13:30 UTC by Enzo
Modified: 2016-03-28 08:57 UTC (History)
38 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.4


Attachments
New crash information added by DrKonqi (1.82 KB, text/plain)
2014-05-20 02:44 UTC, Wout Mertens
Details
New crash information added by DrKonqi (4.89 KB, text/plain)
2014-05-27 08:02 UTC, Martin Steigerwald
Details
New crash information added by DrKonqi (1.95 KB, text/plain)
2014-06-07 09:57 UTC, Olivier van der Toorn
Details
New crash information added by DrKonqi (2.13 KB, text/plain)
2014-06-21 04:58 UTC, Katsumi.Haruno
Details
New crash information added by DrKonqi (2.23 KB, text/plain)
2014-10-16 15:50 UTC, Eugene
Details
New crash information added by DrKonqi (1.90 KB, text/plain)
2014-11-09 06:33 UTC, Inge Svensson
Details
New crash information added by DrKonqi (1.19 KB, text/plain)
2014-11-11 07:59 UTC, Tuomas Nurmi
Details
command line output (964 bytes, text/plain)
2014-11-11 08:01 UTC, Tuomas Nurmi
Details
New crash information added by DrKonqi (2.10 KB, text/plain)
2014-12-23 03:18 UTC, elgeneidy
Details
Kcrash info for KDE 4.14.2 (1.96 KB, text/plain)
2015-03-13 22:10 UTC, Stephan Diestelhorst
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Enzo 2014-04-23 13:30:19 UTC
Application: baloo_file (0.1)
KDE Platform Version: 4.13.0
Qt Version: 4.8.6
Operating System: Linux 3.13.0-24-generic x86_64
Distribution: Ubuntu 14.04 LTS

-- Information about the crash:
- What I was doing when the application crashed: I waited for the start of kde. 
I tried to reinstall the package baloo via "apt-get --reinstall install baloo" but the error remains at every boot.

The crash can be reproduced every time.

-- Backtrace:
Application: File di Baloo (baloo_file), signal: Segmentation fault
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[KCrash Handler]
#5  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x1b608b0, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#6  0x00007f8499b87c7c in Xapian::Database::Database (this=0x1b608a8, other=...) at ../api/omdatabase.cc:82
#7  0x00007f8499b91dfa in Xapian::Enquire::Internal::Internal (this=0x1b608a0, db_=..., errorhandler_=0x0) at ../api/omenquire.cc:621
#8  0x00007f8499b91fae in Xapian::Enquire::Enquire (this=0x7fff3eba1a60, databases=..., errorhandler=0x0) at ../api/omenquire.cc:874
#9  0x00000000004173e3 in Baloo::FileIndexingQueue::fillQueue (this=0x1b59040) at ../../../src/file/fileindexingqueue.cpp:50
#10 0x0000000000415c01 in Baloo::IndexingQueue::resume (this=0x1b59040) at ../../../src/file/indexingqueue.cpp:55
#11 0x0000000000415751 in Baloo::IndexScheduler::IndexScheduler (this=0x1b61400, db=<optimized out>, config=0x7fff3eba1d50, parent=<optimized out>) at ../../../src/file/indexscheduler.cpp:82
#12 0x000000000040f978 in Baloo::FileIndexer::FileIndexer (this=0x7fff3eba1ca0, db=0x7fff3eba1cd0, config=0x7fff3eba1d50, parent=<optimized out>) at ../../../src/file/fileindexer.cpp:41
#13 0x00000000004090fa in main (argc=<optimized out>, argv=<optimized out>) at ../../../src/file/main.cpp:86

Reported using DrKonqi
Comment 1 Vishesh Handa 2014-04-25 15:25:19 UTC
Can you reproduce this crash if you run the baloo_file process from the terminal?

If you can, could you please run it under valgrind?

$ valgrind baloo_file
Comment 2 Vishesh Handa 2014-04-25 15:26:16 UTC
*** Bug 333822 has been marked as a duplicate of this bug. ***
Comment 3 Matt Scheirer 2014-04-27 00:29:33 UTC
Here is a valgrind run on baloo_file, I get the same crash on start bug:

http://goo.gl/Ex0wzq

I solved the problem by deleting the baloo caches in ~/.local/share/baloo. So far, after a few restarts, I am not seeing any crashes on login or other errors from baloo breaking (my problem was tooltips in dolphin were crashing it trying to access semantics through baloo).

I believe it is caused by incomplete transactions during power loss or system crash, that leave it in an invalid state that prevents file lookups and crashes the db.
Comment 4 Enzo 2014-04-28 13:54:56 UTC
Thanks Matt! you're great!
Comment 5 Jekyll Wu 2014-04-29 15:58:48 UTC
*** Bug 333908 has been marked as a duplicate of this bug. ***
Comment 6 Jekyll Wu 2014-04-29 15:59:41 UTC
*** Bug 334005 has been marked as a duplicate of this bug. ***
Comment 7 Jekyll Wu 2014-04-30 04:26:50 UTC

*** This bug has been marked as a duplicate of bug 333722 ***
Comment 8 Jekyll Wu 2014-04-30 05:38:02 UTC
(In reply to comment #7)
> 
> 
> *** This bug has been marked as a duplicate of bug 333722 ***

Sorry for the noisce, wrong operation.
Comment 9 Jekyll Wu 2014-05-03 06:02:18 UTC
*** Bug 334229 has been marked as a duplicate of this bug. ***
Comment 10 Vishesh Handa 2014-05-08 11:11:15 UTC
Hey Matt. Sorry about the delay. Do you still happen to have the valgrind output? The pastebin seems to have expired.

Next time, if possible, please attach it directly on bugzilla.
Comment 11 Dennis Nienhüser 2014-05-08 11:35:12 UTC
I can reproduce a crash with a read-only, empty ~/.local/share/baloo/ and the following valgrind output:

baloo_file(7186): Bananana Error 
baloo_file(7186): Serious Error:  Permission denied 
baloo_file(7186): Couldn't stat '/home/myuser/.local/share/baloo/file/'  DatabaseOpeningError: Couldn't stat '/home/myuser/.local/share/baloo/file/' (Permission denied) 
==7186== Invalid read of size 4
==7186==    at 0x4E33A04: std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator=(std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > > const&) (vector.tcc:161)
==7186==    by 0x4E329FA: Xapian::Database::Database(Xapian::Database const&) (omdatabase.cc:82)
==7186==    by 0x4E3D9C1: Xapian::Enquire::Internal::Internal(Xapian::Database const&, Xapian::ErrorHandler*) (omenquire.cc:621)
==7186==    by 0x4E3DBC6: Xapian::Enquire::Enquire(Xapian::Database const&, Xapian::ErrorHandler*) (omenquire.cc:874)
==7186==    by 0x805DFE3: Baloo::FileIndexingQueue::fillQueue() (in /usr/bin/baloo_file)
==7186==    by 0x805C6E7: Baloo::IndexingQueue::resume() (in /usr/bin/baloo_file)
==7186==    by 0x805C1D5: Baloo::IndexScheduler::IndexScheduler(Database*, Baloo::FileIndexerConfig*, QObject*) (in /usr/bin/baloo_file)
==7186==    by 0x805603F: Baloo::FileIndexer::FileIndexer(Database*, Baloo::FileIndexerConfig*, QObject*) (in /usr/bin/baloo_file)
==7186==    by 0x804EF82: main (in /usr/bin/baloo_file)
==7186==  Address 0x8 is not stack'd, malloc'd or (recently) free'd
==7186==
Comment 12 Christoph Feck 2014-05-15 19:53:22 UTC
*** Bug 334831 has been marked as a duplicate of this bug. ***
Comment 13 Wout Mertens 2014-05-20 02:44:55 UTC
Created attachment 86722 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.13.0 using Qt 4.8.6

- What I was doing when the application crashed:

bootup post disk-full on btrfs filesystem.

-- Backtrace (Reduced):
#6  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x92da80, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#7  0x00007f80b93dcc7c in Xapian::Database::Database (this=0x92da78, other=...) at ../api/omdatabase.cc:82
#8  0x00007f80b93e6dfa in Xapian::Enquire::Internal::Internal (this=0x92da70, db_=..., errorhandler_=0x0) at ../api/omenquire.cc:621
#9  0x00007f80b93e6fae in Xapian::Enquire::Enquire (this=0x7fff20a3db50, databases=..., errorhandler=0x0) at ../api/omenquire.cc:874
#10 0x00000000004173e3 in Baloo::FileIndexingQueue::fillQueue (this=0x8a7fc0) at ../../../src/file/fileindexingqueue.cpp:50
Comment 14 Martin Steigerwald 2014-05-27 08:02:40 UTC
Created attachment 86851 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.13.1 using Qt 4.8.6

I have parts of KDE (kde-baseapps, konsole, kdepim-runtime, kdepimlibs, kdepim) compiled from source, but baloo, kfilemeta and others are from most recent Debian KDE SC 4.13.1 packages. It also happened with self-compiled baloo touch.

- What I was doing when the application crashed:

Running baloo_file.

Error message indicates an issue with opening files:

martin@merkaba:~#255> baloo_file
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
baloo_file(11185): Bananana Error 
baloo_file(11185): Serious Error:   
baloo_file(11185): Error opening table `/home/martin/.local/share/baloo/file//record.':
Unable to read revision from /home/martin/.local/share/baloo/file//record.baseA
Unable to read revision from /home/martin/.local/share/baloo/file//record.baseB
  DatabaseOpeningError: Error opening table `/home/martin/.local/share/baloo/file//record.':
Unable to read revision from /home/martin/.local/share/baloo/file//record.baseA
Unable to read revision from /home/martin/.local/share/baloo/file//record.baseB
 
KCrash: Attempting to start /usr/bin/baloo_file from kdeinit
sock_file=/home/martin/.kde/socket-merkaba/kdeinit4__0
baloo_file(11184): Communication problem with  "baloo_file" , it probably crashed. 
Error message was:  "org.freedesktop.DBus.Error.NoReply" : " "Message did not receive a reply (timeout by message bus)" " 

martin@merkaba:~#255> KCrash: Application 'baloo_file' crashing...
KCrash: Attempting to start /usr/lib/kde4/libexec/drkonqi from kdeinit
sock_file=/home/martin/.kde/socket-merkaba/kdeinit4__0



I think some files are broken – zero byte files – I had an BTRFS hang some time ago. I do not have any own tagged data in it, so I can just have it re-index stuff.

martin@merkaba:~#2> ls -l /home/martin/.local/share/baloo/file/
insgesamt 903412
-rw-r--r-- 1 martin martin 129876992 Mai 26 13:33 fileMap.sqlite3
-rw-r--r-- 1 martin martin     32768 Mai 27 09:54 fileMap.sqlite3-shm
-rw-r--r-- 1 martin martin   1690456 Mai 26 13:44 fileMap.sqlite3-wal
-rw-r--r-- 1 martin martin         0 Mai 27 09:54 flintlock
-rw-r--r-- 1 martin martin        28 Mai  4 13:14 iamchert
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 position.baseA
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 position.baseB
-rw-r--r-- 1 martin martin 414646272 Mai 26 13:44 position.DB
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 postlist.baseA
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 postlist.baseB
-rw-r--r-- 1 martin martin 229089280 Mai 26 13:44 postlist.DB
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 record.baseA
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 record.baseB
-rw-r--r-- 1 martin martin   8536064 Mai 26 13:44 record.DB
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 termlist.baseA
-rw-r--r-- 1 martin martin         0 Mai 26 13:44 termlist.baseB
-rw-r--r-- 1 martin martin 141213696 Mai 26 13:44 termlist.DB


Expected results:

Baloo / Xapian recovers from this situation automatically.

-- Backtrace (Reduced):
#6  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x2170370, __x=<error reading variable: Cannot access memory at address 0x10>) at /usr/include/c++/4.8/bits/vector.tcc:161
#7  0x00007fbc6319a43c in Xapian::Database::Database (this=0x2170368, other=...) at ../api/omdatabase.cc:82
#8  0x00007fbc631a45ba in Xapian::Enquire::Internal::Internal (this=0x2170360, db_=..., errorhandler_=0x0) at ../api/omenquire.cc:621
#9  0x00007fbc631a476e in Xapian::Enquire::Enquire (this=0x7fff2acb9230, databases=..., errorhandler=0x0) at ../api/omenquire.cc:874
#10 0x000000000041738b in Baloo::FileIndexingQueue::fillQueue (this=0x20398a0) at ../../../src/file/fileindexingqueue.cpp:56
Comment 15 Jekyll Wu 2014-05-28 01:50:07 UTC
*** Bug 334720 has been marked as a duplicate of this bug. ***
Comment 16 Olivier van der Toorn 2014-06-07 09:57:06 UTC
Created attachment 87058 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.13.0 using Qt 4.8.6

- What I was doing when the application crashed:

I logged in, the crash reporter showed that Balloo had crashed. Logged out and in again same thing, greeted by a crash report.

-- Backtrace (Reduced):
#5  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x1437b50, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#6  0x00007fe6a8e8dc7c in Xapian::Database::Database (this=0x1437b48, other=...) at ../api/omdatabase.cc:82
#7  0x00007fe6a8e97dfa in Xapian::Enquire::Internal::Internal (this=0x1437b40, db_=..., errorhandler_=0x0) at ../api/omenquire.cc:621
#8  0x00007fe6a8e97fae in Xapian::Enquire::Enquire (this=0x7fff487ae590, databases=..., errorhandler=0x0) at ../api/omenquire.cc:874
#9  0x00000000004173e3 in Baloo::FileIndexingQueue::fillQueue (this=0x14d01a0) at ../../../src/file/fileindexingqueue.cpp:50
Comment 17 Rafael Linux User 2014-06-09 07:43:08 UTC
Same problema here. Baloo error window on starting KDE 4.13 on OpenSUSE 13.1.
If I launch "baloo_file" from console:

Baloo File Indexing has been disabled
baloo_file(3619): Communication problem with  "baloo_file" , it probably crashed.
Error message was:  "org.freedesktop.DBus.Error.NoReply" : " "Message did not receive a reply (timeout by message bus)" "
Comment 18 Rafael Linux User 2014-06-09 08:01:22 UTC
dmesg ouput about baloo:
baloo_file[1975]: segfault at 10 ip 00007fb597ae83fa sp 00007fffb8269340 error 4 in libxapian.so.22.6.4[7fb597a9b000+1f6000]
Comment 19 Katsumi.Haruno 2014-06-21 04:58:50 UTC
Created attachment 87318 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.13.2 using Qt 4.8.6

- What I was doing when the application crashed: Booting up PC and logged into KDE.

-- Backtrace (Reduced):
#5  0x00007f0c3f21a90a in std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x276c050, __x=<error reading variable: Cannot access memory at address 0x10>) at /usr/include/c++/4.9.0/bits/vector.tcc:170
#6  0x00007f0c3f2198ac in Xapian::Database::Database (this=0x276c048, other=...) at api/omdatabase.cc:82
#7  0x00007f0c3f224b08 in Xapian::Enquire::Internal::Internal (this=0x276c040, db_=..., errorhandler_=0x0) at api/omenquire.cc:621
#8  0x00007f0c3f224cfe in Xapian::Enquire::Enquire (this=0x7fffb46ad660, databases=..., errorhandler=0x0) at api/omenquire.cc:874
#9  0x0000000000419c3d in Baloo::FileIndexingQueue::fillQueue (this=0x2764790) at /home/katsumi/Projects/ABS/baloo/src/baloo-4.13.2/src/file/fileindexingqueue.cpp:56
Comment 20 Dennis Nienhüser 2014-07-05 20:36:43 UTC
Still happening on all my systems. Now 4 crash windows pop up one after the other each time I log in.
Comment 21 Martin Steigerwald 2014-07-06 08:42:18 UTC
Please *always* add a version number for such a comment. Otherwise I think the comment is useless for the bug report.

I use Baloo from Git master and it didn´t crash on startup since quite a while. Laurent told me for another bug – search crashing in KMail – that he fixed some more exception. So please, does this still happen with the most recent KDE for you?
Comment 22 Dennis Nienhüser 2014-07-06 13:11:05 UTC
(In reply to comment #21)
> Please *always* add a version number for such a comment. Otherwise I think
> the comment is useless for the bug report.

It's 4.13.2.
 
> I use Baloo from Git master and it didn´t crash on startup since quite a
> while.

You can easily reproduce the problem by moving ~/.local/share/baloo away and creating a read-only file in place (e.g. touch ~/.local/share/baloo; chmod 000 ~/.local/share/baloo;).

Laurent told me for another bug – search crashing in KMail – that he
> fixed some more exception. So please, does this still happen with the most
> recent KDE for you?

You mean commit 7025b81d925dafa442a00b2b731f47523e2514dc. It won't help in all cases, e.g. one of the backtraces goes like this:
#6  0x00000071 in ?? ()
#7  0x080520dc in BalooIndexingAgent::createIndexers (this=this@entry=0x9586958) at ../../../../src/pim/agent/agent.cpp:213
#8  0x080537f4 in BalooIndexingAgent::BalooIndexingAgent (this=0x9586958, id=...) at ../../../../src/pim/agent/agent.cpp:94
#9  0x08055ce2 in Akonadi::AgentBase::init<BalooIndexingAgent> (argc=argc@entry=3, argv=argv@entry=0xbfa74ac4) at /usr/include/akonadi/agentbase.h:446
#10 0x0804fb1b in main (argc=3, argv=0xbfa74ac4) at ../../../../src/pim/agent/agent.cpp:504

agent.cpp:213 in KDE 4.13.2 corresponds to
213       delete indexer;
where indexer is an instance created like new CalendarIndexer(calendarIndexingPath() and line 213 is inside an exception handler. Unfortunately the destructor of CalendarIndexer calls commit() on the xapian database (WritableDatabase), which will throw another exception when the database is corrupt which it is here. A fix for that would be not calling commit() at all in there, because according to the xapian documentation it is done automatically anyway in the WritableDatabase destructor:

	 *  If a transaction is active cancel_transaction() will be implicitly
	 *  called; if no transaction is active commit() will be implicitly
	 *  called, but any exception will be swallowed (because throwing
	 *  exceptions in C++ destructors is problematic).

This won't fix all errors though. The code needs to be revisited with a corrupt database in mind, currently several places I came across assume everything is always fine. Just exiting (without crashing) might be a good option here, but I'd rather leave that up to Vishesh or Montel who have more knowledge of the code.
Comment 23 Martin Steigerwald 2014-07-08 09:37:48 UTC
Dennis, I can confirm your findings and for completeness reported the not writable case as well:

Bug 337224 -  baloo file indexer crashes if .local/share/baloo is not writable

I didn´t check the backtrace yet, whether it is an exact duplicate.
Comment 24 Eike Hein 2014-07-10 07:12:09 UTC
One more:

Application: Baloo File (baloo_file), signal: Segmentation fault
Using host libthread_db library "/lib64/libthread_db.so.1".
81	T_PSEUDO (SYSCALL_SYMBOL, SYSCALL_NAME, SYSCALL_NARGS)
[Current thread is 1 (Thread 0x7f5bc7367980 (LWP 5428))]

Thread 2 (Thread 0x7f5bc04f3700 (LWP 5431)):
#0  0x000000348b6ea9dd in poll () at ../sysdeps/unix/syscall-template.S:81
#1  0x000000348ee09f72 in poll (__timeout=-1, __nfds=1, __fds=0x7f5bc04f2b90) at /usr/include/bits/poll2.h:46
#2  _xcb_conn_wait (c=c@entry=0xff9510, cond=cond@entry=0xff9550, vector=vector@entry=0x0, count=count@entry=0x0) at xcb_conn.c:414
#3  0x000000348ee0b6bf in xcb_wait_for_event (c=0xff9510) at xcb_in.c:526
#4  0x00007f5bc0b3a3e3 in QXcbEventReader::run (this=0x10075d0) at qxcbconnection.cpp:1043
#5  0x00007f5bcbcb0e87 in QThreadPrivate::start (arg=0x10075d0) at thread/qthread_unix.cpp:345
#6  0x000000348c207f33 in start_thread (arg=0x7f5bc04f3700) at pthread_create.c:309
#7  0x000000348b6f4ded in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111

Thread 1 (Thread 0x7f5bc7367980 (LWP 5428)):
[KCrash Handler]
#6  0x0000003df724b39a in std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator=(std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > > const&) () from /lib64/libxapian.so.22
#7  0x0000003df724a38c in Xapian::Database::Database(Xapian::Database const&) () from /lib64/libxapian.so.22
#8  0x0000003df7254d4a in Xapian::Enquire::Internal::Internal(Xapian::Database const&, Xapian::ErrorHandler*) () from /lib64/libxapian.so.22
#9  0x0000003df7254f1e in Xapian::Enquire::Enquire(Xapian::Database const&, Xapian::ErrorHandler*) () from /lib64/libxapian.so.22
#10 0x000000000044369a in Baloo::FileIndexingQueue::fillQueue (this=0x10e3700) at /home/sho/devel/src/kde/kdelibs/baloo/src/file/fileindexingqueue.cpp:58
#11 0x000000000043fd00 in Baloo::IndexScheduler::slotScheduleIndexing (this=0x10ebd70) at /home/sho/devel/src/kde/kdelibs/baloo/src/file/indexscheduler.cpp:271
#12 0x000000000043f230 in Baloo::IndexScheduler::IndexScheduler (this=0x10ebd70, db=0x7fff2e2ce860, config=0x7fff2e2ce8e0, parent=0x7fff2e2ce830) at /home/sho/devel/src/kde/kdelibs/baloo/src/file/indexscheduler.cpp:77
#13 0x000000000043a291 in Baloo::FileIndexer::FileIndexer (this=0x7fff2e2ce830, db=0x7fff2e2ce860, config=0x7fff2e2ce8e0, parent=0x7fff2e2ce960) at /home/sho/devel/src/kde/kdelibs/baloo/src/file/fileindexer.cpp:41
#14 0x000000000042f288 in main (argc=1, argv=0x7fff2e2cece8) at /home/sho/devel/src/kde/kdelibs/baloo/src/file/main.cpp:92
Comment 25 Vishesh Handa 2014-07-21 16:11:15 UTC
Recent findings seem to indicate that this crash occurs due to the database getting corrupted. Could you the affected users please run the baloo_file process manually and paste the debug log.

The debug log will clearly tell you if the database is corrupted. If there is no debug output, then you should enable it via kdebugdialog.
Comment 26 darkosmart 2014-09-07 08:15:39 UTC
(In reply to Matt Scheirer from comment #3)
> Here is a valgrind run on baloo_file, I get the same crash on start bug:
> 
> http://goo.gl/Ex0wzq
> 
> I solved the problem by deleting the baloo caches in ~/.local/share/baloo.
> So far, after a few restarts, I am not seeing any crashes on login or other
> errors from baloo breaking (my problem was tooltips in dolphin were crashing
> it trying to access semantics through baloo).
> 
> I believe it is caused by incomplete transactions during power loss or
> system crash, that leave it in an invalid state that prevents file lookups
> and crashes the db.

This resolves it (In reply to Matt Scheirer from comment #3)
> Here is a valgrind run on baloo_file, I get the same crash on start bug:
> 
> http://goo.gl/Ex0wzq
> 
> I solved the problem by deleting the baloo caches in ~/.local/share/baloo.
> So far, after a few restarts, I am not seeing any crashes on login or other
> errors from baloo breaking (my problem was tooltips in dolphin were crashing
> it trying to access semantics through baloo).
> 
> I believe it is caused by incomplete transactions during power loss or
> system crash, that leave it in an invalid state that prevents file lookups
> and crashes the db.

This solves it for me, also.
Comment 27 Vishesh Handa 2014-10-01 13:27:01 UTC
*** Bug 339473 has been marked as a duplicate of this bug. ***
Comment 28 Eugene 2014-10-16 15:50:46 UTC
Created attachment 89161 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.14.2 using Qt 4.8.6

- What I was doing when the application crashed:
Just logged in KDE.  And crash Immediately happend. Trying to run Dolphin call crash again.

The interesting thing that in other kde accouns it is not crashes but only with this one. Once ran baloo_cleaner after which Dolphin started well. But then I installed some updates into the system and after reboot crash happens again.

-- Backtrace (Reduced):
#5  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0xabdab0, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#6  0x00007ff75d1bdc7c in Xapian::Database::Database (this=0xabdaa8, other=...) at ../api/omdatabase.cc:82
#7  0x00007ff75d1c7dfa in Xapian::Enquire::Internal::Internal (this=0xabdaa0, db_=..., errorhandler_=0x0) at ../api/omenquire.cc:621
#8  0x00007ff75d1c7fae in Xapian::Enquire::Enquire (this=0x7fff358ee270, databases=..., errorhandler=0x0) at ../api/omenquire.cc:874
#9  0x00000000004174d3 in Baloo::FileIndexingQueue::fillQueue (this=0xab8ba0) at ../../../src/file/fileindexingqueue.cpp:56
Comment 29 Vishesh Handa 2014-10-22 12:30:52 UTC
*** Bug 340197 has been marked as a duplicate of this bug. ***
Comment 30 Inge Svensson 2014-11-09 06:33:56 UTC
Created attachment 89508 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.14.2 using Qt 4.8.6

I shut down computer and started it again.

-- Backtrace (Reduced):
#5  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x8d5450, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#6  0x00007f0c47663edc in Xapian::Database::Database (this=0x8d5448, other=...) at api/omdatabase.cc:82
#7  0x00007f0c4766e05a in Xapian::Enquire::Internal::Internal (this=0x8d5440, db_=..., errorhandler_=0x0) at api/omenquire.cc:621
#8  0x00007f0c4766e20e in Xapian::Enquire::Enquire (this=0x7fff482175f0, databases=..., errorhandler=0x0) at api/omenquire.cc:874
#9  0x0000000000417ea3 in Baloo::FileIndexingQueue::fillQueue (this=0x8cf7f0) at /usr/src/debug/baloo-4.14.2/src/file/fileindexingqueue.cpp:56
Comment 31 Tuomas Nurmi 2014-11-11 07:59:26 UTC
Created attachment 89525 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.14.2 using Qt 4.8.6

- What I was doing when the application crashed:

Started the computer with automatic login.

-- Backtrace (Reduced):
#5  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x1db4180, __x=...) at /usr/include/c++/4.8/bits/vector.tcc:161
#6  0x00007f5ce7f28edc in Xapian::Database::Database (this=0x1db4178, other=...) at api/omdatabase.cc:82
#7  0x00007f5ce7f3305a in Xapian::Enquire::Internal::Internal (this=0x1db4170, db_=..., errorhandler_=0x0) at api/omenquire.cc:621
#8  0x00007f5ce7f3320e in Xapian::Enquire::Enquire (this=0x7fff963fc0c0, databases=..., errorhandler=0x0) at api/omenquire.cc:874
#9  0x0000000000417ea3 in _start ()
Comment 32 Tuomas Nurmi 2014-11-11 08:01:55 UTC
Created attachment 89526 [details]
command line output
Comment 33 Vishesh Handa 2014-11-19 14:16:48 UTC
*** Bug 340893 has been marked as a duplicate of this bug. ***
Comment 34 Vishesh Handa 2014-11-22 16:59:55 UTC
*** Bug 341167 has been marked as a duplicate of this bug. ***
Comment 35 elgeneidy 2014-12-23 03:18:57 UTC
Created attachment 90097 [details]
New crash information added by DrKonqi

baloo_file (0.1) on KDE Platform 4.14.3 using Qt 4.8.6

- What I was doing when the application crashed:

On system boot baloo file crashes. Main report is representative of my bug.

-- Backtrace (Reduced):
#6  std::vector<Xapian::Internal::RefCntPtr<Xapian::Database::Internal>, std::allocator<Xapian::Internal::RefCntPtr<Xapian::Database::Internal> > >::operator= (this=this@entry=0x1a0ac20, __x=<error reading variable: Cannot access memory at address 0x10>) at /usr/include/c++/4.8.3/bits/vector.tcc:161
#7  0x00007fdd0a24d19c in Xapian::Database::Database (this=0x1a0ac18, other=...) at api/omdatabase.cc:82
#8  0x00007fdd0a256b0a in Xapian::Enquire::Internal::Internal (this=0x1a0ac10, db_=..., errorhandler_=0x0) at api/omenquire.cc:621
#9  0x00007fdd0a256cde in Xapian::Enquire::Enquire (this=0x7fff0d63aa90, databases=..., errorhandler=0x0) at api/omenquire.cc:874
#10 0x00000000004182ab in Baloo::FileIndexingQueue::fillQueue (this=0x19f2020) at /usr/src/debug/baloo-4.14.3/src/file/fileindexingqueue.cpp:56
Comment 36 Vishesh Handa 2014-12-29 13:49:57 UTC
*** Bug 342211 has been marked as a duplicate of this bug. ***
Comment 37 Vishesh Handa 2014-12-30 11:21:30 UTC
*** Bug 342304 has been marked as a duplicate of this bug. ***
Comment 38 Vishesh Handa 2015-02-11 00:43:46 UTC
*** Bug 344016 has been marked as a duplicate of this bug. ***
Comment 39 Vishesh Handa 2015-02-12 21:38:29 UTC
*** Bug 344086 has been marked as a duplicate of this bug. ***
Comment 40 Vishesh Handa 2015-02-19 21:59:04 UTC
*** Bug 344360 has been marked as a duplicate of this bug. ***
Comment 41 Vishesh Handa 2015-02-25 11:33:48 UTC
*** Bug 344496 has been marked as a duplicate of this bug. ***
Comment 42 Stephan Diestelhorst 2015-03-13 22:10:04 UTC
Created attachment 91550 [details]
Kcrash info for KDE 4.14.2
Comment 43 Stephan Diestelhorst 2015-03-13 22:10:27 UTC
Happens still on KDE 4.14.2
Comment 44 Vishesh Handa 2015-03-17 12:52:26 UTC
*** Bug 345120 has been marked as a duplicate of this bug. ***
Comment 45 Vishesh Handa 2015-03-23 15:46:30 UTC
*** Bug 345444 has been marked as a duplicate of this bug. ***
Comment 46 Vishesh Handa 2015-03-25 00:56:23 UTC
*** Bug 345466 has been marked as a duplicate of this bug. ***
Comment 47 Vishesh Handa 2015-05-11 11:07:26 UTC
Fixed with Plasma 5.4
Comment 48 Christoph Feck 2015-06-07 10:24:13 UTC
*** Bug 348770 has been marked as a duplicate of this bug. ***
Comment 49 David Vincent-Jones 2015-07-21 17:28:24 UTC
Comment on attachment 91550 [details]
Kcrash info for KDE 4.14.2

duplicate problem, same KDE, on OpenSUSE 13.2 with similar trace information.

system was rebuilt 3 time over a period and the problem has persisted.

Lenovo W530 laptop
Comment 50 yodelu 2016-03-16 10:39:33 UTC
rm -rf .local/share/baloo/file/
reboot
that works for me..
Comment 51 Gaspard Bariller 2016-03-28 08:57:18 UTC
Same problem, Baloo crashing at startup, removing cache files in ~/.local/share/baloo worked pretty well.

Thanks !