系统相关
首页 > 系统相关> > CentOS 7 Suspend

CentOS 7 Suspend

作者:互联网

Create a shell script such as 'suspend.sh', fill with following contents,

#!/bin/sh
echo your_root_password | sudo systemctl suspend

make it executable,

$ sudo chmod u+x suspend.sh

then, if you want to suspend the computer, run it,

$ cd to/the/script/path
$ ./suspend.sh

 

(Over)

 

标签:suspend,CentOS,script,Create,sudo,chmod,sh,Suspend
来源: https://www.cnblogs.com/gaowengang/p/15759332.html