您的当前位置:首页 --> CentOS入门
centos6.4 查看和关闭selinux
浏览次数:3097 关键词 ( selinux  )
  1. 安装vsftpd服务后,客户端登录ftp报错:

ftp> open 127.0.0.1 Connected to 127.0.0.1 (127.0.0.1). 220 (vsFTPd 2.2.2) Name (127.0.0.1:wander): ftpuser 331 Please specify the password. Password: 500 OOPS: cannot change directory:/home/ftpuser Login failed.

 原因是系统没有关闭selinux

 

 查看selinux状态:

[wander@localhost ~]$ /usr/sbin/sestatus -v SELinux status:                 disabled  //禁用selinux   [wander@localhost ~]$ getenforce  Disabled                                  //禁用selinux   [wander@localhost .ssh]$ getenforce  Enforcing                                //启动

 关闭selinux方法:

#setenforce 0 #设置SELinux 成为permissive模式 #setenforce 1 设置SELinux 成为enforcing模式

 第二种方法:

#vim /etc/selinux/config  编辑文件   # This file controls the state of SELinux on the system. # SELINUX= can take one of these three values: #     enforcing - SELinux security policy is enforced. #     permissive - SELinux prints warnings instead of enforcing. #     disabled - No SELinux policy is loaded. SELINUX=enforcing # SELINUXTYPE= can take one of these two values: #     targeted - Targeted processes are protected, #     mls - Multi Level Security protection.

 

将SELINUX=enforceing 改为 SELINUX=disabled 重启机器就ok了

下载次数:38
下载地址:点击下载
本资源为程序自动采集,如有侵权请联系我们移除 admin#80vps.com 来信请将#替换为@
下一条 centos系统中网络配置相关
上一条 CentOS系统结构 文件属性 权限解析

拥有超过10年的业务管理经验。我们是IDC服务和解决方案方面的专家

有任何疑问请不要犹豫,立即点击联系我们