新增wiki命令文件

This commit is contained in:
2026-04-14 16:02:50 +08:00
parent 65803c911d
commit c6e3d3c5db
485 changed files with 12578 additions and 396 deletions

View File

@@ -0,0 +1,31 @@
---
title: "Ubuntu禁用合盖休眠"
type: source
tags: [ubuntu]
date: 2026-04-14
source_file: raw/Technical/Home Office/🟠Ubuntu禁用合盖休眠.md
---
## Summary
- 核心主题让Ubuntu服务器在笔记本合盖后继续运行
- 问题域:服务器笔记本合盖休眠行为控制
- 方法/机制修改systemd-logind配置或mask休眠target
- 结论/价值:实现合盖继续运行,适合部署为服务器的笔记本场景
## Key Claims
- Ubuntu 24.04中笔记本合盖休眠行为由systemd-logind控制
- 修改HandleLidSwitch、HandleLidSwitchExternalPower、HandleLidSwitchDocked为ignore可禁用合盖休眠
- 使用systemctl mask可以彻底禁用系统休眠功能内核级别
## Key Concepts
- [[systemd-logind]]:系统登录管理器,控制电源管理行为
- [[休眠target]]sleep.target/suspend.target/hibernate.target/hybrid-sleep.target
## Key Entities
- [[Ubuntu]]Linux发行版
## Connections
- [[Ubuntu]] ← 配置 ← [[systemd-logind]]
- [[systemd-logind]] ← 控制 ← [[休眠target]]
## Contradictions