Chinaunix首页 | 论坛 | 博客
  • 博客访问: 306903
  • 博文数量: 34
  • 博客积分: 1944
  • 博客等级: 上尉
  • 技术积分: 400
  • 用 户 组: 普通用户
  • 注册时间: 2008-02-01 23:22
文章分类

全部博文(34)

文章存档

2010年(2)

2009年(4)

2008年(28)

分类: LINUX

2008-04-25 10:16:27

vsftpd 500 OOPS: cannot change directory
 
今天在默认配置下,启动vsftpd,一般用户登陆居然报错:
C:\>ftp 192.168.0.101
Connected to 192.168.0.101.
220 (vsFTPd 2.0.5)
User (192.168.0.101:(none)): frank
331 Please specify the password.
Password:
500 OOPS: cannot change directory:/home/frank
Login failed.
ftp> ls
500 OOPS: child died
Connection closed by remote host.
 
觉得这个问题很奇怪,google.cn了一下,有人的解决方法是:
解决方法:
ref: http://hi.baidu.com/qhdinfo/blog/item/eee71e0e7abc25c97acbe17d.html
在终端输入命令:
setsebool ftpd_disable_trans 1
service vsftpd restart
就OK了!
 
作者没说为什么,后来google.com后才发现这是SELinux的设置命令.
其实 man 一下setsebool也知道了:
NAME
       setsebool - set SELinux boolean value
 
在不熟悉SELnux前,把SELinux关掉也可以的。有时间研究下SELinux。  
在想用SELinux但是又不熟悉的情况下可以把SELinux设置成Permissive,表示SELinux规则启动,但只是把违规的记录到log中。   
阅读(2748) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~