1

I am trying to address this issue for a while, but been unable to resolve it. When I put the laptop (ThinkPad P15s Gen1) to sleep mode manually, it will not go to sleep mode, it will try to go to sleep, but wake up in a few seconds (lock screen). I have no idea how to resolve it, other than maybe reformat, which I would prefer not to do. I used to have 20.04, but ended up upgrading to 24.04 hoping it would fix, but it didn't. I also tried using a live CD to see if a fresh ubuntu 20.04 would go to sleep mode, and it did, so perhaps that means bios settings are correct?

Any help would be hugely appreciated. Thanks!

enter image description here

Edit: I used to have cuda installed, but I removed it to eliminate if it was causing an issue.

enter image description here

  • It's not clear if it's suspending and then waking after a few seconds or not suspending at all. Take a look at /var/log/syslog at the time of a suspend/wake to see if there are any clues as to exactly what it's doing and if it's suspending what is causing the wake. Do you have any devices connected to the laptop? Sometimes external devices can cause a wake (e.g. mouse, keyboard, other devices connected to a connected USB dock etc). – codlord Mar 26 '23 at 07:34
  • thank you so much for the assistance. I don't have any dock attached. I have M325 mouse, but the behavior is the same without it too. I added log in the original post. I don't understand it. :p Any thoughts from the logs? – user2661372 Mar 28 '23 at 01:11
  • It's always better to cut/paste log output and properly format it on your question rather than post a terminal screenshot. But anyway, I can see the last line says wake requested from NetworkManager. I don't know why but it could be wired network, Wi-Fi or something else like Bluetooth causing the wake. So I suggest a flight mode before a sleep, then disabling bluetooth and trying a sleep, then the same with WiFi etc. That way you may be able to identify exactly the cause. It could be a bug, or there maybe a workaround by changing a BIOS setting but first you need to narrow down the cause. – codlord Mar 28 '23 at 13:23
  • So I tried that. I set airplane mode and then put laptop to sleep, but it wakes up right away. :/ FYI, I tested sleep function by loading live usb, and it works without any issue (didnd't need to change airplane mode or anything.) I think I might have messed up something in bios, but that should also impact live usb ubuntu too, but it didn't. Any thoughts? I can attach a log with airplane mode. Thank you so much. – user2661372 Mar 29 '23 at 17:35
  • here's the screenshot of my terminal after setting network to airplane mode. Does it help in root cause? https://imgur.com/a/Qnk2F0m – user2661372 Mar 30 '23 at 19:02
  • Any insights from the log above, @codlord? – user2661372 Apr 02 '23 at 20:39
  • any thoughts, my friend? – user2661372 Apr 06 '23 at 00:19
  • I don't know why your NetworkManager is causing the wake. You could try a stop of the service before a sleep as a workaround: sudo systemctl stop network-manager and see the last section of this article here which details disabling the ability of devices to wake the system which may or may not help you: https://gist.github.com/george-hawkins/a897a6fe116093a4c1f29ad19df088de – codlord Apr 10 '23 at 10:20
  • Having the same issue. Might be related to installing Python 3.10 or nvidia driver 5.30 but not sure. I have tried stopping the network manager, hasn't helped. – Tyreal Apr 15 '23 at 05:13

1 Answers1

0

It could be related to another question which has this answer: https://askubuntu.com/a/1393726/1029625

This answer has solved the problem for me. I originally installed a newer version of nvidia driver (5.30), it seems to miss tidying up left over systemd hibernate and suspend requirements.

Tyreal
  • 131
  • 3