I was building a Fedora server with an old laptop, a Samsung Q330 to be precise. I’m surprised it runs Fedora 33 so well (it wasn’t happy with CentOS 8 at all). I wanted it to remain on at all times, even when the lid is closed. Sadly there was no easy way in GNOME to disable this action, nor did I find anything pertinent in the BIOS.
Thankfully there’s an entry in systemd that we can set. Here’s how to do it. Head over to /etc/systemd/logind.conf. You should find a lot of commented lines in this file. One of them looks like this:
Uncomment this line and change it to this:
Now we need to restart systemd for our change to be acknowledged:
systemctl restart systemd
It works like a charm on my Samsung Q330. I can close the lid, the power stays on, yet the screen blanks as it should.