Freecad 0.20.2 on Debian bookworm segfaults

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
ceving
Posts: 87
Joined: Wed Sep 20, 2017 9:46 am

Freecad 0.20.2 on Debian bookworm segfaults

Post by ceving »

FreeCAD constantly segfaults. Any ideas what might be wrong?

Code: Select all

FreeCAD 0.20.2, Libs: 0.20.2R
© Juergen Riegel, Werner Mayer, Yorik van Havre and others 2001-2022
FreeCAD is free and open-source software licensed under the terms of LGPL2+ license.
FreeCAD wouldn't be possible without FreeCAD community.
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

Program received signal SIGSEGV, Segmentation fault.
#0  /lib/x86_64-linux-gnu/libc.so.6(+0x3bf90) [0x7f2a3bc5af90]
#1  0x7f2a3c700670 in QBackingStore::beginPaint(QRegion const&) from /lib/x86_64-linux-gnu/libQt5Gui.so.5+0xd0
#2  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x17413e) [0x7f2a3cd7413e]
#3  0x7f2a3cda5078 in QWidget::event(QEvent*) from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x468
#4  0x7f2a3cd62fae in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x7e
#5  0x7f2a3e6270e8 in Gui::GUIApplication::notify(QObject*, QEvent*) from /usr/lib/freecad-python3/lib/libFreeCADGui.so+0x88
#6  0x7f2a3c0b16f8 in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /lib/x86_64-linux-gnu/libQt5Core.so.5+0x118
#7  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x1751f5) [0x7f2a3cd751f5]
#8  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x177c60) [0x7f2a3cd77c60]
#9  0x7f2a3cd8eb10 in QWidget::repaint(QRect const&) from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x80
#10  0x7f2a3cd8eb6a in QWidget::repaint() from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x3a
#11  0x7f2a3cf11b89 in QSplashScreen::repaint() from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x9
#12  /usr/lib/freecad-python3/lib/libFreeCADGui.so(+0x774b89) [0x7f2a3e974b89]
#13  0x7f2a3f3279bd in Base::ConsoleSingleton::NotifyLog(char const*) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0xbd
#14  0x7f2a3f327c93 in Base::ConsoleSingleton::Log(char const*, ...) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0x213
#15  0x7f2a3e5bd421 in messageHandler(QtMsgType, QMessageLogContext const&, QString const&) from /usr/lib/freecad-python3/lib/libFreeCADGui.so+0x51
#16  /lib/x86_64-linux-gnu/libQt5Core.so.5(+0xc3b50) [0x7f2a3bec3b50]
#17  /lib/x86_64-linux-gnu/libQt5Core.so.5(+0xc3c68) [0x7f2a3bec3c68]
#18  0x7f2a3be9053d in QMessageLogger::warning(char const*, ...) const from /lib/x86_64-linux-gnu/libQt5Core.so.5+0xaf
#19  /lib/x86_64-linux-gnu/libQt5XcbQpa.so.5(+0x6174a) [0x7f2a361ef74a]
#20  /lib/x86_64-linux-gnu/libQt5XcbQpa.so.5(+0x62712) [0x7f2a361f0712]
#21  /lib/x86_64-linux-gnu/libQt5XcbQpa.so.5(+0x6453b) [0x7f2a361f253b]
#22  0x7f2a3c7000d7 in QBackingStore::resize(QSize const&) from /lib/x86_64-linux-gnu/libQt5Gui.so.5+0xa7
#23  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x1735df) [0x7f2a3cd735df]
#24  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x174afa) [0x7f2a3cd74afa]
#25  /lib/x86_64-linux-gnu/libQt5Widgets.so.5(+0x1c124c) [0x7f2a3cdc124c]
#26  0x7f2a3cd62fae in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /lib/x86_64-linux-gnu/libQt5Widgets.so.5+0x7e
#27  0x7f2a3e6270e8 in Gui::GUIApplication::notify(QObject*, QEvent*) from /usr/lib/freecad-python3/lib/libFreeCADGui.so+0x88
#28  0x7f2a3c0b16f8 in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /lib/x86_64-linux-gnu/libQt5Core.so.5+0x118
#29  0x7f2a3c53e5cd in QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) from /lib/x86_64-linux-gnu/libQt5Gui.so.5+0x8d
#30  0x7f2a3c511cac in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /lib/x86_64-linux-gnu/libQt5Gui.so.5+0xac
#31  /lib/x86_64-linux-gnu/libQt5XcbQpa.so.5(+0x6deba) [0x7f2a361fbeba]
#32  /lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_context_dispatch+0x299) [0x7f2a3a1d47a9]
#33  /lib/x86_64-linux-gnu/libglib-2.0.so.0(+0x54a38) [0x7f2a3a1d4a38]
#34  /lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_context_iteration+0x2c) [0x7f2a3a1d4acc]
#35  0x7f2a3c109836 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /lib/x86_64-linux-gnu/libQt5Core.so.5+0x66
#36  /usr/lib/freecad-python3/lib/libFreeCADGui.so(+0x774b89) [0x7f2a3e974b89]
#37  0x7f2a3f3279bd in Base::ConsoleSingleton::NotifyLog(char const*) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0xbd
#38  0x7f2a3f327c93 in Base::ConsoleSingleton::Log(char const*, ...) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0x213
#39  0x7f2a3f3283aa in Base::ConsoleSingleton::sPyLog(_object*, _object*) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0x6a
#40  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(+0x1c9ba1) [0x7f2a3d5c9ba1]
#41  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(_PyObject_MakeTpCall+0x7d) [0x7f2a3d57be8d]
#42  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(_PyEval_EvalFrameDefault+0x4a63) [0x7f2a3d509c63]
#43  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(+0x3ccd3c) [0x7f2a3d7ccd3c]
#44  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(PyEval_EvalCode+0xc1) [0x7f2a3d668891]
#45  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(+0x2b7359) [0x7f2a3d6b7359]
#46  /lib/x86_64-linux-gnu/libpython3.11.so.1.0(PyRun_StringFlags+0x6b) [0x7f2a3d6b850b]
#47  0x7f2a3f33d898 in Base::InterpreterSingleton::runString[abi:cxx11](char const*) from /usr/lib/freecad-python3/lib/libFreeCADBase.so+0x68
#48  0x7f2a3e5bda9f in Gui::Application::runInitGuiScript() from /usr/lib/freecad-python3/lib/libFreeCADGui.so+0x3f
#49  0x7f2a3e5c2c59 in Gui::Application::runApplication() from /usr/lib/freecad-python3/lib/libFreeCADGui.so+0x10c9
#50  freecad(+0x4c01) [0x55ded54bfc01]
#51  /lib/x86_64-linux-gnu/libc.so.6(+0x2718a) [0x7f2a3bc4618a]
#52  /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x85) [0x7f2a3bc46245]
#53  freecad(+0x5ad1) [0x55ded54c0ad1]
Appimage crashes too:

Code: Select all

FreeCAD 0.20.2, Libs: 0.20.2R29603 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre and others 2001-2022
FreeCAD is free and open-source software licensed under the terms of LGPL2+ license.
FreeCAD wouldn't be possible without FreeCAD community.
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

/home/runner/work/FreeCAD-Bundle/FreeCAD-Bundle/conda/linux/AppDir/usr/share/libdrm/amdgpu.ids: Datei oder Verzeichnis nicht gefunden
Program received signal SIGSEGV, Segmentation fault.
#0  /lib/x86_64-linux-gnu/libc.so.6(+0x3bf90) [0x7f6298e5af90]
#1  0x7f62997f1ebe in QBackingStore::beginPaint(QRegion const&) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Gui.so.5+0xb2
#2  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x1742ec) [0x7f6299d742ec]
#3  0x7f6299d94c1d in QWidget::event(QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0x905
#4  0x7f6299d6a0f7 in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0xd9
#5  0x7f629b28cda9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so+0x89
#6  0x7f62991c2608 in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5+0x8e
#7  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x174e59) [0x7f6299d74e59]
#8  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x177039) [0x7f6299d77039]
#9  0x7f6299d841f0 in QWidget::repaint(QRect const&) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0x70
#10  0x7f6299d8421f in QWidget::repaint() from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0x27
#11  0x7f6299e77808 in QSplashScreen::repaint() from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0x6
#12  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so(+0x8f3f34) [0x7f629b6f3f34]
#13  0x7f629a2d2b25 in Base::ConsoleSingleton::NotifyLog(char const*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0xc5
#14  0x7f629a2d2e24 in Base::ConsoleSingleton::Log(char const*, ...) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0x234
#15  0x7f629b1ee9a2 in messageHandler(QtMsgType, QMessageLogContext const&, QString const&) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so+0x52
#16  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5(+0xa59d7) [0x7f62990a59d7]
#17  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5(+0xa5a7c) [0x7f62990a5a7c]
#18  0x7f629909852d in QMessageLogger::warning(char const*, ...) const from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5+0xa1
#19  /tmp/.mount_FreeCA7s4ucj/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x4d2f3) [0x7f62946282f3]
#20  /tmp/.mount_FreeCA7s4ucj/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x4da5f) [0x7f6294628a5f]
#21  /tmp/.mount_FreeCA7s4ucj/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x4eea5) [0x7f6294629ea5]
#22  0x7f62997f1a4f in QBackingStore::resize(QSize const&) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Gui.so.5+0x7f
#23  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x173bfd) [0x7f6299d73bfd]
#24  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x1746fa) [0x7f6299d746fa]
#25  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5(+0x1a499f) [0x7f6299da499f]
#26  0x7f6299d6a0f7 in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Widgets.so.5+0xd9
#27  0x7f629b28cda9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so+0x89
#28  0x7f62991c2608 in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5+0x8e
#29  0x7f6299709e3d in QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Gui.so.5+0xef
#30  0x7f62996f5f29 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Gui.so.5+0x57
#31  /tmp/.mount_FreeCA7s4ucj/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x55294) [0x7f6294630294]
#32  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_dispatch+0x25c) [0x7f6297dde1bc]
#33  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/./libglib-2.0.so.0(+0x58489) [0x7f6297dde489]
#34  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_iteration+0x31) [0x7f6297dde551]
#35  0x7f62991f33f3 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libQt5Core.so.5+0x5b
#36  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so(+0x8f3f34) [0x7f629b6f3f34]
#37  0x7f629a2d2b25 in Base::ConsoleSingleton::NotifyLog(char const*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0xc5
#38  0x7f629a2d2e24 in Base::ConsoleSingleton::Log(char const*, ...) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0x234
#39  0x7f629a2d34be in Base::ConsoleSingleton::sPyLog(_object*, _object*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0x6e
#40  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(+0x1480d2) [0x7f629ab480d2]
#41  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(_PyObject_MakeTpCall+0x2bb) [0x7f629ab40fdb]
#42  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(_PyEval_EvalFrameDefault+0x4d8a) [0x7f629ab3c3aa]
#43  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(+0x1ed6a2) [0x7f629abed6a2]
#44  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(PyEval_EvalCode+0x8c) [0x7f629abed5ec]
#45  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(+0x21f43d) [0x7f629ac1f43d]
#46  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(+0x219e1b) [0x7f629ac19e1b]
#47  /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libpython3.10.so.1.0(PyRun_StringFlags+0x7d) [0x7f629ac1209d]
#48  0x7f629a2efccc in Base::InterpreterSingleton::runString[abi:cxx11](char const*) from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADBase.so+0x6c
#49  0x7f629b1f1933 in Gui::Application::runInitGuiScript() from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so+0x43
#50  0x7f629b210f26 in Gui::Application::runApplication() from /tmp/.mount_FreeCA7s4ucj/usr/bin/../lib/libFreeCADGui.so+0x12d6
#51  /tmp/.mount_FreeCA7s4ucj/usr/bin/freecad(+0x68e5) [0x5629cb39f8e5]
#52  /lib/x86_64-linux-gnu/libc.so.6(+0x2718a) [0x7f6298e4618a]
#53  /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x85) [0x7f6298e46245]
#54  /tmp/.mount_FreeCA7s4ucj/usr/bin/freecad(+0x6c29) [0x5629cb39fc29]
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by adrianinsaval »

graphics driver is usually the first suspect in this cases, what graphics card do you have and what driver are you using? the nouveau driver is known to be shity for example.

Try enabling software opengl in preferences

Try disabling the startpage.

Describe what you are usually doing when it crashes.
wmayer
Founder
Posts: 20243
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by wmayer »

According to the call stack some warnings are written. In order to find out what is written you should start FreeCAD with the option --write-log. After the crash open the file ~/.local/share/FreeCAD/FreeCAD.log
ceving
Posts: 87
Joined: Wed Sep 20, 2017 9:46 am

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by ceving »

adrianinsaval wrote: Thu Mar 30, 2023 2:56 am graphics driver is usually the first suspect in this cases, what graphics card do you have and what driver are you using?
I am using the integrated graphics of an AMD Ryzen 7 5700G. glxgears runs fine and Civilization VI works, too.
adrianinsaval wrote: Thu Mar 30, 2023 2:56 am Try enabling software opengl in preferences
Try disabling the startpage.
Describe what you are usually doing when it crashes.
I can not do anything. It crashes instantly after the start.
ceving
Posts: 87
Joined: Wed Sep 20, 2017 9:46 am

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by ceving »

Compiling the source fixed it.
marcidy
Posts: 3
Joined: Thu Jun 22, 2023 10:46 pm

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by marcidy »

I have this same issue on my laptop which i just upgraded to debian 12. Crash with debian 12 (bookworm) FreeCad 20.2 and the 20.2 AppImage.

Attached is an example and strace of the issue, captured via screen.

unfortunately i cannot determine what's the problem

it's not possible to use any switch except -h. They cause a different crash:


marcidy@Moog:~$ freecad -c
Argument expected for the -c option
usage: freecad [option] ... [-c cmd | -m mod | file | -] [arg] ...
Try `python -h' for more information.
Program received signal SIGSEGV, Segmentation fault.
#0 /lib/x86_64-linux-gnu/libc.so.6(+0x3bf90) [0x7f63f9e5af90]
#1 /lib/x86_64-linux-gnu/libc.so.6(+0x175066) [0x7f63f9f94066]
#2 /lib/x86_64-linux-gnu/libpython3.11.so.1.0(+0x2d07f3) [0x7f63fb8d07f3]
#3 /lib/x86_64-linux-gnu/libpython3.11.so.1.0(Py_EncodeLocale+0x4e) [0x7f63fb8d0ede]
#4 freecad(+0x5034) [0x561690c23034]
#5 /lib/x86_64-linux-gnu/libc.so.6(+0x2718a) [0x7f63f9e4618a]
#6 /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x85) [0x7f63f9e46245]
#7 freecad(+0x5ad1) [0x561690c23ad1]


No logs are written with the --with-log or -l switches, they crash with the same smaller stack.

Interestingly, i can use the "freecadcmd-python3" command directly to get the shell:


./freecadcmd-python3
FreeCAD 0.20.2, Libs: 0.20.2R
(c) Juergen Riegel, Werner Mayer, Yorik van Havre and others 2001-2022
FreeCAD is free and open-source software licensed under the terms of LGPL2+ license.
FreeCAD wouldn't be possible without FreeCAD community.
##### #### ### ####
# # # # # #
# ## #### #### # # # # #
#### # # # # # # # ##### # #
# # #### #### # # # # #
# # # # # # # # # ## ## ##
# # #### #### ### # # #### ## ## ##

[FreeCAD Console mode <Use Ctrl-D (i.e. EOF) to exit.>]
>>>


i haven't made further progress beyond this, might go the compile route to see if that works. Let me know if there's anything i can log / poke at for this, i don't really know how to debug this further.

I have reinstalled a couple times including deleting everything under my home directory in .cache, .config, and .FreeCAD.
Attachments
FreeCAD-Debian12-20.2-strace.gz
(111.48 KiB) Downloaded 30 times
xemul
Posts: 394
Joined: Tue Mar 21, 2023 9:35 pm

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by xemul »

There are no problems with FC 0.21 (many builds) on neither Bookworm nor Bullseye.
I also can not remember such problems with 0.20 on Bullseye.
You can try edit ~/.config/FreeCAD/user.cfg to enable software OpenGL

Code: Select all

<FCBool Name="UseSoftwareOpenGL" Value="1"/>
to exclude graphics driver issue.
Laurie Hartley
Posts: 522
Joined: Mon Feb 27, 2017 5:33 am
Location: Australia

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by Laurie Hartley »

Just a random thought. I had a similar problem sometime ago with an AMD Ryzen with integrated graphics driver on Debian Buster 10. Changing the Kernel back to 5.14 fixed it.
marcidy
Posts: 3
Joined: Thu Jun 22, 2023 10:46 pm

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by marcidy »

Thank you for the replies, im only at this machine twice a week and even then, not always able to work on it. Sorry for the slow response.

I did a complete reinstall from scratch of debian 12 and still yielded the crash, both with the packaged FreeCAD 0.20.2 and with a compiled FreeCAD 0.20.2.

The crash occurred in both of the above caes with and without enabling SoftwareOpenGL.


I'm going to try installing a kernel between 5.10 and 6.0 later to see if that fixes it.

A compiled 20.2 worked fine on my desktop at home with debian 12, whatever it is seems localized on the laptop.

I'll keep plugging at it, there's nothing wrong with 20.2, hopefully i can isolate the issue.
marcidy
Posts: 3
Joined: Thu Jun 22, 2023 10:46 pm

Re: Freecad 0.20.2 on Debian bookworm segfaults

Post by marcidy »

On a whim i launched as root and that worked (albeit i needed QTWEBENGINE_DISABLE_SANDBOX=1) though there were a lot of Qt based errors.


QPainter::begin: Paint device returned engine == 0, type: 3
QPainter::setCompositionMode: Painter not active
QWidget::paintEngine: Should no longer be called
QPainter::begin: Paint device returned engine == 0, type: 1
QPainter::setRenderHint: Painter must be active to set rendering hints
QPainter::setPen: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 3
QPainter::setCompositionMode: Painter not active
QWidget::paintEngine: Should no longer be called
QPainter::begin: Paint device returned engine == 0, type: 1
QPainter::setRenderHint: Painter must be active to set rendering hints
QPainter::setPen: Painter not active
QXcbConnection: XCB error: 11 (BadAlloc), sequence: 477, resource id: 799, major code: 53 (CreatePixmap), minor code: 0

<snipped, see attached>

For clarity, the GUI came up and i was able to click around, use Part Design to create a padded sketch, and save the file. I think that acquits the graphics drivers.

For the record, this is an old laptop with Intel Integrated graphics:

00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)


I tried a fresh-installed Debian 11 and it still crashed. Which is odd, that worked before I upgraded to Debian 12. I have since fresh-installed Debian 12 again since that's my target.


I peppered some std::couts and print()s to attempt to trace where exactly it's crashing, but there is a redefinition of stdout and friends in Main/MainGui,cpp that I don't quite understand (yet), and that is interfering my attempt to deduce where it's crashing.
I undid the redefinitions of stdcout, but i suspect that caused a different crash in Gui/FreeCADGuiInit.py at the top level Log() call.

Any further hints appreciated. I attempted a debug build but couldn't launch the assembled binary, ill look at that again, I'd rather look at this in GDB.

I will keep poking, it's clearly a "me" issue, something weird with this machine but i can't tell what weirdness has survived over multiple OS installs (or what weirdness i had done previously which hasn't been done, etc).
Attachments
freecad-out.txt
Full output from launching freecad with sudo
(74.28 KiB) Downloaded 21 times
Post Reply