云服务器 ECS Linux CentOS 7 下重启服务通过service 操作报错:
Redirecting to /bin/systemctl restart sshd.service
查资料发现,在ESC下重启服务是通过systemctl 操作:
例:1、启动sshd服务:
systemctl start sshd.service
2.、重启 sshd 服务:
systemctl restart sshd.service
3、 设置服务开启自启:
systemctl enable sshd.service