Skip to content

systemctl · 管理系统服务(systemd) ​

Linux 命令手册 · 常用命令(必会)

语法

bash
systemctl [子命令] 服务

常用选项

  • start/stop/restart 启停
  • enable/disable 开机
  • status 状态
  • is-active 是否运行

示例

bash
$ systemctl status nginx
$ systemctl restart docker

练习建议

打开「Linux 模拟终端」,直接输入 systemctl 看真实输出,比死记更有效。