Files
nexus/wiki/concepts/HandleLidSwitch.md
2026-04-17 08:38:12 +08:00

799 B

title, type, tags, date
title type tags date
HandleLidSwitch concept
systemd
power-management
2026-04-17

Definition

systemd-logind 的电源管理配置项,用于控制笔记本合盖时的系统行为。

Configuration Options

  • ignore:不执行任何操作,系统继续运行
  • suspend:进入待机状态
  • hibernate:进入休眠状态
  • poweroff:关机
  • lock:锁定屏幕
  • HandleLidSwitch:合盖时的动作(电池模式下)
  • HandleLidSwitchExternalPower:连接外接电源合盖时的动作
  • HandleLidSwitchDocked:连接扩展坞合盖时的动作

Use Cases

  • 服务器场景:设置 ignore 防止合盖后系统休眠
  • 笔记本场景:合盖自动锁定或待机

Connections