Ubuntu – Stop laptop from suspending when closing lid in lightdm

lightdmpower-management

How do I stop my laptop from suspending when closing the lid under lightdm – the power management settings in xfce or gnome 3 does not seem to apply when the window manager is not running.

Best Answer

At the bottom of /etc/UPower/UPower.conf, set IgnoreLid=true.