笔记基本分类-systemd管理服务的命令
systemd管理服务的命令:(centos7专用)
查状态:systemctl status 服务名.service
启动:systemctl start 服务名.service
停止:systemctl stop 服务名.service
重启:systemctl restart 服务名.service
重加载:systemctl reload 服务名.service
查开机启动设置状态: systemctl list-unit-files
开机自动启动:systemctl enable 服务名.service
开机不启动:systemctl disable 服务名.service
查详细错误信息:systemctl status 服务名.service
journalctl -xe
systemv 、init管理服务的命令:(centos6、7通用)
查状态:service 服务名 status
启动:service 服务名 start
停止:service 服务名 stop
重启:service 服务名 restart
重加载:service 服务名 reload
查开机启动设置状态:chkconfig --list [服务名]
开机自动启动:chkconfig 服务名 on
开机不启动:chkconfig 服务名 off
查详细错误信息:systemctl 服务名 status
浙公网安备 33010602011771号