centos7 开启关闭服务
2018-04-04 14:14
537 查看
centos 7 中使用systemctl工具来管理服务程序,包括了service和chkconfig
关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running)
启动一个服务:systemctl
start firewalld.service
关闭一个服务:systemctl stop firewalld.service
重启一个服务:systemctl restart firewalld.service
显示一个服务的状态:systemctl status firewalld.service
在开机时启用一个服务:systemctl enable firewalld.service
在开机时禁用一个服务:systemctl disable firewalld.service
查看服务是否开机启动:systemctl is-enabled firewalld.service;echo $?
查看已启动的服务列表:systemctl list-unit-files|grep enabled
关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running)
启动一个服务:systemctl
start firewalld.service
关闭一个服务:systemctl stop firewalld.service
重启一个服务:systemctl restart firewalld.service
显示一个服务的状态:systemctl status firewalld.service
在开机时启用一个服务:systemctl enable firewalld.service
在开机时禁用一个服务:systemctl disable firewalld.service
查看服务是否开机启动:systemctl is-enabled firewalld.service;echo $?
查看已启动的服务列表:systemctl list-unit-files|grep enabled
相关文章推荐
- CentOS7 - systemd服务及开启关闭服务命令
- CentOS(Linux) - SVN使用笔记(一) - 安装SVN过程及开启和关闭svn服务指令
- centos7 开启关闭服务
- redhat或centos关闭防火墙并开启sshd服务
- CentOS下图形界面服务开启关闭以及不同运行级别的转换
- centos防火墙开启、关闭、查看状态
- Centos Linux 开启端口 - 解决Centos发布服务外网访问不了的问题
- Centos开启FTP服务
- android MTK 关闭开启google服务
- windows下关闭系统开启IPv6服务的方法
- Solaris 10 开启/关闭SFTP服务、SSH服务
- CentOS 开启samba共享服务
- centOS防火墙中端口的开启和关闭
- 如何开启Centos6.4系统的SSH服务
- CentOS开启telnet服务
- CentOS开启samba服务(附smb.conf手册)
- Linux系统默认服务建议开启关闭说明列表
- oracle 服务的开启 和 关闭
- Debian GNU Linux服务列表的获取、服务的关闭/开启、服务在启动时是否自己主动执行的生效/失效