KDE freezes randomly + graphical glitches

I've been having this issue lately where the desktop locks up but the PC keeps functioning, I can keep listening to whatever audio was playing and friends on voip can hear me, another strange thing is that sometimes it's not a full freeze, in some instances I can keep scrolling through chats and browser windows but trying to open new windows or pulling up the menu doesn't work, other times it's a complete freeze and nothing works.
The only way I can get the desktop back is by CTRL+ALT+BACKSPACE and logging back in.

Another, perhaps unrelated, problem is that I'm having random glitches in the UI like in the following image:
Screenshot_20200508_093318
These glitches don't happen all the time and rebooting can fix it.

I have no clue on how to fix this so any suggestion is welcome.

Please read this:


and post some more information so we can see what's really going on. Now we know the symptom of the disease, but we need some more probing to know where the origin lies...

:innocent:

P.S. If you enter a bit more details in your profile, we can also see which Desktop Environment you're using, which CPU/GPU you have, ...

The following is the output of
inxi --full --verbosity=7 --filter --no-host

System:    Kernel: 5.6.11-1-MANJARO x86_64 bits: 64 compiler: gcc v: 9.3.0 Desktop: KDE Plasma 5.18.5 tk: Qt 5.14.2 
           wm: kwin_x11 dm: SDDM Distro: Manjaro Linux 
Machine:   Type: Desktop System: Gigabyte product: Z170XP-SLI v: N/A serial: <filter> 
           Mobo: Gigabyte model: Z170XP-SLI-CF v: x.x serial: <filter> UEFI: American Megatrends v: F22f date: 03/09/2018 
Memory:    RAM: total: 15.60 GiB used: 5.33 GiB (34.2%) 
           RAM Report: permissions: Unable to run dmidecode. Root privileges required. 
CPU:       Topology: Quad Core model: Intel Core i5-6600K bits: 64 type: MCP arch: Skylake-S rev: 3 L2 cache: 6144 KiB 
           bogomips: 28009 
           Speed: 800 MHz min/max: 800/3900 MHz Core speeds (MHz): 1: 800 2: 800 3: 800 4: 800 
           Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat arch_perfmon art avx avx2 bmi1 bmi2 bts clflush 
           clflushopt cmov constant_tsc cpuid cpuid_fault cx16 cx8 de ds_cpl dtes64 dtherm dts ept ept_ad erms est f16c 
           flexpriority flush_l1d fma fpu fsgsbase fxsr hle ht hwp hwp_act_window hwp_epp hwp_notify ibpb ibrs ida intel_pt 
           invpcid invpcid_single lahf_lm lm mca mce md_clear mmx monitor movbe mpx msr mtrr nonstop_tsc nopl nx pae pat pbe 
           pcid pclmulqdq pdcm pdpe1gb pebs pge pln pni popcnt pse pse36 pti pts rdrand rdseed rdtscp rep_good rtm sdbg sep 
           smap smep ss ssbd sse sse2 sse4_1 sse4_2 ssse3 stibp syscall tm tm2 tpr_shadow tsc tsc_adjust tsc_deadline_timer 
           vme vmx vnmi vpid x2apic xgetbv1 xsave xsavec xsaveopt xsaves xtopology xtpr 
Graphics:  Device-1: Advanced Micro Devices [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X/590] 
           vendor: Sapphire Limited Nitro+ driver: amdgpu v: kernel bus ID: 01:00.0 chip ID: 1002:67df 
           Display: x11 server: X.Org 1.20.8 driver: amdgpu FAILED: ati unloaded: modesetting alternate: fbdev,vesa 
           compositor: kwin_x11 tty: N/A 
           OpenGL: renderer: Radeon RX 590 Series (POLARIS10 DRM 3.36.0 5.6.11-1-MANJARO LLVM 10.0.0) 
           v: 4.6 Mesa 20.1.0-rc1 (git-3968b9381f) direct render: Yes 
Audio:     Device-1: Intel 100 Series/C230 Series Family HD Audio vendor: Gigabyte driver: snd_hda_intel v: kernel 
           bus ID: 00:1f.3 chip ID: 8086:a170 
           Device-2: AMD Ellesmere HDMI Audio [Radeon RX 470/480 / 570/580/590] vendor: Sapphire Limited driver: snd_hda_intel 
           v: kernel bus ID: 01:00.1 chip ID: 1002:aaf0 
           Sound Server: ALSA v: k5.6.11-1-MANJARO 
Network:   Device-1: Intel Ethernet I219-V vendor: Gigabyte driver: e1000e v: 3.2.6-k port: f000 bus ID: 00:1f.6 
           chip ID: 8086:15b8 
           IF: enp0s31f6 state: up speed: 1000 Mbps duplex: full mac: <filter> 
           IP v4: <filter> type: noprefixroute scope: global broadcast: <filter> 
           IP v6: <filter> type: noprefixroute scope: link 
           WAN IP: <filter> 
Drives:    Local Storage: total: 2.76 TiB used: 1.64 TiB (59.4%) 
           ID-1: /dev/sda vendor: Seagate model: ST2000DM008-2FR102 size: 1.82 TiB speed: 6.0 Gb/s rotation: 7200 rpm 
           serial: <filter> rev: 0001 scheme: MBR 
           ID-2: /dev/sdb vendor: Samsung model: SSD 850 PRO 1TB size: 953.87 GiB speed: 6.0 Gb/s serial: <filter> rev: 4B6Q 
           scheme: GPT 
           ID-3: /dev/sdc type: USB model: Multi Flash Reader size: 7.45 GiB serial: <filter> rev: 1.00 scheme: MBR 
           Message: No Optical or Floppy data was found. 
RAID:      Message: No RAID data was found. 
Partition: ID-1: / size: 28.71 GiB used: 14.07 GiB (49.0%) fs: ext4 dev: /dev/sdb2 label: N/A 
           uuid: f63f8e34-794a-4bbf-81a6-418f71830d97 
           ID-2: /boot/efi size: 299.4 MiB used: 144 KiB (0.0%) fs: vfat dev: /dev/sdb1 label: N/A uuid: 9925-6BDA 
           ID-3: /data size: 1.79 TiB used: 1.06 TiB (59.0%) fs: ext4 dev: /dev/sda1 label: N/A 
           uuid: 137d2336-eaab-4a92-a77c-9948668d4982 
           ID-4: /home size: 900.11 GiB used: 581.80 GiB (64.6%) fs: ext4 dev: /dev/sdb3 label: N/A 
           uuid: 56df74b2-6d89-4f0d-a965-88465b3fb8ee 
           ID-5: /run/timeshift/backup raw size: 1.82 TiB size: <root required> used: <root required> fs: ext4 dev: /dev/sda1 
           label: N/A uuid: 137d2336-eaab-4a92-a77c-9948668d4982 
           ID-6: swap-1 size: 8.79 GiB used: 6.5 MiB (0.1%) fs: swap dev: /dev/sdb4 label: N/A 
           uuid: da489ce9-86c9-42c0-89de-9164696c4ab2 
Unmounted: ID-1: /dev/sdc1 size: 7.44 GiB fs: vfat label: N/A uuid: 1C64-1B44 
USB:       Hub: 1-0:1 info: Full speed (or root) Hub ports: 16 rev: 2.0 speed: 480 Mb/s chip ID: 1d6b:0002 
           Device-1: 1-6:2 info: Microsoft Xbox One S Controller type: <vendor specific> driver: xpad interfaces: 3 rev: 2.0 
           speed: 12 Mb/s chip ID: 045e:02ea serial: <filter> 
           Device-2: 1-13:3 info: Holtek Keyboard [Diatec Majestouch 2 Tenkeyless] type: Keyboard,Mouse 
           driver: hid-generic,usbhid interfaces: 2 rev: 1.1 speed: 1.5 Mb/s chip ID: 04d9:4545 
           Device-3: 1-14:4 info: SteelSeries ApS SteelSeries Rival 600 type: HID,Mouse driver: hid-generic,usbhid 
           interfaces: 3 rev: 2.0 speed: 12 Mb/s chip ID: 1038:1724 
           Hub: 2-0:1 info: Full speed (or root) Hub ports: 10 rev: 3.0 speed: 5 Gb/s chip ID: 1d6b:0003 
           Hub: 3-0:1 info: Full speed (or root) Hub ports: 2 rev: 2.0 speed: 480 Mb/s chip ID: 1d6b:0002 
           Hub: 3-1:2 info: Alcor Micro USB Hub ports: 4 rev: 2.0 speed: 480 Mb/s chip ID: 058f:6254 
           Device-4: 3-1.1:3 info: USB2.0Hub type: Mouse driver: uclogic,usbhid interfaces: 2 rev: 1.0 speed: 12 Mb/s 
           chip ID: 256c:006e 
           Device-5: 3-1.4:4 info: Alcor Micro Multi Flash Reader type: Mass Storage driver: usb-storage interfaces: 1 
           rev: 2.0 speed: 480 Mb/s chip ID: 058f:6366 serial: <filter> 
           Hub: 4-0:1 info: Full speed (or root) Hub ports: 2 rev: 3.1 speed: 10 Gb/s chip ID: 1d6b:0003 
Sensors:   System Temperatures: cpu: 23.0 C mobo: N/A gpu: amdgpu temp: 29 C 
           Fan Speeds (RPM): N/A gpu: amdgpu fan: 768 
Info:      Processes: 234 Uptime: 3h 23m Init: systemd v: 245 Compilers: gcc: 9.3.0 clang: 10.0.0 Shell: bash v: 5.0.16 
           running in: yakuake inxi: 3.0.37 

If any more info is needed let me know.

That's a good start, thanks. When it happens again, REISUB your machine and do a:

sudo journalctl --system --boot=-1 > /tmp/Journal.txt

and upload /tmp/Journal.txt here so we can have an in-depth look of what's happening.

:innocent:

After a couple days without problems I got the graphical glitch again this morning, I have a txt file as instructed but I can only upload images on the forum, where should I upload the file?

In the mean time I was scrolling through the journal in the terminal and saw a bunch of red messages towards the end of the file

May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0f00150c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x001059E0
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x0801500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1071584, read from 'DBH3' (0x44424833) (21)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0f10550c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x001059E4
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x09015014
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x14, vmid 4, pasid 32773) at page 1071588, write from 'DBH3' (0x44424833) (21)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0f00d50c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x001059E0
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x080D500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1071584, read from 'DBH7' (0x44424837) (213)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0f08550c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x00000000
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x090E5014
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x14, vmid 4, pasid 32773) at page 0, write from 'DBH6' (0x44424836) (229)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fc0150c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F8
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x0801500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1090040, read from 'DBH3' (0x44424833) (21)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fd0150c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F9
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x09095014
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x14, vmid 4, pasid 32773) at page 1090041, write from 'DBH5' (0x44424835) (149)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fc0d50c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F8
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x080D500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1090040, read from 'DBH7' (0x44424837) (213)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fc0150c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F8
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x0801500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1090040, read from 'DBH3' (0x44424833) (21)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fc0550c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F8
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x0805500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1090040, read from 'DBH1' (0x44424831) (85)
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: GPU fault detected: 146 0x0fc0150c for process plasmashell pid 7724 thread plasmashel:cs0 pid 8056
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x0010A1F8
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0:   VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x0801500C
May 13 09:45:58 akezhar-pc kernel: amdgpu 0000:01:00.0: VM fault (0x0c, vmid 4, pasid 32773) at page 1090040, read from 'DBH3' (0x44424833) (21)

As you have an AMD dGPU, their drivers are built into the kernel, so:

  • Log off

  • Switch to TTY2 by pressing Ctrl+Alt+F2

  • Log in there

  • Execute:

    sudo mhwd-kernel --install linux419
    sudo mhwd-kernel --install linux56-rt
    
  • to ensure grub is showing, execute:

     sudo nano --backup /etc/default/grub
    
  • Change (or add?) the following 3 lines:

    GRUB_TIMEOUT=3
    #GRUB_HIDDEN_TIMEOUT=0
    #GRUB_TIMEOUT_STYLE=hidden
    

    (3 or higher is fine, add the # before the lines above if those lines are present)

  • Ctrl+X Y Enter to save if there is anything to save

  • If you did save, execute:

     sudo update-grub 
    
  • Reboot

  • Go to grub's Advanced options

  • Choose these kernels one by one and try them out one by one and see if that helps.

If it doesn't, these are the available kernels:

  • linux316
  • linux414
  • linux419
  • linux44
  • linux49
  • linux54
  • linux55
  • linux56
  • linux57
  • linux54-rt
  • linux56-rt

After trying a bunch of different kernels without success I've decided to make a new install of the OS, and the problems seem to be gone.

You should have mentioned that this didn't help as it could also have been a user artefact instead of a system artefact and then creating a new user would have been sufficient instead of a full re-install.

:innocent:

Next time!

Forum kindly sponsored by