From 6e9dd516f10d7d03b9b9df01ed2a2fc76b33fd3c Mon Sep 17 00:00:00 2001 From: fbachus Date: Fri, 8 Nov 2024 19:02:18 +0100 Subject: [PATCH] add systemd config files for sleep and login/session behaviour --- 10_logind_default.conf | 36 ++++++++++++++++++++++++++++++++++++ 10_sleepd_default.conf | 12 ++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 10_logind_default.conf create mode 100644 10_sleepd_default.conf diff --git a/10_logind_default.conf b/10_logind_default.conf new file mode 100644 index 0000000..a605570 --- /dev/null +++ b/10_logind_default.conf @@ -0,0 +1,36 @@ +#/etc/systemd/logind.conf.d/10_default.conf + +[Login] +#NAutoVTs=6 +#ReserveVT=6 +#KillUserProcesses=no +#KillOnlyUsers= +#KillExcludeUsers=root +#InhibitDelayMaxSec=5 +#UserStopDelaySec=10 +#SleepOperation=suspend-then-hibernate suspend +#HandlePowerKey=poweroff +#HandlePowerKeyLongPress=ignore +#HandleRebootKey=reboot +#HandleRebootKeyLongPress=poweroff +#HandleSuspendKey=suspend +#HandleSuspendKeyLongPress=hibernate +#HandleHibernateKey=hibernate +#HandleHibernateKeyLongPress=ignore +HandleLidSwitch=suspend-then-hibernate +#HandleLidSwitchExternalPower=suspend +#HandleLidSwitchDocked=ignore +#PowerKeyIgnoreInhibited=no +#SuspendKeyIgnoreInhibited=no +#HibernateKeyIgnoreInhibited=no +LidSwitchIgnoreInhibited=yes +#RebootKeyIgnoreInhibited=no +#HoldoffTimeoutSec=30s +IdleAction=Suspend +IdleActionSec=20min +#RuntimeDirectorySize=10% +#RuntimeDirectoryInodesMax= +#RemoveIPC=yes +#InhibitorsMax=8192 +#SessionsMax=8192 +StopIdleSessionSec=3600 diff --git a/10_sleepd_default.conf b/10_sleepd_default.conf new file mode 100644 index 0000000..5431185 --- /dev/null +++ b/10_sleepd_default.conf @@ -0,0 +1,12 @@ +# /etc/systemd/sleep.conf.d/10_default.conf +[Sleep] +AllowSuspend=yes +AllowHibernation=yes +AllowSuspendThenHibernate=yes +AllowHybridSleep=no +SuspendState=mem standby freeze +HibernateMode=platform shutdown +MemorySleepMode=deep +HibernateDelaySec=7200 +SuspendEstimationSec=60min +