Debian设置关闭笔记本关盖休眠

1. 编辑配置文件

vi /etc/systemd/logind.conf

2. 找到下面内容

#HandleLidSwitch=suspend
#HandleLidSwitchExternalPower=suspend
#HandleLidSwitchDocked=ignore

3. 修改成下面内容

HandleLidSwitch=ignore
HandleLidSwitchExternalPower=ignore
HandleLidSwitchDocked=ignore

4. 重启服务使修改生效

systemctl restart systemd-logind 或 service systemd-logind restart


文档仓库 » Debian设置关闭笔记本关盖休眠