码迷,mamicode.com
首页 > 系统相关 > 详细

CentOS Linux release 7 安装完成后停止几个服务

时间:2018-04-04 16:09:41      阅读:193      评论:0      收藏:0      [点我收藏+]

标签:CentOS Linux release

一、停止邮件服务
[root@localhost ~]# systemctl stop postfix # 临时关闭
[root@localhost ~]# systemctl disable postfix # 永久关闭网络管理命令
Removed symlink /etc/systemd/system/multi-user.target.wants/postfix.service.
[root@localhost ~]#

二、停止打印服务:
[root@localhost ~]# systemctl stop cups.path # 临时关闭
[root@localhost ~]# systemctl stop cups.socket # 临时关闭
[root@localhost ~]# systemctl stop cups.service # 临时关闭
[root@localhost ~]# systemctl disable cups.path # 永久关闭网络管理命令
Removed symlink /etc/systemd/system/multi-user.target.wants/cups.path.
[root@localhost ~]# systemctl disable cups.socket # 永久关闭网络管理命令
Removed symlink /etc/systemd/system/sockets.target.wants/cups.socket.
[root@localhost ~]# systemctl disable cups.service # 永久关闭网络管理命令
Removed symlink /etc/systemd/system/multi-user.target.wants/cups.service.
Removed symlink /etc/systemd/system/printer.target.wants/cups.service.
[root@localhost ~]#

三、停止rpcbind:
[root@localhost ~]# systemctl stop rpcbind.socket # 临时关闭
[root@localhost ~]# systemctl stop rpcbind # 临时关闭
[root@localhost ~]# systemctl disable rpcbind.socket # 永久关闭网络管理命令
Removed symlink /etc/systemd/system/sockets.target.wants/rpcbind.socket.
[root@localhost ~]# systemctl disable rpcbind # 永久关闭网络管理命令
[root@localhost ~]#

四、关闭SELinux,将 /etc/sysconfig/selinux 中的 SELinux=enforcing 修改为 SELinux=disabled
临时关闭,重启失效:
#setenforce 0
#getenforce

五、关闭firewall:
#停止firewall
systemctl stop firewalld.service

#禁止firewall开机启动
systemctl disable firewalld.service 

#查看默认防火墙状态(关闭后显示notrunning,开启后显示running)
firewall-cmd --state

六、关闭NetworkManager

    # systemctl stop NetworkManager        # 临时关闭
    # systemctl disable NetworkManager   # 永久关闭网络管理命令

CentOS Linux release 7 安装完成后停止几个服务

标签:CentOS Linux release

原文地址:http://blog.51cto.com/wangqh/2094715

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!