How do I prevent an external monitor from shutting off when closing my laptop lid?

Solution 1:

I scoured the 'net for solutions that respected the Ubuntu/GNOME settings but ultimately this was the only thing that worked for me:

sudo vim /etc/UPower/UPower.conf

# <snip> ...

ignoreLid=true

# <snip> ...

On systemd operating systems you can issue the command sudo service upower restart to have the new config take effect. Otherwise, you need to reboot.

Solution 2:

The only way I managed this: hit dash and search for displays.

Screenshot of "Displays" Window

2 things I noticed:

  • the 'off' does not get saved;
  • I still need to keep the screen physically up. Closing the lid kills the 2nd monitor too. If you do close the lid and put it back up both screens light up.

The problem is that closing the lid still shuts off my external monitor. What to do?

Found it: after the 2nd monitor turns off move the mouse or type something. The 2nd monitor will turn on.

Solution 3:

Managed to do this by installing dconf tools and disabling org->gnome->desktop->screensaver: * idle-activation-enabled

I also had to set the 'Turn screen off when inactive for:' setting to 'Never' on the 'Brightness and Lock' section of the Ubuntu settings.

Lastly, I had to make sure that displays are not mirrored (Check box on 'Displays' settings dialog)

Now it finally works.