darktable-org / darktable

darktable is an open source photography workflow application and raw developer
https://www.darktable.org
GNU General Public License v3.0
9.69k stars 1.14k forks source link

Darktable crashes when monitor awakened from sleep #14850

Closed kasav81 closed 1 year ago

kasav81 commented 1 year ago

Describe the bug

I'm using darktable-4.4.1 on Gentoo, when editing pictures I haven't experienced a crash until now, I hardly ever edit for longer than one hour though. But almost every time I take a break and leave darktable running, when I return darktable has crashed. I tried with a completely new config, with only one image in the db, with --disable-opencl and as a different user, as a last resort I have recompiled darktable with all its dependencies but the problem persists.

darktable_bt_MWXR71.txt

gdb output

gdb_darktable.txt

Steps to reproduce

Open darktable Leave it alone for some time (maybe an hour or two), doesn't matter if I have edited something before or just opened it On waking up the monitor darktable has crashed

Expected behavior

darktable should run until I close it

Logfile | Screenshot | Screencast

No response

Commit

No response

Where did you install darktable from?

distro packaging

darktable version

4.4.1

What OS are you using?

Linux

What is the version of your OS?

Gentoo

Describe your system?

emerge --info output:

Portage 3.0.46 (python 3.11.4-final-0, default/linux/amd64/17.1/desktop/plasma/systemd/merged-usr, gcc-12, glibc-2.37-r3, 6.1.38-gentoo-dist x86_64)
=================================================================
System uname: Linux-6.1.38-gentoo-dist-x86_64-13th_Gen_Intel-R-_Core-TM-_i7-13700-with-glibc2.37
KiB Mem:    65535972 total,  54774712 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Sat, 08 Jul 2023 06:16:46 +0000
Head commit of repository gentoo: 8031e99ab564fd7d36a700c172ec1be47b6a4b18

Timestamp of repository guru: Sat, 08 Jul 2023 02:46:43 +0000
Head commit of repository guru: c7b094323e3f4aecf09b2700b16430847ac55dec

Timestamp of repository kzd: Sat, 08 Jul 2023 01:31:44 +0000
Head commit of repository kzd: 7a3a894b3aaeafdd33ebf6542ed91eca65f4fd9d

Timestamp of repository monero: Tue, 26 Jul 2022 05:02:30 +0000
Head commit of repository monero: f09efc008db5f08668b8341baba0d46b8488e3cd

Timestamp of repository src_prepare-overlay: Thu, 06 Jul 2023 17:46:57 +0000
Head commit of repository src_prepare-overlay: 32ddc1244082c92eac6f4c707be23086c11366e9

Timestamp of repository steam-overlay: Sun, 02 Jul 2023 15:32:30 +0000
Head commit of repository steam-overlay: 301e948a8983d54430c42621a58c8c9ccdc6231c

Timestamp of repository stefantalpalaru: Thu, 06 Jul 2023 12:16:52 +0000
Head commit of repository stefantalpalaru: 3a2939cd31a9d1f434f71d9636d725c61e6f77e0

Timestamp of repository waffle-builds: Sun, 02 Jul 2023 15:32:42 +0000
Head commit of repository waffle-builds: 94661a646504f0c7a0855e727ffae4bcd64fafb6

sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.40 p5) 2.40.0
app-misc/pax-utils:        1.3.5::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-java/java-config:      2.3.1-r1::gentoo
dev-lang/perl:             5.36.1-r2::gentoo
dev-lang/python:           2.7.18_p16-r1::gentoo, 3.10.12::gentoo, 3.11.4::gentoo
dev-lang/rust:             1.69.0-r1::gentoo
dev-util/cmake:            3.26.4-r1::gentoo
dev-util/meson:            1.1.1::gentoo
sys-apps/baselayout:       2.13-r1::gentoo
sys-apps/sandbox:          2.32::gentoo
sys-apps/systemd:          253.3-r1::gentoo
sys-devel/autoconf:        2.71-r6::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.40-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           14.0.6-r1::gentoo, 15.0.7-r1::gentoo, 16.0.5::gentoo
sys-devel/gcc:             12.3.1_p20230526::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/lld:             15.0.7::gentoo
sys-devel/llvm:            14.0.6-r4::gentoo, 15.0.7-r3::gentoo, 16.0.5::gentoo
sys-devel/make:            4.4.1-r1::gentoo
sys-kernel/linux-headers:  6.1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.37-r3::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/gentoo.git
    priority: -1000
    volatile: True

guru
    location: /var/db/repos/guru
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/guru.git
    masters: gentoo
    volatile: False

kzd
    location: /var/db/repos/kzd
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/kzd.git
    masters: gentoo steam-overlay
    volatile: False

localrepo
    location: /usr/local/local_overlay
    masters: gentoo
    volatile: True

monero
    location: /var/db/repos/monero
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/monero.git
    masters: gentoo
    volatile: False

src_prepare-overlay
    location: /var/db/repos/src_prepare-overlay
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/src_prepare-overlay.git
    masters: gentoo
    volatile: False

steam-overlay
    location: /var/db/repos/steam-overlay
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/steam-overlay.git
    masters: gentoo
    volatile: False

stefantalpalaru
    location: /var/db/repos/stefantalpalaru
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/stefantalpalaru.git
    masters: gentoo
    volatile: False

waffle-builds
    location: /var/db/repos/waffle-builds
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/waffle-builds.git
    masters: gentoo
    volatile: False

Installed sets: @looking-glass
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.9/conf /usr/share/themes/oxygen-gtk/gtk-2.0"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
LINGUAS="de en"
MAKEOPTS="-j16"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac aacs acl acpi activities alsa alsa-plugin amd64 argyllcms avahi bdplus bluetooth bluray branding bzip2 cairo calculator calendar cdda cddb cdr cli color-management colord crypt cups dbus declarative discover discovery dist-kernel dri dts dvd dvdr encode exif face facedetect ffmpeg fftw flac flatpak fortran frei0r gallium gcj gdbm gif gimp gl glamor gnome-online-accounts googledrive gphoto2 gpm graphite gstreamer gtk gui gusb haptic heif iconv icq icu infinality initramfs ipv6 ithreads java javafx javamail javascript jpeg jpeg2k kde kdesu kwallet lapack lcms legacy-systray lensfun libkms libnotify libtirpc logitech mad mbim mdnsresponder-compat mediaplayer mng modemmanager mp3 mp4 mpeg mtp multilib multimedia musicbrainz ncurses networkmanager nls nptl nvenc nvidia ogg opencl opencv openexr opengl openh264 openmp openssl opus pam pango pcre pdf perl pipewire plasma png policykit ppds printsupport pulseaudio qmi qmimodem qml qt5 qtaudio qtmedia raw readline samba screencast scripts sdl seccomp semantic-desktop sound speex spell spice ssl startup-notification svg systemd tcl test-rust theora threads tiff timezone tk truetype tty-helpers udev udisks unicode upower usb usbredir utils v4l vaapi vdpau vorbis vpx vulkan wayland webdav webp widgets wxwidgets x11extras x264 x265 xa xattr xcb xft xml xrandr xv xvid yahoo zeroconf zlib" ABI_X86="64 32" ADA_TARGET="gnat_2021" AMDGPU_TARGETS="gfx1030 gfx1031" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt rdrand sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="emu efi-64 pc" INPUT_DEVICES="evdev wacom" KERNEL="linux" L10N="de en" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11 python3_10" RUBY_TARGETS="ruby31" VIDEO_CARDS="intel i965 iris nvidia amdgpu radeonsi" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS

Are you using OpenCL GPU in darktable?

Yes

If yes, what is the GPU card and driver?

x11-drivers/nvidia-drivers-525.125.06 dev-libs/intel-compute-runtime-23.17.26241.15 and latest mesa with rusticl for an AMD card with radeonsi-driver

Please provide additional context if applicable. You can attach files too, but might need to rename to .txt or .zip

No response

jenshannoschwalm commented 1 year ago
  1. Does your single image have a size of 1x1 pixels?
  2. Doesn't sound like a dt problem at all for me.
kasav81 commented 1 year ago

Do you mean the dimension of the image? It was a normal RAW-File from a Pentax K3. If it is not darktable, do you have any idea where I should look further because the rest of the system does run stable so I am out of ideas? Thanks

jenshannoschwalm commented 1 year ago

I suspect the pretty new driver for your amd card. There have been so many issues around.

Running stable?

  1. Could be powerd problems with dis/re-enabling a card. Some time ago we had such issues with nvidia ...
  2. Stable running OpenCL apps on a specific device?
  3. You seem to have opencl compiled in, so a log with -d common might be helping here.
  4. About the image, i stumbled across the lines
    1293.5186 [rawprepare] got wrong crop parameters left=0, right=0, top=0, bottom=0 for size=1x1
    1293.5186 Trouble: [Raw-Schwarz-/Weißpunkt] invalid crop parameters (empty-pixel.png 17)
    1293.5212 [rawprepare] got wrong crop parameters left=0, right=0, top=0, bottom=0 for size=1x1
    1293.5212 Trouble: [Raw-Schwarz-/Weißpunkt] invalid crop parameters (empty-pixel.png 655)
kasav81 commented 1 year ago

The logs were acquired using my standard config with the db containing my whole ~/Pictures folder, the empty-pixel.png 1x1 files must be some left-overs from long ago, but it also happened using a new configdir and just one Pentax DNG file and even with opencl disabled using the --disable-opencl option. As the crashes always happen after the monitor has been turned off and woken up again I tried disabling monitor power management and darktable hasn't crashed so far, so I suppose you are right, it seems it hasn't got anything to do with darktable but with power management, which also explains why I never had a crash while editing. Thanks a lot for your help & time!

jenshannoschwalm commented 1 year ago

Using X11 or Wayland?

kasav81 commented 1 year ago

X11

kasav81 commented 1 year ago

Tried under wayland, the display went to sleep and was woken up again several times so that I already believed the crash wouln't happen but after approximately 1h45min darktable crashed under wayland as well...