Manjaro KDE screen freezes when closing laptop

Hello, another n00b post. I’ve read over 30 posts regarding Manjaro screen freezing when you close the laptop/put into sleep mode. I thought I fixed it because it seemed to stop freezing when I manually locked the screen but if I close it with an app/program still open it will still freeze. I can interact with the app that was open to a limited degree (like typing in a text box or scrolling) but I wont be able to do anything else and the background will typically be completely black. Before closing the screen I’ve tried executing kernel.sysrq=1 | sudotee --append /etc/ sysctl.d/99-sysctl.conf and sudo update-grub then rebooted and waited for the next screen freeze. I tried Fn+Alt+PrtSc, Alt+PrtSc, Alt Gr+PrtSc, Ctrl+Alt+PrtSc, I’ve also made sure to press Alt and let go of SysRq before/while pressing the buttons and waiting at least 6 seconds in between.
I hope this has all the info you need. What is the next step to fixing my annoying locking screen issue?

  Kernel: 6.12.44-3-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 15.2.1
    clocksource: tsc avail: acpi_pm
    parameters: BOOT_IMAGE=/boot/vmlinuz-6.12-x86_64
    root=UUID=2979bd53-c696-4820-89b9-d90256648b8a rw quiet
    cryptdevice=UUID=8f4dc640-d29a-44d6-b91e-3b5abaccd9ee:luks-8f4dc640-d29a-44d6-b91e-3b5abaccd9ee
    root=/dev/mapper/luks-8f4dc640-d29a-44d6-b91e-3b5abaccd9ee splash
    udev.log_priority=3
  Desktop: KDE Plasma v: 6.3.6 tk: Qt v: N/A info: frameworks v: 6.17.0
    wm: kwin_x11 vt: 2 dm: SDDM Distro: Manjaro base: Arch Linux
Machine:
  Type: Laptop System: LENOVO product: 21DH v: ThinkBook 14 G4 IAP
    serial: <superuser required> Chassis: type: 10 v: ThinkBook 14 G4 IAP
    serial: <superuser required>
  Mobo: LENOVO model: LNVNB161216 v: SDK0T76530 WIN
    serial: <superuser required> part-nu: LENOVO_MT_21DH_BU_idea_FM_ThinkBook 14
    G4 IAP uuid: <superuser required> UEFI: LENOVO v: JFCN27WW(V1.05)
    date: 04/21/2022
Battery:
  ID-1: BAT1 charge: 5.7 Wh (14%) condition: 40.7/45 Wh (90.4%) power: 7.9 W
    volts: 10.81 min: 11.52 model: Celxpert L19C3PDA type: Li-ion
    serial: <filter> charging: status: discharging cycles: 112
CPU:
  Info: model: 12th Gen Intel Core i7-1255U bits: 64 type: MST AMCP
    arch: Alder Lake level: v3 note: check built: 2021+
    process: Intel 7 (10nm ESF) family: 6 model-id: 0x9A (154) stepping: 4
    microcode: 0x437
  Topology: cpus: 1x dies: 1 clusters: 4 cores: 10 threads: 12 mt: 2 tpc: 2
    st: 8 smt: enabled cache: L1: 928 KiB desc: d-8x32 KiB, 2x48 KiB; i-2x32
    KiB, 8x64 KiB L2: 6.5 MiB desc: 2x1.2 MiB, 2x2 MiB L3: 12 MiB
    desc: 1x12 MiB
  Speed (MHz): avg: 400 min/max: 400/4700:3500 scaling: driver: intel_pstate
    governor: powersave cores: 1: 400 2: 400 3: 400 4: 400 5: 400 6: 400 7: 400
    8: 400 9: 400 10: 400 11: 400 12: 400 bogomips: 62688
  Flags-basic: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: gather_data_sampling status: Not affected
  Type: indirect_target_selection status: Not affected
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data status: Not affected
  Type: reg_file_data_sampling mitigation: Clear Register File
  Type: retbleed status: Not affected
  Type: spec_rstack_overflow status: Not affected
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via
    prctl
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer
    sanitization
  Type: spectre_v2 mitigation: Enhanced / Automatic IBRS; IBPB: conditional;
    PBRSB-eIBRS: SW sequence; BHI: BHI_DIS_S
  Type: srbds status: Not affected
  Type: tsa status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel Alder Lake-UP3 GT2 [Iris Xe Graphics] vendor: Lenovo
    driver: i915 v: kernel alternate: xe arch: Xe process: Intel 10nm
    built: 2021-22+ ports: active: eDP-1 empty: DP-1,DP-2,HDMI-A-1
    bus-ID: 00:02.0 chip-ID: 8086:46a8 class-ID: 0300
  Device-2: Luxvisions Innotech Integrated Camera driver: uvcvideo type: USB
    rev: 2.0 speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 3-5:2 chip-ID: 30c9:0030
    class-ID: 0e02 serial: <filter>
  Display: x11 server: X.Org v: 21.1.18 with: Xwayland v: 24.1.8
    compositor: kwin_x11 driver: X: loaded: modesetting alternate: fbdev,vesa
    dri: iris gpu: i915 display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.00x11.22")
    s-diag: 582mm (22.93")
  Monitor-1: eDP-1 model: AU Optronics 0x323d built: 2018 res:
    mode: 1920x1080 hz: 60 scale: 100% (1) dpi: 158 gamma: 1.2
    size: 309x174mm (12.17x6.85") diag: 355mm (14") ratio: 16:9
    modes: 1920x1080
  API: EGL v: 1.5 hw: drv: intel iris platforms: device: 0 drv: iris
    device: 1 drv: swrast gbm: drv: iris surfaceless: drv: iris x11: drv: iris
    inactive: wayland
  API: OpenGL v: 4.6 compat-v: 4.5 vendor: intel mesa v: 25.2.1-arch1.4
    glx-v: 1.4 direct-render: yes renderer: Mesa Intel Iris Xe Graphics (ADL GT2)
    device-ID: 8086:46a8 memory: 14.99 GiB unified: yes
  API: Vulkan v: 1.4.321 layers: 4 device: 0 type: integrated-gpu name: Intel
    Iris Xe Graphics (ADL GT2) driver: mesa intel v: 25.2.1-arch1.4
    device-ID: 8086:46a8 surfaces: N/A
  Info: Tools: api: clinfo, eglinfo, glxinfo, vulkaninfo
    de: kscreen-console,kscreen-doctor wl: wayland-info
    x11: xdpyinfo, xprop, xrandr
Audio:
  Device-1: Intel Alder Lake PCH-P High Definition Audio vendor: Lenovo
    driver: snd_hda_intel v: kernel alternate: snd_soc_avs,snd_sof_pci_intel_tgl
    bus-ID: 00:1f.3 chip-ID: 8086:51c8 class-ID: 0403
  API: ALSA v: k6.12.44-3-MANJARO status: kernel-api with: aoss
    type: oss-emulator tools: alsactl,alsamixer,amixer
  Server-1: JACK v: 1.9.22 status: off tools: N/A
  Server-2: PipeWire v: 1.4.7 status: active with: 1: pipewire-pulse
    status: active 2: wireplumber status: active 3: pipewire-alsa type: plugin
    tools: pactl,pw-cat,pw-cli,wpctl
Network:
  Device-1: Intel Alder Lake-P PCH CNVi WiFi driver: iwlwifi v: kernel
    bus-ID: 00:14.3 chip-ID: 8086:51f0 class-ID: 0280
  IF: wlp0s20f3 state: up mac: <filter>
  Device-2: Intel Ethernet I219-V vendor: Lenovo driver: e1000e v: kernel
    port: N/A bus-ID: 00:1f.6 chip-ID: 8086:1a1f class-ID: 0200
  IF: enp0s31f6 state: down mac: <filter>
  Info: services: NetworkManager, systemd-timesyncd, wpa_supplicant
Bluetooth:
  Device-1: Intel AX201 Bluetooth driver: btusb v: 0.8 type: USB rev: 2.0
    speed: 12 Mb/s lanes: 1 mode: 1.1 bus-ID: 3-10:4 chip-ID: 8087:0026
    class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 2 state: up address: see --recommends
Drives:
  Local Storage: total: 476.94 GiB used: 54.35 GiB (11.4%)
  SMART Message: Required tool smartctl not installed. Check --recommends
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung model: MZALQ512HBLU-00BL2
    size: 476.94 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
    lanes: 4 tech: SSD serial: <filter> fw-rev: 7L2QFXM7 temp: 31.9 C
    scheme: GPT
Partition:
  ID-1: / raw-size: 100 GiB size: 97.87 GiB (97.87%) used: 21.59 GiB (22.1%)
    fs: ext4 dev: /dev/dm-0 maj-min: 254:0
    mapped: luks-8f4dc640-d29a-44d6-b91e-3b5abaccd9ee
  ID-2: /boot/efi raw-size: 1024 MiB size: 1022 MiB (99.80%)
    used: 536 KiB (0.1%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
  ID-3: /home raw-size: 375.94 GiB size: 368.97 GiB (98.15%)
    used: 32.76 GiB (8.9%) fs: ext4 dev: /dev/dm-1 maj-min: 254:1
    mapped: luks-ce7198fc-e884-4e13-a9d7-7b1be3656b57
Swap:
  Alert: No swap data was found.
Sensors:
  System Temperatures: cpu: 37.0 C mobo: N/A
  Fan Speeds (rpm): N/A
Info:
  Memory: total: 16 GiB note: est. available: 15.35 GiB used: 2.77 GiB (18.1%)
  Processes: 285 Power: uptime: 14m states: freeze,mem,disk suspend: s2idle
    avail: deep wakeups: 0 hibernate: platform avail: shutdown, reboot, suspend,
    test_resume image: 6.12 GiB services: org_kde_powerdevil,
    power-profiles-daemon, upowerd Init: systemd v: 257 default: graphical
    tool: systemctl
  Packages: pm: pacman pkgs: 1361 libs: 377 tools: pamac,yay pm: flatpak
    pkgs: 0 Compilers: clang: 20.1.8 gcc: 15.2.1 Shell: Zsh v: 5.9
    running-in: konsole inxi: 3.3.39```

Welcome the Manjaro community @galyxy

First, please don’t start multiple support topics for the same issue. Your duplicate topic has been closed.

Is that the actual command you ran? If it is, it won’t work as there are two typos in it: you are missing echo at the start, and also need a space between sudo & tee. The correct command would be:

echo kernel.sysrq=1 | sudo tee --append /etc/sysctl.d/99-sysctl.conf

If you want to check if the changes were written to the /etc/sysctl.d/99-sysctl.conf file, you can view its contents by running the following command:

cat /etc/sysctl.d/99-sysctl.conf

Have you tested to see if the issue also occurs in a Plasma Wayland session?

You can change your Plasma session from X11 to Wayland by selecting the session type at the login screen (Wayland is now KDE’s default for Plasma).

If you have set up autologin to skip the password screen, you can change to a Wayland session by opening System Settings → Colors & Themes → Login Screen (SDDM) → Behavior.