Okular does not start: Bus error (core dumped)

I am sometimes unable to start Okular:

$ okular
Bus error (core dumped)

Here is the output of journalctl:

May 16 15:01:52 work systemd[1]: Started Process Core Dump (PID 52888/UID 0).
May 16 15:01:52 work systemd[1]: Started Pass systemd-coredump journal entries to relevant user for potential DrKonqi handling.
May 16 15:01:53 work systemd-coredump[52889]: [🡕] Process 52866 (okular) of user 1000 dumped core.
                                              
                                              Stack trace of thread 52866:
                                              #0  0x000009f1bb97b4ec n/a (libc.so.6 + 0x1674ec)
                                              #1  0x000009f1ae6d2154 n/a (radeonsi_dri.so + 0x8d2154)
                                              #2  0x000009f1ae6d87b2 n/a (radeonsi_dri.so + 0x8d87b2)
                                              #3  0x000009f1ae6c77fb n/a (radeonsi_dri.so + 0x8c77fb)
                                              #4  0x000009f1ae6c969b n/a (radeonsi_dri.so + 0x8c969b)
                                              #5  0x000009f1ae6ca028 n/a (radeonsi_dri.so + 0x8ca028)
                                              #6  0x000009f1ae6ca2c6 n/a (radeonsi_dri.so + 0x8ca2c6)
                                              #7  0x000009f1ae6ca664 n/a (radeonsi_dri.so + 0x8ca664)
                                              #8  0x000009f1ae6c2eba n/a (radeonsi_dri.so + 0x8c2eba)
                                              #9  0x000009f1ae68ab47 n/a (radeonsi_dri.so + 0x88ab47)
                                              #10 0x000009f1ae68b57b n/a (radeonsi_dri.so + 0x88b57b)
                                              #11 0x000009f1ade2daee n/a (radeonsi_dri.so + 0x2daee)
                                              #12 0x000009f1b6173324 n/a (libEGL_mesa.so.0 + 0x23324)
                                              #13 0x000009f1b6173a23 n/a (libEGL_mesa.so.0 + 0x23a23)
                                              #14 0x000009f1ade2f56e n/a (radeonsi_dri.so + 0x2f56e)
                                              #15 0x000009f1ade2f714 n/a (radeonsi_dri.so + 0x2f714)
                                              #16 0x000009f1ade32b56 n/a (radeonsi_dri.so + 0x32b56)
                                              #17 0x000009f1adf06e44 n/a (radeonsi_dri.so + 0x106e44)
                                              #18 0x000009f1adf079d1 n/a (radeonsi_dri.so + 0x1079d1)
                                              #19 0x000009f1ade32726 n/a (radeonsi_dri.so + 0x32726)
                                              #20 0x000009f1ade36223 n/a (radeonsi_dri.so + 0x36223)
                                              #21 0x000009f1b616b135 n/a (libEGL_mesa.so.0 + 0x1b135)
                                              #22 0x000009f1b615b0b0 n/a (libEGL_mesa.so.0 + 0xb0b0)
                                              #23 0x000009f1bc3f2d86 n/a (libEGL.so.1 + 0x4d86)
                                              #24 0x000009f1bc3f2ee3 n/a (libEGL.so.1 + 0x4ee3)
                                              #25 0x000009f1b758d700 _ZN15QtWaylandClient17QWaylandGLContext11makeCurrentEP16QPlatformSurface (libQt6WaylandEglClientHwIntegration.so.6 + 0x9700)
                                              #26 0x000009f1bc897aaa _ZN14QOpenGLContext11makeCurrentEP8QSurface (libQt6Gui.so.6 + 0x497aaa)
                                              #27 0x000009f1bda28fa9 n/a (libKF6Crash.so.6 + 0x7fa9)
                                              #28 0x00005cb11fe1ca03 n/a (okular + 0x12a03)
                                              #29 0x000009f1bb839c88 n/a (libc.so.6 + 0x25c88)
                                              #30 0x000009f1bb839d4c __libc_start_main (libc.so.6 + 0x25d4c)
                                              #31 0x00005cb11fe1eec5 n/a (okular + 0x14ec5)
                                              
                                              Stack trace of thread 52868:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1bc0befd0 _ZN14QWaitCondition4waitEP6QMutex14QDeadlineTimer (libQt6Core.so.6 + 0x2befd0)
                                              #3  0x000009f1ba538c68 n/a (libQt6WaylandClient.so.6 + 0x64c68)
                                              #4  0x000009f1bc0bb619 n/a (libQt6Core.so.6 + 0x2bb619)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52869:
                                              #0  0x000009f1bb91c39d __poll (libc.so.6 + 0x10839d)
                                              #1  0x000009f1ba538ce8 n/a (libQt6WaylandClient.so.6 + 0x64ce8)
                                              #2  0x000009f1bc0bb619 n/a (libQt6Core.so.6 + 0x2bb619)
                                              #3  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #4  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52870:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52875:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52867:
                                              #0  0x000009f1bb91c39d __poll (libc.so.6 + 0x10839d)
                                              #1  0x000009f1bb1ad8fd n/a (libglib-2.0.so.0 + 0xbe8fd)
                                              #2  0x000009f1bb14af95 g_main_context_iteration (libglib-2.0.so.0 + 0x5bf95)
                                              #3  0x000009f1bc193389 _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt6Core.so.6 + 0x393389)
                                              #4  0x000009f1bbf48350 _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt6Core.so.6 + 0x148350)
                                              #5  0x000009f1bc032a20 _ZN7QThread4execEv (libQt6Core.so.6 + 0x232a20)
                                              #6  0x000009f1bcd76b1e n/a (libQt6DBus.so.6 + 0x2db1e)
                                              #7  0x000009f1bc0bb619 n/a (libQt6Core.so.6 + 0x2bb619)
                                              #8  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #9  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52874:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52882:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52873:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52887:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52871:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52872:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52885:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52884:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52883:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              
                                              Stack trace of thread 52886:
                                              #0  0x000009f1bb8a34e9 n/a (libc.so.6 + 0x8f4e9)
                                              #1  0x000009f1bb8a5ed9 pthread_cond_wait (libc.so.6 + 0x91ed9)
                                              #2  0x000009f1ade9891e n/a (radeonsi_dri.so + 0x9891e)
                                              #3  0x000009f1ade766cc n/a (radeonsi_dri.so + 0x766cc)
                                              #4  0x000009f1ade9884d n/a (radeonsi_dri.so + 0x9884d)
                                              #5  0x000009f1bb8a6ded n/a (libc.so.6 + 0x92ded)
                                              #6  0x000009f1bb92a0dc n/a (libc.so.6 + 0x1160dc)
                                              ELF object binary architecture: AMD x86-64
May 16 15:01:53 work systemd[1]: systemd-coredump@14-52888-0.service: Deactivated successfully.
May 16 15:01:53 work drkonqi-coredump-processor[52890]: "/usr/bin/okular" 52866 "/var/lib/systemd/coredump/core.okular.1000.cefd92931a0c4a979a46ea2569b960de.52866.1715864512000000.zst"
May 16 15:01:53 work systemd[1]: drkonqi-coredump-processor@14-52888-0.service: Deactivated successfully.
May 16 15:01:53 work systemd[1272]: Started Launch DrKonqi for a systemd-coredump crash (PID 52890/UID 0).
May 16 15:01:53 work drkonqi-coredump-launcher[52907]: Unable to find file for pid 52866 expected at "kcrash-metadata/okular.cefd92931a0c4a979a46ea2569b960de.52866.ini"
May 16 15:01:53 work drkonqi-coredump-launcher[52907]: Nothing handled the dump :O 

And here is the output when I run Okular in GDB:

[New Thread 0x15554ca006c0 (LWP 56541)]                                                                                                                                                                                                                                      
[New Thread 0x15554c6006c0 (LWP 56542)]
[New Thread 0x155545c006c0 (LWP 56543)]
[New Thread 0x1555458006c0 (LWP 56544)]
[New Thread 0x1555454006c0 (LWP 56545)]
[New Thread 0x1555450006c0 (LWP 56546)]
[New Thread 0x155544c006c0 (LWP 56547)]
[New Thread 0x1555448006c0 (LWP 56548)]
[New Thread 0x1555444006c0 (LWP 56549)]
[New Thread 0x155533c006c0 (LWP 56550)]
[New Thread 0x1555338006c0 (LWP 56551)]
[New Thread 0x1555334006c0 (LWP 56552)]
[Thread 0x1555334006c0 (LWP 56552) exited]

Thread 1 "okular" received signal SIGBUS, Bus error.
__memcpy_avx_unaligned_erms () at ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S:405
Downloading source file /usr/src/debug/glibc/glibc/string/../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S
405             VMOVU   %VMM(0), (%rdi)                                                                                                                                                                                                                                      
(gdb) bt
#0  __memcpy_avx_unaligned_erms () at ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S:405
#1  0x00001555466c26fb in memcpy () at /usr/include/bits/string_fortified.h:29
#2  si_buffer_subdata () at ../mesa-24.0.7/src/gallium/drivers/radeonsi/si_buffer.c:540
#3  0x0000155546668cb7 in pipe_buffer_write_nooverlap () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_inlines.h:477
#4  pipe_buffer_create_with_data () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_inlines.h:515
#5  si_set_framebuffer_state () at ../mesa-24.0.7/src/gallium/drivers/radeonsi/si_state.c:3247
#6  0x000015554641b77e in tc_call_set_framebuffer_state () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_threaded_context.c:1525

#7  0x000015554641825e in batch_execute () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_threaded_context.c:461
#8  tc_batch_execute () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_threaded_context.c:512
#9  0x00001555464189c8 in _tc_sync () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_threaded_context.c:767
#10 0x0000155546418b4b in tc_destroy () at ../mesa-24.0.7/src/gallium/auxiliary/util/u_threaded_context.c:5141
#11 0x0000155545ef3afd in st_destroy_context_priv () at ../mesa-24.0.7/src/mesa/state_tracker/st_context.c:372
#12 0x0000155545ef5362 in st_destroy_context () at ../mesa-24.0.7/src/mesa/state_tracker/st_context.c:1003
#13 0x0000155545e325d0 in dri_destroy_context () at ../mesa-24.0.7/src/gallium/frontends/dri/dri_context.c:277
#14 0x000015554d35d803 in dri2_destroy_context () at ../mesa-24.0.7/src/egl/drivers/dri2/egl_dri2.c:1590
#15 0x000015554d34fd89 in eglDestroyContext () at ../mesa-24.0.7/src/egl/main/eglapi.c:918
#16 0x000015554e99c8a2 in QtWaylandClient::QWaylandGLContext::~QWaylandGLContext (this=0x555555728aa0, this=<optimized out>) at /usr/src/debug/qt6-wayland/qtwayland-everywhere-src-6.7.0/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp:271
#17 0x000015554e99c8de in QtWaylandClient::QWaylandGLContext::~QWaylandGLContext (this=0x555555728aa0, this=<optimized out>) at /usr/src/debug/qt6-wayland/qtwayland-everywhere-src-6.7.0/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp:272
#18 0x0000155553e9789e in QOpenGLContext::destroy (this=this@entry=0x7fffffffd0e0) at /usr/src/debug/qt6-base/qtbase/src/gui/kernel/qopenglcontext.cpp:442
#19 0x0000155553e9798f in QOpenGLContext::~QOpenGLContext (this=this@entry=0x7fffffffd0e0, this=<optimized out>) at /usr/src/debug/qt6-base/qtbase/src/gui/kernel/qopenglcontext.cpp:469
#20 0x000015554e9e2620 in initializeRendererSessions () at /usr/src/debug/plasma-integration/plasma-integration-6.0.4/qt6/src/platformtheme/qtquickrenderersettings.cpp:94
#21 0x0000155553543532 in qt_call_pre_routines () at /usr/src/debug/qt6-base/qtbase/src/corelib/kernel/qcoreapplication.cpp:309
#22 QCoreApplicationPrivate::init (this=this@entry=0x5555555b87b0) at /usr/src/debug/qt6-base/qtbase/src/corelib/kernel/qcoreapplication.cpp:919
#23 0x0000155553b7ade0 in QGuiApplicationPrivate::init (this=this@entry=0x5555555b87b0) at /usr/src/debug/qt6-base/qtbase/src/gui/kernel/qguiapplication.cpp:1580
#24 0x00001555544f7596 in QApplicationPrivate::init (this=0x5555555b87b0) at /usr/src/debug/qt6-base/qtbase/src/widgets/kernel/qapplication.cpp:472
#25 0x00001555544f76f2 in QApplication::QApplication (this=this@entry=0x7fffffffd560, argc=@0x7fffffffd54c: 1, argv=<optimized out>, this=<optimized out>, argc=<optimized out>, argv=<optimized out>)
    at /usr/src/debug/qt6-base/qtbase/src/widgets/kernel/qapplication.cpp:460
#26 0x00005555555660f2 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/okular/okular-24.02.2/shell/main.cpp:46
(gdb)

How would one debug this?

This looks like what I’m experiencing as well. You’re not using Arch are you? I haven’t had any luck getting insight on this if it is the same issue.

I am indeed using Arch. I switched from dbus-daemon-units to dbus-broker-units yesterday and haven’t faced this issue thus far. Firefox still keeps crashing occasionally but KDE apps seem to be more stable now.

From a quick look at the backtrace, it looks like its crashing in your graphics driver (mesa)

1 Like

Is the issue still occurring for you? After a couple of updates, I haven’t seen it again.

I was still seeing it yesterday but not today. Maybe one of the recent updates helped.