Ubuntu – 18.04: How to lock the screen without suspending the machine

18.04gnome-shellgnome-shell-extensionlock-screensuspend

I'd like to leave my screen in a locked state, but without the machine being suspended. I need to have long computations running in the background while I go grab a coffee, while making sure no one around can access the machine.

Locking the screen also suspends the machine, which is not what I want. How do I lock my screen without suspending the machine?

This isn't quite a duplicate of this question, because I am not looking for how to disable suspend. @user535733 is right: it appears to be suspended, more so because I'm using GNOME Shell system-monitor, which looks like this after unlocking the screen:
this

Prior to 18.04, I was used to indicator-multiload, which remains active when the screen is locked/display is off. Which is why GNOME Shell system-monitor looked like the system was suspended. Leaving this up in case anyone else has the same confusion.

Best Answer

When you lock your machine with Super+L it locks and turns off display then. It doesn't go to suspend state in that moment.

But it can suspend later according with your settings. To prevent suspending open Settings -> Power and turn off Automatic suspend "On Battery Power" and "Plugged in".