Need help, KDE Plasma + Debian 12 Stable are driving me crazy with blackscreens and errors

Haui111

Member
Joined
Jul 1, 2023
Messages
71
Reaction score
35
Credits
690
Since about 2 months, I switched from Ubuntu+Gnome to Debian+KDE. The installation was okay, wayland didnt work since I'm using an nvidia graphics card so I switched to X11 and all was fine... I had to tinker with a lot of games since debian 12 stable uses a rather old version of the proprietary nvidia driver.

But the inability to use hibernate bugged me so I investigated. I found out that Debian only preconfigures a 1 GB swap file (pretty tiny for my 32 GB ram system). So I made a 32 GB swap file on /.

I'm not totally sure that my problems started escalating then but since a couple of days, I'm experiencing rather odd behavior (black screen at boot, shutdown, reboot, still no hibernation, a lot of errors in journalctl)

To mitigate the issues and error messages I did the following things:
  • disabled bluetooth (which still enables itself, I suppose because I didnt mask it)
  • installed pipewire since debian/kde doesnt come with it but the error messages pointed at them
  • enabled wayland by using nvidia drm modeset=1, now at least wayland works but suspending/standby is now completely broken, I also cant change gamma using xrandr (obviously)

I'm rather stressed and I'm done trying random google finds since they aren't helping. Here's my setup:

System:
Code:
  Host: TowerPC Kernel: 6.1.0-18-amd64 arch: x86_64 bits: 64
Desktop: KDE Plasma v: 5.27.5 Distro: Debian GNU/Linux 12 (bookworm)
Machine:
Type: Desktop Mobo: ASUSTeK model: PRIME X299-A II v: Rev 1.xx
serial: <superuser required> BIOS: American Megatrends v: 0702
date: 06/10/2020
CPU:
Info: 12-core model: Intel Core i9-10920X bits: 64 type: MT MCP cache:
L2: 12 MiB
Speed (MHz): avg: 1203 min/max: 1200/4600:4800:4700 cores: 1: 1200 2: 1200
3: 1200 4: 1200 5: 1200 6: 1200 7: 1200 8: 1200 9: 1274 10: 1200 11: 1200
12: 1200 13: 1200 14: 1200 15: 1200 16: 1200 17: 1200 18: 1200 19: 1200
20: 1200 21: 1200 22: 1200 23: 1200 24: 1200
Graphics:
Device-1: NVIDIA GA104 [GeForce RTX 3060 Ti Lite Hash Rate] driver: nvidia
v: 525.147.05
Device-2: Logitech C920 PRO HD Webcam type: USB
driver: snd-usb-audio,uvcvideo
Display: wayland server: X.Org v: 1.22.1.9 with: Xwayland v: 22.1.9
compositor: kwin_wayland driver: X: loaded: nvidia
unloaded: fbdev,modesetting,nouveau,vesa gpu: nvidia,nvidia-nvswitch
resolution: 1920x1080~60Hz
API: OpenGL v: 4.6.0 NVIDIA 525.147.05 renderer: NVIDIA GeForce RTX 3060
    Ti/PCIe/SSE2
Audio:
Device-1: Intel 200 Series PCH HD Audio driver: snd_hda_intel
Device-2: NVIDIA GA104 High Definition Audio driver: snd_hda_intel
Device-3: ZOOM U-22 type: USB driver: snd-usb-audio
Device-4: Logitech C920 PRO HD Webcam type: USB
driver: snd-usb-audio,uvcvideo
API: ALSA v: k6.1.0-18-amd64 status: kernel-api
Server-1: PipeWire v: 0.3.65 status: active
Network:
Device-1: Intel Ethernet I219-V driver: e1000e
IF: eno1 state: up speed: 1000 Mbps duplex: full mac: f0:2f:74:1f:39:**
RAID:
Hardware-1: Intel SATA Controller [RAID mode] driver: ahci
Drives:
Local Storage: total: 2.69 TiB used: 386.71 GiB (14.0%)
ID-1: /dev/nvme0n1 vendor: Samsung model: SSD 970 EVO Plus 2TB
size: 1.82 TiB
ID-2: /dev/sda vendor: Kingston model: SA400S37960G size: 894.25 GiB
Partition:
ID-1: / size: 1.79 TiB used: 386.71 GiB (21.1%) fs: ext4 dev: /dev/nvme0n1p1
Swap:
ID-1: swap-1 type: file size: 32 GiB used: 0 KiB (0.0%)
file: /swapfile_extend_32GB
ID-2: swap-2 type: partition size: 976 MiB used: 0 KiB (0.0%)
dev: /dev/nvme0n1p5
Sensors:
System Temperatures: cpu: 36.0 C mobo: N/A
Fan Speeds (RPM): N/A
Info:
Processes: 362 Uptime: 19m Memory: 31.03 GiB used: 3.77 GiB (12.1%)
Shell: Bash inxi: 3.3.26

And attached is the journalctl from today, priority 4.

I tried googling for most of the issues but installing pipewire has done nothing but kill my sound and searching for "pmd_set_huge: Cannot satisfy" brought me to a mitigation advice that didnt work.

Can someone take a look and tell me how to go about solving this without going insane? Thanks a lot.
 

Attachments

  • journalctl_priority4_2024-03-08.txt
    59.4 KB · Views: 59


But the inability to use hibernate bugged me so I investigated. I found out that Debian only preconfigures a 1 GB swap file (pretty tiny for my 32 GB ram system).
To make hibernate work you need swap size of 1.5 x RAM, however this applies to up to 16GB RAM.
If you have more than 16GB then setting up swap for hibernation makes no sense because it would take a lot of disk space.
That is according to red hat docs (can't find link).

So I made a 32 GB swap file on /.
This is very likely your problem because swap should be a separate partition away from (/) root, I'm not sure how and why you mounted it to root partition?

enabled wayland by using nvidia drm modeset=1
It's not enough, it only makes wayland suck less but does not solve all the problems.
Just use X11 until wayland one day becomes fully fixed.
 
In order for hibernation to work properly you have to set a 'resume parameter' for your kernel.

 
To make hibernate work you need swap size of 1.5 x RAM, however this applies to up to 16GB RAM.
If you have more than 16GB then setting up swap for hibernation makes no sense because it would take a lot of disk space.
That is according to red hat docs (can't find link).


This is very likely your problem because swap should be a separate partition away from (/) root, I'm not sure how and why you mounted it to root partition?
Because that is what is suggested when you search for help on the internet nowadays. The amount of trash makes it impossible to know if the suggested fix is actually going to help and if your system starts having issues, searching for hours isnt always an option.


I cant find where they suggest adding more swap but that literally is what is being suggested.

Can you take a look at the log? I have no idea if the errors there are connected to the observed behavior.
 
In order for hibernation to work properly you have to set a 'resume parameter' for your kernel.

I dont understand. Do I need to manually set this since hibernation is already available, it just doesnt work.

Why is it that I always need to tinker with things on a stable system for them to work?

The comment before yours literally says I cant use a swap file while your link says I can use a swap file. Can anyone understand why I dont know what to do?
 
I cant find where they suggest adding more swap but that literally is what is being suggested.
That article is OK, however it does not create swap partition but swap file.

Please run the following command and share command output:

Code:
sudo cat /etc/fstab

edit:
And also this one:

Code:
free -h

---

Can you take a look at the log? I have no idea if the errors there are connected to the observed behavior.

xhci_hcd 0000:02:00.0: xHC error in resume, USBSTS 0x401, Reinit

Means the kernel is unable to restore USB devices, which could be due to misconfigured swap space.
 
Last edited:
That article is OK, however it does not create swap partition but swap file.

Please run the following command and share command output:

Code:
sudo cat /etc/fstab

UUID=57b817ee-f9f8-406d-a541-e2b9c9a2603b / ext4 errors=remount-ro 0 1
# swap was on /dev/nvme0n1p5 during installation
UUID=65afc5ac-889a-49d2-a536-ce06cfa7e4a5 none swap sw 0 0
/swapfile_extend_32GB none swap sw 0 0

edit:
And also this one:

Code:
free -h

---





Means the kernel is unable to restore USB devices, which could be due to misconfigured swap space.
gesamt benutzt frei gemns. Puffer/Cache verfügbar
Speicher: 31Gi 4,1Gi 23Gi 89Mi 3,7Gi 26Gi
Swap: 32Gi 0B 32Gi
 
@Haui111
I think your problem is that you're using swap file instead of swap partition.
Using swap file for hibernation might require some additional configuration but I can't give you any exact steps on this.

Another problem is that you have 2 swaps configured in fstab, even though only one is reported by free -h I suggest you to comment out old swap partition in /etc/fstab and then reboot system.

Comment out the line which says UUID=65afc5ac-889a-49d2-a536-ce06cfa7e4a5 none swap sw 0 0 and save.

After reboot try hibernating and let us know if this worked.
 
Because that is what is suggested when you search for help on the internet nowadays.
I use ChatGPT for the technical stuff instead of google. You might need to break your problem down or rephrase a few times but you might have better luck.
 
I'll weighin here also. My guess is that nvidia is still the problem If it were me for now anyway I'd go back to X11 instead of Wayland. Wayland as far as it has come is still not ready for prime time especially with nvidia cards. Just a suggestion.

But this is why Distros like Kubuntu and ohters have not defaulted to Wayland yet.
Or perhaps I should put it this way. Nvidia has not caught up with Wayland yet.
 
Last edited:
@Haui111
I think your problem is that you're using swap file instead of swap partition.
Using swap file for hibernation might require some additional configuration but I can't give you any exact steps on this.

Another problem is that you have 2 swaps configured in fstab, even though only one is reported by free -h I suggest you to comment out old swap partition in /etc/fstab and then reboot system.

Comment out the line which says UUID=65afc5ac-889a-49d2-a536-ce06cfa7e4a5 none swap sw 0 0 and save.

After reboot try hibernating and let us know if this worked.
I did as you asked. Thanks for helping btw! :)

Sadly, it didnt work but it confirms the initial idea that a swap file is not sufficient I guess. Now the plasma start menu does not have a hibernate function anymore and if I use systemctl hibernate it says
Call to Hibernate failed: Not enough swap space for hibernation

So far so good. I dont use lvm so changing the swap partition is not going to be easy since everything else is taken by the main partition.

Here's what the log looks like now:

Mär 09 12:41:18 TowerPC kernel: MMIO Stale Data CPU bug present and SMT on, data leak possible. See https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/processor_mmio_stale_data.html for more details.
Code:
Mär 09 12:41:18 TowerPC kernel:  #13 #14 #15 #16 #17 #18 #19 #20 #21 #22 #23
Mär 09 12:41:18 TowerPC kernel: pmd_set_huge: Cannot satisfy [mem 0x60000000-0x60200000] with a huge-page mapping due to MTRR override.
Mär 09 12:41:18 TowerPC kernel: ENERGY_PERF_BIAS: Set to 'normal', was 'performance'
Mär 09 12:41:18 TowerPC kernel: i2c i2c-1: Systems with more than 4 memory slots not supported yet, not instantiating SPD
Mär 09 12:41:18 TowerPC kernel: usb: port power management may be unreliable
Mär 09 12:41:18 TowerPC kernel: device-mapper: core: CONFIG_IMA_DISABLE_HTABLE is disabled. Duplicate IMA measurements will not be recorded in the IMA log.
Mär 09 12:41:18 TowerPC kernel: nvidia: loading out-of-tree module taints kernel.
Mär 09 12:41:18 TowerPC kernel: nvidia: module license 'NVIDIA' taints kernel.
Mär 09 12:41:18 TowerPC kernel: Disabling lock debugging due to kernel taint
Mär 09 12:41:19 TowerPC kernel:  
Mär 09 12:41:19 TowerPC kernel: NVRM: loading NVIDIA UNIX x86_64 Kernel Module  525.147.05  Wed Oct 25 20:27:35 UTC 2023
Mär 09 12:41:19 TowerPC kernel: EDAC skx: ECC is disabled on imc 1
Mär 09 12:41:21 TowerPC udisksd[912]: failed to load module mdraid: libbd_mdraid.so.2: cannot open shared object file: No such file or directory
Mär 09 12:41:21 TowerPC udisksd[912]: Failed to load the 'mdraid' libblockdev plugin
Mär 09 12:41:21 TowerPC kernel: kauditd_printk_skb: 14 callbacks suppressed
Mär 09 12:41:21 TowerPC kernel: VBoxNetFlt: Successfully started.
Mär 09 12:41:21 TowerPC kernel: VBoxNetAdp: Successfully started.
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: QFont::fromString: Invalid description '(empty)'
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/VirtualKeyboard.qml:28:1: Type InputPanel unavailable
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: qrc:/QtQuick/VirtualKeyboard/content/InputPanel.qml:138:5: Type Keyboard unavailable
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: qrc:/QtQuick/VirtualKeyboard/content/components/Keyboard.qml:38:1: module "QtQuick.VirtualKeyboard.Plugins" is not installed
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/Input.qml:561:5: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onF>
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SessionButton.qml:38:5: Unable to assign ComboBox_QMLTYPE_4 to Control_QMLTYPE_8
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:24 TowerPC sddm-greeter[1242]: file:///usr/share/sddm/themes/sugar-candy/Components/SystemButtons.qml:70:13: Unable to assign [undefined] to QQuickItem*
Mär 09 12:41:26 TowerPC pulseaudio[1241]: GetManagedObjects() failed: org.freedesktop.systemd1.NoSuchUnit: Unit dbus-org.bluez.service not found.
Mär 09 12:41:30 TowerPC sddm-helper[1295]: gkr-pam: unable to locate daemon control file
Mär 09 12:41:31 TowerPC pulseaudio[1314]: GetManagedObjects() failed: org.freedesktop.systemd1.NoSuchUnit: Unit dbus-org.bluez.service not found.
Mär 09 12:41:33 TowerPC org.kde.powerdevil.backlighthelper[1528]: org.kde.powerdevil: no kernel backlight interface found
Mär 09 12:41:34 TowerPC xdg-desktop-por[1759]: Failed connect to PipeWire: Couldn't connect to PipeWire
Mär 09 12:42:24 TowerPC utempter[2282]: [ppid=2257] cannot find slave pty: Inappropriate ioctl for device
 
I use ChatGPT for the technical stuff instead of google. You might need to break your problem down or rephrase a few times but you might have better luck.
Thank you very much! I tried that before but I guess I could do so again, especially before I burden human helpers. :)
 
I'll weighin here also. My guess is that nvidia is still the problem If it were me for now anyway I'd go back to X11 instead of Wayland. Wayland as far as it has come is still not ready for prime time especially with nvidia cards. Just a suggestion.

But this is why Distros like Kubuntu and ohters have not defaulted to Wayland yet.
Or perhaps I should put it this way. Nvidia has not caught up with Wayland yet.
My personal opinion is that nvidia should just not be used if anyone can help it but maybe thats just me. I will consider going back to X11. Thank you very much for replying. I appreciate you taking the time. :)
 
Thank you very much! I tried that before but I guess I could do so again, especially before I burden human helpers. :)
I like reading about and learning from other peoples' challenges. I just meant that ai could help more than web searches (in some cases).. in some cases ai is useless aswell
 
Sadly, it didnt work but it confirms the initial idea that a swap file is not sufficient I guess. Now the plasma start menu does not have a hibernate function anymore and if I use systemctl hibernate it says
Call to Hibernate failed: Not enough swap space for hibernation
Suggested amount of swap space is 1.5 x RAM so 32 x 1.5 = 48G
Try that and it should work.

Alternatively...

I dont use lvm so changing the swap partition is not going to be easy since everything else is taken by the main partition.
It's not that hard either, the procedure is:
1. shrink root partition
2. delete swap partition
3. recreate swap partition by available free space

root partition must be shrinked by amount needed minus current swap partition size.
You need 48G swap but current swap is 1G, so shrink it by 48 - 1 = 47G

But before you shrink it you first need to shrink file system to avoid data loss.
then after it's shrinked you need to resize file system to consume new space.

Unless I'm wrong, problem is also that you'll need to do this from live USB because file system should be unmounted,
there are methods to do it while it's mounted but I've never done it.

Keep in mind that things can go wrong so you need to be careful, if you need steps for this let me know.

---

Alternatively you can google out on how to make swap file work with hibernation.
 
If you are new to Linux Hau111 it would easier to perform a fresh installation.
That way if your not well equated with g-parted or the partition manager that comes with the Debian installer the ease will be lighter on your part.
Unless you are in a dual boot with another operating system, then that changes everything. Learning proper partitioning is a skill and like you said time isn't something we all have.

Kernel tainted means that it is in a state that is not supported by the community.

I'm still in the process of reading the journalctl_priority4 file you attached in your first post.:)

If you decide to perform a fresh installation or manipulate the partitions you already have and still have the black screen at boot time among all the other issues......I strongly suggest that you set a 'resume parameter' for your kernel.

Code:
 Resuming from hibernation works by telling the kernel to try resuming from a swap partition, using the resume= kernel argument, resume=/dev/sda4 (if /dev/sda4 is your swap partition), resume=UUID=deadbeef-cafe-b00b-1337-123456123456 or similar.

See post #3 for those instructions and the link.

I completely agree with our member kc1di, returning to X11 is best.
My Debian 12 Gnome install failed in functionality and became unresponsive under Wayland.
It would work for a few minutes and very quickly lag behind until the desktop, mouse, and the like would lock up and fail.
 
I dont understand. Do I need to manually set this since hibernation is already available, it just doesnt work.

Why is it that I always need to tinker with things on a stable system for them to work?

The comment before yours literally says I cant use a swap file while your link says I can use a swap file. Can anyone understand why I dont know what to do?
I've never used a swap file and I have reason's for that.

Not everything in that article is wisdom. Learning how to manipulate, tweak, customize and re-arange a Linux system takes years.
In 10 plus years I have had success with either using 'g-parted Live' or the 'partition manager' that comes with the distro that the installer communicates with.
I dont understand. Do I need to manually set this since hibernation is already available, it just doesnt work.

Why is it that I always need to tinker with things on a stable system for them to work?

The comment before yours literally says I cant use a swap file while your link says I can use a swap file. Can anyone understand why I dont know what to do?
Yes, you need to manually set the parameter for the kernel.
However, before you do that you need to undue the argument that you enabled wayland by using nvidia drm modeset=1:-

The reason why you and others have to tinker with things on a stable system is because developers can't make customization's and such adjustment in the code for a one size fits all.
 
Sorry for the late reply. I've been insanely busy for some time. So I changed the swap file to 32 GB and disabled the swap partition. Now hibernation isnt even available anymore. So the "shrink partition" way is probably the only one that makes sense now. It's terribly important rn but it is something I will try at some point

If you are new to Linux Hau111 it would easier to perform a fresh installation.
That way if your not well equated with g-parted or the partition manager that comes with the Debian installer the ease will be lighter on your part.

I'm not new to linux as a whole. I run a home server for 2+ yrs now and am an admin irl. But desktop linux is still quite new to me. I dont like reinstalls unless I really have to.

So I fixed the blackscreens. I went to wayland, which made the problem worse and back to X11, then inserted modeset=1 in the grub (I dont remember the command but I suppose you know what I'm talking about) and now most of it works well.

The amount of issues in my log feels a lot smaller now. I also installed pkexec which took care of a window in timeshift that didnt want to function and didnt want to close either.

So far I'm pretty caught up. Thanks again.
 
Sorry for the late reply. I've been insanely busy for some time. So I changed the swap file to 32 GB and disabled the swap partition. Now hibernation isnt even available anymore. So the "shrink partition" way is probably the only one that makes sense now. It's terribly important rn but it is something I will try at some point



I'm not new to linux as a whole. I run a home server for 2+ yrs now and am an admin irl. But desktop linux is still quite new to me. I dont like reinstalls unless I really have to.

So I fixed the blackscreens. I went to wayland, which made the problem worse and back to X11, then inserted modeset=1 in the grub (I dont remember the command but I suppose you know what I'm talking about) and now most of it works well.

The amount of issues in my log feels a lot smaller now. I also installed pkexec which took care of a window in timeshift that didnt want to function and didnt want to close either.

So far I'm pretty caught up. Thanks again.
Thanks for the update.
I'm glad to hear that adding modeset=1 to grub helped.
 

Members online


Latest posts

Top