Bug 352921 - Crash (or lock-up) while applying geotags to images
Summary: Crash (or lock-up) while applying geotags to images
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Database-Sqlite (show other bugs)
Version: 4.13.0
Platform: Other Linux
: NOR crash
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-19 19:20 UTC by Gabriel Burca
Modified: 2017-08-18 19:53 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.0.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gabriel Burca 2015-09-19 19:20:29 UTC
Virtually impossible to geo-tag images without a crash or a lock-up. The progress bar either freezes, and the application stops responding, or the app just crashes. When the app freezes, sometimes the geotagging actually finishes (all the pictures are geotagged, even though the progress bar would indicate only 40% completion for example). I noticed that the chances of a crash or freeze is reduced if only a few pictures at a time are geotagged (10 or so), and if the mouse is not moved (i.e. no movement of the scroll wheel, or movement that would cause other parts of the window to gain focus - I have focus-follows-mouse).

Reproducible: Always

Steps to Reproduce:
1. Select about 100 JPG pictures (5-10Mb each).
2. Image -> Geo-location
3. Load a GPX file and "Correlate", or manually drop the pictures on various locations of the map.
4. Press "Apply"

Actual Results:  
95% of the time the app either crashes, or the progress bar (in the Geolocation window as well as the main app window) stops moving and the app locks up.

Expected Results:  
No crash, no lock-up, progress bar reaches 100% and all the selected images are geotagged.
Comment 1 caulier.gilles 2015-09-19 20:55:23 UTC
Run digiKam into GDB to get a suitable backtrace to hack...

https://www.digikam.org/contrib

Gilles Caulier
Comment 2 Gabriel Burca 2015-09-20 04:15:08 UTC
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fff9afae700 (LWP 13687)]
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x00007fffd9aede5c in ?? () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
#2  0x00007fffd9aee013 in ?? () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
#3  0x00007fffd9b026b9 in ?? () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
#4  0x00007fffd9b2aa75 in ?? () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
#5  0x00007fffd9b32f87 in sqlite3_step () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
#6  0x00007fffc686911c in ?? () from /usr/lib/x86_64-linux-gnu/qt4/plugins/sqldrivers/libqsqlite.so
#7  0x00007fffc6869e48 in ?? () from /usr/lib/x86_64-linux-gnu/qt4/plugins/sqldrivers/libqsqlite.so
#8  0x00007ffff7babb7d in QSqlQuery::exec() () from /usr/lib/x86_64-linux-gnu/libQtSql.so.4
#9  0x00007ffff5c9f416 in Digikam::DatabaseCoreBackend::exec(Digikam::SqlQuery&) () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#10 0x00007ffff5c9f49c in Digikam::DatabaseCoreBackend::execQuery(Digikam::SqlQuery&, QVariant const&) () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#11 0x00007ffff5ca0190 in Digikam::DatabaseCoreBackend::execQuery(QString const&, QVariant const&) () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#12 0x00007ffff5ca01d9 in Digikam::DatabaseCoreBackend::execSql(QString const&, QVariant const&, QList<QVariant>*, QVariant*) ()
   from /usr/lib/digikam/libdigikamcore.so.4.13.0
#13 0x00007ffff5cac0ce in Digikam::ThumbnailDB::findByFilePath(QString const&) () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#14 0x00007ffff5cad557 in Digikam::ThumbnailDB::findByFilePath(QString const&, QString const&) () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#15 0x00007ffff5cce656 in Digikam::ThumbnailCreator::loadDatabaseThumbnailInfo(Digikam::ThumbnailInfo const&) const ()
   from /usr/lib/digikam/libdigikamcore.so.4.13.0
#16 0x00007ffff5cd1baf in Digikam::ThumbnailCreator::loadFromDatabase(Digikam::ThumbnailInfo const&) const () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#17 0x00007ffff5cd33cc in Digikam::ThumbnailCreator::load(Digikam::ThumbnailIdentifier const&, QRect const&, bool) const ()
   from /usr/lib/digikam/libdigikamcore.so.4.13.0
#18 0x00007ffff5cd3c12 in Digikam::ThumbnailCreator::load(Digikam::ThumbnailIdentifier const&) const () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#19 0x00007ffff5ce249e in ?? () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#20 0x00007ffff5cb9996 in Digikam::LoadSaveThread::run() () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#21 0x00007ffff5ce888e in Digikam::DynamicThread::DynamicThreadPriv::run() () from /usr/lib/digikam/libdigikamcore.so.4.13.0
#22 0x00007ffff15c8fee in ?? () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#23 0x00007ffff15d532f in ?? () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#24 0x00007fffed71b182 in start_thread (arg=0x7fff9afae700) at pthread_create.c:312
#25 0x00007ffff0afa47d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111
Comment 3 caulier.gilles 2015-09-20 08:34:05 UTC
It crash in sqlite lib, not digiKam.

We have plenty of report about sqlite dysfunctions.
Comment 4 caulier.gilles 2015-09-20 08:37:08 UTC
Did you enable baloo/nepomuk synchronization settings in digiKam ?
Comment 5 Gabriel Burca 2015-09-21 03:47:31 UTC
Baloo is disabled. I didn't see a setting for Nepomuk.

I've been trying to get it to crash lately, but I'm not having much luck. I have noticed however that even though I erased all GPS data from the image files (using exiftool), DigiKam still shows the blue earth icon in the upper right corner of the Thumbnails indicating that the image has geolocation information. My original crashes were with fresh images off the camera, which DigiKam recognized as not having any geolocation info.

I'll save off a set of unmodified images next time I import and geotag so that I can experiment with them.
Comment 6 caulier.gilles 2015-09-21 08:56:42 UTC
I suspect that the previous backtrace do not identify the real problem.

Run well digiKam into GDB to get another backtrace.
Comment 7 caulier.gilles 2016-07-02 18:59:52 UTC
With digiKam 5.0.0, this problem is not reproducible.

I close this file now. Re-open it if necessary.

Gilles Caulier