The issue still happens in GNOME and KDE!! So it is not a KDE issue either! Even the light on the Caps
button doesn’t change when the issue is happening if I press it, but the Fn
light works. Please tell me where else I can go to fix my issue. I really want help
Edit:
THIS ISSUE EVEN HAPPENS IN MY WINDOWS DUAL BOOT!!!
It sounds like a bios issue if it is happening in Windows too. You may need to go to the forums for Surface and see if someone there can help you sort that out. I’m guessing they have support forums.
Okay, I’ll look in the bios and maybe sign up for the Microsoft forums
Edit: Whoops, I almost fully reset my computer trying to open the bios!
If it’s across OS, do a memory check. Maybe it’s just faulty ram.
forget what I said. Just saw, you are able to revive your surface after screen turning black. when hitting the touchpad.
I got a USB with memtest86 should I run that?
Edit: I ran the test, no errors
Go for it. It won’t hurt.
I think I found out the issue. Whenever this issue occurs it seems like the system clock gets misaligned by ~12 hours. I think that the system clock gets misaligned first and then KDE gets confused as to what just happened, then it sleeps and sends me to the lock screen.
I am not 100% sure but I think disabling the automatic network time synchronisation will fix this. It would be nice if the time on my computer was synchronised with time.is because it is what I use normally and it’s super accurate.
Please post the output of
timedatectl
Yeah, looks like there is a problem with my configuration. I never even used the terminal timedatectl on this computer so I wonder how this happened!
Local Time: Wed 2023-10-11 17:48:13 NZDT
Universal Time: Wed 2023-10-11 04:48:13 UTC
RTC Time: Wed 2023-10-11 17:48:13
Time Zone: Pacific/Auckland (NZDT, +1300)
System clock synchronized: no
NTP Service: inactive
RTC in local TZ: yes
And it shows a warning complaining about the RTC in local TZ thing. I have run the command suggested as sudo and now I hope it will fix
Unfortunately it did not fix the issue
The time is now fixed, but the computer still goes to sleep sometimes.
I noticed that the computer is much more likely to break when waking from sleep if it is not on the kernel 6.4.15, in the GRUB screen if I choose any newer version than that, waking from sleep is broken.
Please clarify “sometimes”.
Can you also post the output of
systemd-inhibit --list
and a full journal log after such an unintended sleep occurs?
Note the command below will upload your log file to 0x0.st
sudo journalctl -b | curl -F 'file=@-' 0x0.st
Sorry for the late reply!!
I had a look at the kernel logs and I have a feeling that the lid is being “closed” randomly even though I am still looking at the screen. (I am not sure if I should attach the full log because I think it contains personal information) I still don’t understand why the newer kernel versions seem to be even worse.
Here is the systemd-inhibit command after ~a minute:
WHO UID USER PID COMM WHAT WHY MODE
ModemManager 0 root 914 ModemManager sleep ModemManager needs to reset devices delay
NetworkManager 0 root 933 NetworkManager sleep NetworkManager needs to turn off networks delay
UPower 0 root 835 upowerd sleep Pause device polling delay
PowerDevil 1001 myusername 1599 org_kde_powerde handle-power-key:handle-suspend-key:handle-hibernate-key:handle-lid-switch KDE handles power events block
Screen Locker 1001 myusername 1349 kwin_wayland sleep Ensuring that the screen gets locked before going to sleep delay
5 inhibitors listed.
Do you perhaps wear a metal bracelet or something similar? Most laptops use a sensor based on magnetism to detect lid closing, and they can be accidentally triggered by other items.
I wear an apple watch to school but at home I don’t and this still can happen.