19

Since I installed Ubuntu 16.04 my laptop (HP Probook 450 G2) has issues waking up from suspend. Rarely it manages to properly wake up from suspend, but mostly the screen either stays black or it turns on, and completely freezes after 2 or 3 seconds, followed by a bit louder fan activity in both cases. I cannot switch to a tty shell, or do anything else apart from killing the power by holding the power button.

I tried following different solutions such as disabling USB Legacy, adding acpi_backlight=vendor acpi_osi='!Windows 2013' acpi_osi='!Windows 2012' to GRUB_CMDLINE_LINUX_DEFAULT, but nothing worked.

I switched to Linux Mint yesterday just to test if I have an issue there, but it still persists. Here is the output of /var/log/kern.log which shows the last messages from my previous session.

Feb 13 09:51:55 hamza-PC kernel: [  913.345833] nf_conntrack: automatic helper assignment is deprecated and it will be removed soon. Use the iptables CT target to attach helpers instead.
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.4773] manager: sleep requested (sleeping: no  enabled: yes)
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.4774] manager: sleeping...
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.4774] device (wlo1): state change: activated -> unmanaged (reason 'sleeping') [100 10 37]
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.4969] dhcp4 (wlo1): canceled DHCP transaction, DHCP client pid 1440
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.4970] dhcp4 (wlo1): state changed bound -> done
Feb 13 09:52:22 hamza-PC kernel: [  940.019586] wlo1: deauthenticating from b4:75:0e:ce:22:bb by local choice (Reason: 3=DEAUTH_LEAVING)
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.5125] dns-mgr: Writing DNS information to /sbin/resolvconf
Feb 13 09:52:22 hamza-PC kernel: [  940.034017] cfg80211: World regulatory domain updated:
Feb 13 09:52:22 hamza-PC kernel: [  940.034019] cfg80211:  DFS Master region: unset
Feb 13 09:52:22 hamza-PC kernel: [  940.034020] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
Feb 13 09:52:22 hamza-PC kernel: [  940.034022] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Feb 13 09:52:22 hamza-PC kernel: [  940.034024] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
Feb 13 09:52:22 hamza-PC kernel: [  940.034025] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (N/A, 2000 mBm), (N/A)
Feb 13 09:52:22 hamza-PC kernel: [  940.034026] cfg80211:   (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
Feb 13 09:52:22 hamza-PC kernel: [  940.034027] cfg80211:   (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
Feb 13 09:52:22 hamza-PC kernel: [  940.034028] cfg80211:   (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
Feb 13 09:52:22 hamza-PC kernel: [  940.034029] cfg80211:   (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
Feb 13 09:52:22 hamza-PC kernel: [  940.034030] cfg80211:   (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
Feb 13 09:52:22 hamza-PC NetworkManager[1004]: <info>  [1486975942.5423] manager: NetworkManager state is now ASLEEP
Feb 13 09:52:26 hamza-PC kernel: [  943.880782] i915 0000:00:02.0: BAR 6: [??? 0x00000000 flags 0x2] has bogus alignment
Feb 13 09:52:27 hamza-PC kernel: [  944.885059] i915 0000:00:02.0: BAR 6: [??? 0x00000000 flags 0x2] has bogus alignment

Also

uname -a
Linux hamza-PC 4.4.0-62-generic #83-Ubuntu SMP Wed Jan 18 14:10:15 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Any info would be helpful, thank you!

tepsijash
  • 381

7 Answers7

10

I have a 4.19 kernel and Nvidia driver version 390. I changed gdm to lightdm.

sudo apt install lightdm

Problem is solved now.

Fabby
  • 34,259
  • 2
    worked for me on Ubuntu 18.04. Thank you very much! – Francesco Borzi Jan 20 '19 at 16:06
  • 3
    Running Ubuntu 20.04 on AMD system - solution worked – Be Kind Dec 19 '20 at 04:29
  • This worked, but the screen lock no longer works, and someone could turn on the computer and mess around when I'm away ... – gmt42 Oct 07 '21 at 20:46
  • The problem is that Internet television has temporary freezes of video and audio with lightdm on. When I switched back to gdm3, the problem is apparently resolved from this single change leaving everything else (all tabs) unchanged. Is there another way to remedy freeze after return from suspend? Apparently, the freeze happens while unlocking the session display lock. – gmt42 Oct 10 '21 at 17:50
  • 2 years ago i have same problem. I changed kernel to new version. Problem solved. Download 4 deb file to ubuntu kernel site and install deb packages. And restart with new kernel. – manowar_manowar Oct 10 '21 at 17:55
  • Doing this is the shortest imprecise method. – manowar_manowar Oct 12 '21 at 08:35
  • Did not help on Ubuntu 22.04. It only helped cursor to be working but other then that everything hangs – user1325696 Jul 20 '22 at 01:28
3

After using Ubuntu 16.04 LTS for a few days and everything was OK, I started to experience this freeze on suspend/sleep. I reinstalled the lightdm display manager and the problem didn't go away. I had similar logs to yours, but no hard errors.

What solved the problem for me was changing the default X.org video driver to the NVidia one.

This is located in Settings -> Software & Updates -> Additional Drivers

There I had the following option selected.

'Using X.org X server - Nouveau display driver...'

After changing it to:

Using NVidia binary driver ... (proprietary, tested)

Restart and everything is fine since then :)

enter image description here

luben
  • 131
1

I have had the same problem with Ubuntu 20.04 since installing some time ago - freezing on going into suspend - could only be dealt with by holding down the power-button for some six seconds or so. Tried all manner of suggestions - including those given above - but nothing worked, UNTIL I used the "Software & Updates" app to upgrade and, Hey Presto, all fixed!

Hope it works for you too.

Duncan
  • 1,053
1

Disable the "Ubuntu Dock" gnome shell extension:

gnome-extensions disable ubuntu-dock@ubuntu.com
zx485
  • 2,426
0

Open /etc/systemd/logind.conf using editor like Vim, gedit:

sudo gedit /etc/systemd/logind.conf

You will see all these options:

#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
#HandleSuspendKey=suspend
#HandleHibernateKey=hibernate
#HandleLidSwitch=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
#UserTasksMax=12288

Just change these entries value to suspend and all will work fine:

HandleSuspendKey=suspend
HandleLidSwitch=suspend
HandleLidSwitchDocked=suspend

If still not fixed :

HandleHibernateKey=suspend

Check this article from itsfoss

0

Here is one method which helped me.

Edit grub configuration,

sudoedit /etc/default/grub

Change

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

to

GRUB_CMDLINE_LINUX_DEFAULT="text"

Then do

sudo update-grub

and reboot your computer.

pomsky
  • 68,507
Yukai
  • 9
  • Welcome to Ask Ubuntu. Kindly avoid posting links in an answer, since over the time those links could be broken or not available. – Vishnu N K Oct 11 '18 at 04:41
  • 4
    I don't see how this could have helped. This setting just changes what Ubuntu shows you by boot time. – Quora Feans Nov 06 '19 at 01:10
-1

Temporary Solution | Stuck On The Logon Screen | Even After Many Restarts

If you still find yourself stuck on the logon screen even after the hard restart then follow these steps to get out of this...

  • Restart your system : Press & hold the power button for 5-10 seconds

  • Start the system in recovery mode by selecting "Advance Option for Ubuntu"

  • Select the first options that ends with "(recovery)"

  • Choose "root drop to root shell prompt" option and hint ENTER Key (twice)

  • Execute the following commands:

sudo dpkg --configure -a

sudo prime-select intel

sudo reboot

Note: : This would work only if you're using a system that has two graphics cards (such as nvidia+intel or intel+amd) and the non-intel one is configured as the primary one.

  • Your solution simply selects intel video card. Don't run Linux commands if you don't know what they do. – Shital Shah Oct 24 '19 at 00:29
  • @ShitalShah dear don't add comments without reading the complete answer, I clearly stated there that it's just a temporary solution when your system is configured to use the third party graphic card as the primary one but the appropriate driver for the same is not installed on your system or get corrupted due to sudden power failure/lack of sufficient battery backup in suspend mode etc., then it struggles during the login flow. The commands given above is to fix the corrupted apps or interrupted installations > select the native intel driver as the primary one and then reboot the system. – Akay Nirala Nov 14 '19 at 10:29