ubuntu: disable sleep when lid closes on laptop

Let us talk about scripts, HTML, Perl, PHP, apache, etc.
User avatar
Stevyn
SysOp
Posts:1786
Joined:Mon Nov 09, 2009 10:03 am
Location:Japan
Contact:
ubuntu: disable sleep when lid closes on laptop

Post by Stevyn » Thu Aug 17, 2023 3:56 pm

ubuntu: disable sleep when lid closes on laptop

Code: Select all

 systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
 
nano /etc/systemd/logind.conf

HandleLidSwitch=suspend
 
 systemctl restart systemd-logind
Contact me directly: Ironfeatherbooks (@) gmail.com

Image

Post Reply