Table: LinuxNotes
User: dreamable
Created at: 2021-08-22 22:48:47 UTC
Updated at: 2021-08-22 22:59:21 UTC
Reference:(Table ID 28, Record ID 6)

标题 :
Ubuntu disable sleep
笔记 :
 sudo -H gedit /etc/systemd/logind.conf
 HandleLidSwitch=ignore
 sudo service systemd-logind restart
 # Still sleep after idle
 sudoedit /etc/UPower/UPower.conf
 Change IgnoreLid to IgnoreLid=true
 service upower restart
# also in /etc/systemd/logind.conf
HandleLidSwitch=ignore
HandleLidSwitchExternalPower=ignore
HandleLidSwitchDocked=ignore
HandleHibernateKey=ignore
HandleSuspendKey=ignore
IdleAction=ignore
IdleActionSec=0
 # Still sleep after idle
sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
Tag: