Bug 424618 - When clicking on maps digiKam crash
Summary: When clicking on maps digiKam crash
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Searches-Map (show other bugs)
Version: 7.0.0
Platform: Appimage Linux
: NOR crash
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-24 19:00 UTC by diegomp5
Modified: 2021-03-31 20:31 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 7.3.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description diegomp5 2020-07-24 19:00:18 UTC
SUMMARY

When I click the map section on the sidebar digikam crashes I'm using the appimage version 7.0.0.

STEPS TO REPRODUCE
1. download version 7.0.0 appimage
2. run the appimage
3. click on the map button on the sidebar

OBSERVED RESULT

The app crashes

EXPECTED RESULT

show map screen

SOFTWARE/OS VERSIONS
Linux: Solus GNOME
Comment 1 Maik Qualmann 2020-07-24 19:16:46 UTC
Please start the AppImage in the terminal with the "debug" option and post the backtrace.

Maik
Comment 2 diegomp5 2020-07-24 22:44:19 UTC
what is backtrace?
Comment 3 caulier.gilles 2020-07-25 02:04:19 UTC
the text trace od debugger on the console. See details here :

https://www.digikam.org/contribute/
Comment 4 diegomp5 2020-07-26 01:22:10 UTC
when I used gdb it said there was no bugs but when I just start digikam from the comand line I get 

Unhandled container to remove :  Digikam::DigikamApp
[8326:8343:0725/211550.631570:ERROR:nss_util.cc(674)] Error initializing NSS with a persistent database (sql:/home/mypc/.pki/nssdb): NSS error code: -8023
[8326:8343:0725/211550.631709:ERROR:nss_util.cc(154)] Error initializing NSS without a persistent database: NSS error code: -8023
[8326:8343:0725/211550.631720:FATAL:nss_util.cc(156)] nss_error=-8023, os_error=0
/tmp/.mount_digikaBULjeR/AppRun: line 157:  8326 Trace/breakpoint trap   digikam $@
Comment 5 caulier.gilles 2020-07-26 04:42:38 UTC
Sound like a lib problem used by Chromium browser (qtwebengine component in digiKam)

https://askubuntu.com/questions/801838/google-chrome-error-error-initializing-nss-without-a-persistent-database

Gilles Caulier
Comment 6 diegomp5 2020-07-26 04:48:05 UTC
it works without any porblems on 6.4.0 but when I downloaded 7.0.0 it stoped working.
Comment 7 Maik Qualmann 2020-07-26 07:22:36 UTC
DigiKam-6.4.0 still used QWebKit as browser engine. But for security reasons it shouldn't be used anymore because we also login to web services with the browser engine in the export tools.

The problem is related to libnss3.so.

Either you need a preload of the library or maybe this helps:

https://askubuntu.com/questions/801838/google-chrome-error-error-initializing-nss-without-a-persistent-database

Maik
Comment 8 Maik Qualmann 2020-07-27 06:01:15 UTC
*** Bug 424683 has been marked as a duplicate of this bug. ***
Comment 9 haselnuss87 2020-07-29 09:43:50 UTC
The workaround in comment 7 did not work for me, at least not as a copy+paste solution. I don't know anything about symbolic links.

Debian stable with AppImage 7.0.0
Comment 10 caulier.gilles 2020-07-30 09:45:14 UTC
digiKam 7.0.0 stable release is now published:

https://www.digikam.org/news/2020-07-19-7.0.0_release_announcement/

We need a fresh feedback on this file using this version.

Thanks in advance

Gilles Caulier
Comment 11 haselnuss87 2020-07-30 11:39:24 UTC
(In reply to caulier.gilles from comment #10)
> digiKam 7.0.0 stable release is now published:
> 
> https://www.digikam.org/news/2020-07-19-7.0.0_release_announcement/
> 
> We need a fresh feedback on this file using this version.
> 
> Thanks in advance
> 
> Gilles Caulier

I don't understand. I did not use the RC version. I used the stable release.
Comment 12 Maik Qualmann 2020-08-08 09:35:16 UTC

*** This bug has been marked as a duplicate of bug 417121 ***
Comment 13 caulier.gilles 2020-08-31 13:03:42 UTC
Git commit f1d54b95ddb67f2f4d8484f49806f462bca5e72d by Gilles Caulier.
Committed on 31/08/2020 at 13:01.
Pushed by cgilles into branch 'master'.

AppImage: preload libnssutil3 to prevent crash with GoogleMaps and QtWebEngine
Related: bug 417121
FIXED-IN: 7.1.0

M  +5    -0    project/bundles/appimage/data/AppRun

https://invent.kde.org/graphics/digikam/commit/f1d54b95ddb67f2f4d8484f49806f462bca5e72d
Comment 14 haselnuss87 2020-09-11 21:58:32 UTC
This is still happening in 7.1.0 appimage using Debian Buster:

[10786:10804:0911/235137.041938:ERROR:nss_util.cc(674)] Error initializing NSS with a persistent database (sql:/home/%USER%/.pki/nssdb): NSS error code: -8023
[10786:10804:0911/235137.042226:ERROR:nss_util.cc(154)] Error initializing NSS without a persistent database: NSS error code: -8023
[10786:10804:0911/235137.042251:FATAL:nss_util.cc(156)] nss_error=-8023, os_error=0
/tmp/.mount_digika1Azy7K/AppRun: line 163: 10786 Trace/breakpoint trap   digikam $@
Comment 15 caulier.gilles 2020-09-12 04:08:45 UTC
This can fix your crash if you force to preload xcb-dri3 shared library before the appimage ?


env LD_PRELOAD="/usr/lib64/libxcb-dri3.so.0" ./digikam-7.1.0-x86-64.appimage
Comment 16 haselnuss87 2020-09-14 07:33:27 UTC
I get a whole bunch of errors when issuing this command:

ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
-- digiKam Linux AppImage Bundle
-- Use 'help' as CLI argument to know all available options for digiKam application.
-- Notes: to integrate this bundle to your desktop, use AppImageLauncher.
--        to enable all debug messages on the console, use 'export QT_LOGGING_RULES="digikam*=true"'.
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
libudev.so.0 
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
libnss3.so 
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
libnssutil3.so 
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
libxcb-dri3.so.0 
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
-- Preloading shared libs: /usr/lib64/libxcb-dri3.so.0:/tmp/.mount_digikadYRVO6/usr/lib64/libnss3.so:/tmp/.mount_digikadYRVO6/usr/lib64/libnssutil3.so:/tmp/.mount_digikadYRVO6/usr/lib64/libxcb-dri3.so.0
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libxcb-dri3.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
QtAV 1.13.0(Sep  3 2020, 08:17:38)
Multimedia framework base on Qt and FFmpeg.
Distributed under the terms of LGPLv2.1 or later.
Shanghai, China Copyright (C) 2012-2019 Wang Bin (aka. Lucas Wang) wbsecg1@gmail.com
Donate: http://qtav.org/donate.html
Source: https://github.com/wang-bin/QtAV
Home page: http://qtav.org
unknown: Unhandled container to remove :  Digikam::DigikamApp
[8270:8287:0914/093052.445165:ERROR:nss_util.cc(674)] Error initializing NSS with a persistent database (sql:/home/helmar/.pki/nssdb): NSS error code: -8023
[8270:8287:0914/093052.445422:ERROR:nss_util.cc(154)] Error initializing NSS without a persistent database: NSS error code: -8023
[8270:8287:0914/093052.445443:FATAL:nss_util.cc(156)] nss_error=-8023, os_error=0
/tmp/.mount_digikadYRVO6/AppRun: line 163:  8270 Trace/breakpoint trap   digikam $@
Comment 17 haselnuss87 2020-09-14 07:36:44 UTC
Can't edit my last reply, could some mod please redact my user name in Comment 16?
Comment 18 caulier.gilles 2020-09-14 09:31:47 UTC
well no, it's not a wiki, comments still read only...

Gilles Caulier
Comment 19 jgoerzen 2020-09-14 22:09:41 UTC
I am also experiencing this on Debian buster, or even a crash on start (us kernel.unprivileged_userns_clone=1).

Workaround:

./digikam-7.0.0-x86-64.appimage --appimage-extract
cd squashfs-root
find . -name '*nss*.so' -delete
edit AppRun, comment out "preload_shared_library libnss3.so"
cd ..
./appimagetool-x86_64.AppImage squashfs-root/ digikamtest.AppImage

appimagetool is from https://github.com/AppImage/AppImageKit/releases

So to summarize, for me, removing nss from the appimage fixes the issue.
Comment 20 caulier.gilles 2020-09-16 13:08:45 UTC
Git commit 9d5229606f0781f549f76545b718685f98771881 by Gilles Caulier.
Committed on 16/09/2020 at 13:07.
Pushed by cgilles into branch 'master'.

Drop libnss*3.so from AppImage bundle

M  +2    -0    project/bundles/appimage/04-build-appimage.sh
M  +0    -4    project/bundles/appimage/data/AppRun

https://invent.kde.org/graphics/digikam/commit/9d5229606f0781f549f76545b718685f98771881
Comment 21 caulier.gilles 2020-09-17 03:15:21 UTC
7.2.0-beta1 appimage bundle are now build without libnss internally, and it available for testing at this url:

https://files.kde.org/digikam/

Can you reproduce the crash ?

Thanks in advance

Gilles Caulier
Comment 22 caulier.gilles 2021-03-30 06:53:34 UTC
digiKam 7.2.0 official release is published with more than 360 files closed from bugzilla:

https://www.digikam.org/news/2021-03-22-7.2.0_release_announcement/

Can you reproduce the dysfunction with this version ?

Thanks in advance for your feedback

Gilles Caulier
Comment 23 haselnuss87 2021-03-31 20:28:10 UTC
(In reply to caulier.gilles from comment #22)
> digiKam 7.2.0 official release is published with more than 360 files closed
> from bugzilla:
> 
> https://www.digikam.org/news/2021-03-22-7.2.0_release_announcement/
> 
> Can you reproduce the dysfunction with this version ?
> 
> Thanks in advance for your feedback
> 
> Gilles Caulier

I can confirm that the bug is resolved for Debian Buster with version 7.2.0