3

Last night I upgraded my stationary desktop computer from Ubuntu 19.04 to 20.04. The upgrade went without any difficulty whatsoever.

Next day I found myself needing to use my 3D printer for a small project. I downloaded the model and began printing. The process was estimated to take just under 2 hours.

My printer is kind of loud so I decided to go and do something else in the mean time. About half an hour later I returned to find that my computer had gone into suspend, or hibernation or whatever, and that the printer was stopped in the middle of the model.

Why is my computer doing that, and how do I prevent that from happening? I never want my computer to hibernate for any reason at all.

I'm not a big fan of the Gnome desktop so I use XFCE 4.12. Here are my power settings (which are unaltered - this is how they have been all the time):

Power manager pane 1

Power manager pane 2

Everything looks pretty normal to me.

Any ideas? Also which logs can I check to see why my computer went into suspended state? This is kind of a huge deal for me, as I also leave my computer running for other reasons.

1
  • I have the same problem on my old Lenovo X100e notebook (upgraded to dual core motherboard and 8Gb RAM recently). After a few hours of running with a screen saver on, it shuts off completely by itself when running with the same power settings as above. However, when I press the power button, it won't turn back on. I have to disconnect the power adapter from the notebook, wait a minute, then plug it back in. Only then will it boot back up. I hope this helps a bit to isolate the problem. Oh, I'm running Xubuntu 20.04 and not closing my notebook's lid/display.
    – Stratact
    Sep 27 at 14:55
5

I found a way to at least work around the problem for now.

Looking at /var/log/syslog I noticed that it was the systemd sleep service which was putting my system into suspended state.

Following the information I found on this page I ran the following command:

$ sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target

So far my system hasn't shut down. I'll have to do a few more, longer lasting tests to be sure.

As an ordinary end user, I find my trust in Ubuntu being somewhat shaken by this experience. It seems there is no easy or user friendly way to control the suspend behavior, yet it has evidently been introduced as default behavior in Ubuntu 20.04.

Edit: The solution suggested here has one serious downside: It disables automatic hibernation but it ALSO disables any option to hibernate the system manually. I.e. by selecting Hibernate from the power menu or Whisker menu or whatever you are using. The option simply isn't there anymore.

0

I was running into a similar issue when upgrading to Ubuntu 20.04. My current setup is two external monitors plugged into a laptop with the lid closed. When I was switching my monitors over to my regular PC, my laptop was suspending. By default, the close lid action is to suspend the system. This fixed the issue: https://ubuntuhandbook.org/index.php/2020/05/lid-close-behavior-ubuntu-20-04/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.