Hi there,
I have Kali 2020.1B w/GNOME desktop environment running in VMWare Workstation Pro on a Windows 10 host. Kali installed from the .iso
I've been experiencing consistent freezes after the Kali VM has been running for a few minutes.
In hopes of troubleshooting this further, after rebooting the VM I started the SSH service hoping that I could still SSH in after the 'freeze' occurred. Sure enough, I was able to and observed that when the Kali VM was in this frozen state the Xwayland process was pinned at 99% CPU usage.
Code:
kali@kali:/var/log$ top
top - 12:34:38 up 9 min, 2 users, load average: 1.00, 0.80, 0.41
Tasks: 180 total, 2 running, 178 sleeping, 0 stopped, 0 zombie
%Cpu(s): 50.0 us, 0.2 sy, 0.0 ni, 49.8 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
MiB Mem : 7938.1 total, 6469.6 free, 1017.5 used, 451.0 buff/cache
MiB Swap: 8190.0 total, 8190.0 free, 0.0 used. 6670.4 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1297 kali 20 0 468820 56688 35544 R 99.7 0.7 7:11.81 Xwayland
1642 kali 20 0 13412 6080 4868 S 0.3 0.1 0:00.05 sshd
1 root 20 0 101524 10988 8284 S 0.0 0.1 0:01.35 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kthreadd
3 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_gp
4 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_par_gp
6 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 kworker/0:0H-kblockd
8 root 20 0 0 0 0 I 0.0 0.0 0:00.03 kworker/u256:0-events_unbound
9 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 mm_percpu_wq
10 root 20 0 0 0 0 S 0.0 0.0 0:00.02 ksoftirqd/0
11 root 20 0 0 0 0 I 0.0 0.0 0:00.04 rcu_sched
12 root rt 0 0 0 0 S 0.0 0.0 0:00.00 migration/0
I've since switched to using an Xorg instread of Wayland and so far I have not encountered the freeze again.
To switch to Xorg:
- Open /etc/gdm3/daemon.conf in a text editor
- Uncomment the line "WaylandEnable=false"
- Reboot
- Once logged in again, confirm by opening a terminal and running: echo $XDG_SESSION_TYPE. Result should now be x11 (instead of wayland)