禁止ubuntu休眠

2021-02-17  本文已影响0人  semiscone

禁止ubuntu休眠

bill@NUC:~$ sudo systemctl status sleep.target 
● sleep.target - Sleep
     Loaded: loaded (/lib/systemd/system/sleep.target; static; vendor preset: enabled)
     Active: inactive (dead)
       Docs: man:systemd.special(7)

2月 10 18:23:27 NUC systemd[1]: Reached target Sleep.
2月 10 18:29:59 NUC systemd[1]: Stopped target Sleep.
bill@NUC:~$ sudo systemctl mask sleep.target 
Created symlink /etc/systemd/system/sleep.target → /dev/null.

bill@nuc:/ # sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
 Created symlink /etc/systemd/system/sleep.target → /dev/null.
 Created symlink /etc/systemd/system/suspend.target → /dev/null.
 Created symlink /etc/systemd/system/hibernate.target → /dev/null.
 Created symlink /etc/systemd/system/hybrid-sleep.target → /dev/null.
bill@nuc:/etc/pm/sleep.d#
上一篇 下一篇

猜你喜欢

热点阅读