Linux基础---12服务管理

基本格式:systemctl + 关键指令 + httpd

基础操作关键指令
启动start
停止stop
重启restart
查看状态status
开启开机自启动enable
关闭开机自启动disable

表格的列出是为了复盘时可以更加方便的查阅,毕竟下面的命令不变的是格式。

一.安装服务

yum install httpd -y

二.查看所有服务列表

systemctl list-unit-files

三 . 启动服务

systemctl start httpd

四.停止服务

systemctl stop httpd

五.重启服务

systemctl restart httpd

六.查看服务状态

systemctl status httpd

七.把服务设置为开机自启动

systemctl enable httpd

八.取消服务的开机自启动

systemctl disable httpd

九.关闭防火墙:

systemctl stop firewalld
systemctl disable firewalld
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值